Files
elasticsearch-js/docs/reference/api/Watcher.md
2025-05-27 15:30:21 -05:00

16 KiB

Watcher

Constructor

::: new Watcher(transport: Transport); :::

Properties

Name Type Description
acceptedParams Record<string, { path: string[]; body: string[]; query: string[]; }>  
transport Transport  

Methods

Name Signature Description
ackWatch ackWatch(this: [That](./That.md), params: [WatcherAckWatchRequest](./WatcherAckWatchRequest.md), options?: [TransportRequestOptionsWithOutMeta](./TransportRequestOptionsWithOutMeta.md)): Promise<[WatcherAckWatchResponse](./WatcherAckWatchResponse.md)>; Acknowledge a watch. Acknowledging a watch enables you to manually throttle the execution of the watch's actions. The acknowledgement state of an action is stored in the status.actions.<id>.ack.state structure. IMPORTANT: If the specified watch is currently being executed, this API will return an error The reason for this behavior is to prevent overwriting the watch status from a watch execution. Acknowledging an action throttles further executions of that action until its ack.state is reset to awaits_successful_execution. This happens when the condition of the watch is not met (the condition evaluates to false).