Options
All
  • Public
  • Public/Protected
  • All
Menu

Class ElasticSearchService<T>

Type parameters

  • T: ElasticSearchServiceParameters

Hierarchy

Constructors

Properties

_asyncCount: number = 0
_client: elasticsearch.Client
_createException: string
_initException: any
_initTime: number
_name: string

Service name

_refreshMode: string = "false"
_webda: Core

Webda Core object

logger: Logger

Logger with class context

parameters: T

Hold the parameters for your service

It will be bring from the webda.config.json

defaultMaxListeners: number

Methods

  • __clean(): Promise<void>
  • _create(index: string, object: CoreModel, uuid: string): Promise<void>
  • _delete(index: string, object: CoreModel, uuid: string): Promise<void>
  • _httpSearch(ctx: any): void
  • _update(index: string, object: CoreModel, uuid: string): Promise<void>
  • _wait(): Promise<unknown>
  • addListener(event: string | symbol, listener: function): this
  • addRoute(url: string, methods: HttpMethodType[], executer: Function, openapi?: object, allowPath?: boolean): void
  • bulk(index: string, objects: any): Promise<object>
  • computeParameters(): void
  • count(index?: string): Promise<any>
  • emit(event: string | symbol, ...args: any[]): boolean
  • emitSync(event: any, data: any): Promise<any[]>
  • eventNames(): Array<string | symbol>
  • exists(index: string, uuid: string): Promise<any>
  • getClient(): any
  • getMaxListeners(): number
  • getName(): string
  • getParameters(): T
  • getService<T>(service: string): T
  • getWebda(): Core
  • init(): Promise<void>
  • initRoutes(): void
  • listenerCount(type: string | symbol): number
  • listeners(event: string | symbol): Function[]
  • loadParameters(params: any): ServiceParameters
  • off(event: string | symbol, listener: function): this
  • on(event: string | symbol, listener: function): this
  • onAsync(event: any, callback: any, queue?: string): void
  • once(event: string | symbol, listener: function): this
  • prependListener(event: string | symbol, listener: function): this
  • prependOnceListener(event: string | symbol, listener: function): this
  • rawListeners(event: string | symbol): Function[]
  • reinit(config: any): Promise<void>
  • removeAllListeners(event?: string | symbol): this
  • removeListener(event: string | symbol, listener: function): this
  • resolve(): void
  • search(index: string, query: any, from?: number): Promise<any[]>
  • setMaxListeners(n: number): this
  • setRefreshMode(mode: string): void
  • toPublicJSON(object: any): string
  • wait(timeout?: number): Promise<void>
  • flatten(array: any[]): any
  • getModda(): object
  • getObjectSize(obj: any): number
  • listenerCount(emitter: EventEmitter, event: string | symbol): number

Generated using TypeDoc