3 ²˜‚]µã@s,ddlmZmZmZmZGdd„deƒZdS)é)ÚNamespacedClientÚ query_paramsÚ _make_pathÚ SKIP_IN_PATHc@s¸eZdZeƒddd„ƒZeƒddd„ƒZeƒddd„ƒZeƒddd „ƒZed ƒd d d „ƒZeƒd!d d„ƒZ eddddƒd"dd„ƒZ eƒd#dd„ƒZ edƒd$dd„ƒZ eƒd%dd„ƒZ dS)&Ú WatcherClientNcCs.|tkrtdƒ‚|jjdtdd|d|ƒ|d�S)zÞ ``_ :arg watch_id: Watch ID :arg action_id: A comma-separated list of the action ids to be acked z6Empty value passed for a required argument 'watch_id'.ÚPUTÚ_watcherÚwatchZ_ack)Úparams)rÚ ValueErrorÚ transportÚperform_requestr)ÚselfÚwatch_idZ action_idr ©rúK/tmp/pip-build-z81i1n8o/elasticsearch/elasticsearch/client/xpack/watcher.pyÚ ack_watchs zWatcherClient.ack_watchcCs,|tkrtdƒ‚|jjdtdd|dƒ|d�S)z— ``_ :arg watch_id: Watch ID z6Empty value passed for a required argument 'watch_id'.rrr Z _activate)r )rr r r r)rrr rrrÚactivate_watchszWatcherClient.activate_watchcCs,|tkrtdƒ‚|jjdtdd|dƒ|d�S)z™ ``_ :arg watch_id: Watch ID z6Empty value passed for a required argument 'watch_id'.rrr Z _deactivate)r )rr r r r)rrr rrrÚdeactivate_watch"s  zWatcherClient.deactivate_watchcCs*|tkrtdƒ‚|jjdtdd|ƒ|d�S)zŽ ``_ :arg id: Watch ID z0Empty value passed for a required argument 'id'.ÚDELETErr )r )rr r r r)rÚidr rrrÚ delete_watch1szWatcherClient.delete_watchÚdebugcCs|jjdtdd|dƒ||d�S)a ``_ :arg id: Watch ID :arg body: Execution control :arg debug: indicates whether the watch should execute in debug mode rrr Z_execute)r Úbody)r r r)rrrr rrrÚ execute_watch>s  zWatcherClient.execute_watchcCs*|tkrtdƒ‚|jjdtdd|ƒ|d�S)z‹ ``_ :arg id: Watch ID z0Empty value passed for a required argument 'id'.ÚGETrr )r )rr r r r)rrr rrrÚ get_watchNszWatcherClient.get_watchÚactiveZif_primary_termZ if_seq_noÚversioncCs,|tkrtdƒ‚|jjdtdd|ƒ||d�S)aR ``_ :arg id: Watch ID :arg body: The watch :arg active: Specify whether the watch is in/active by default :arg if_primary_term: only update the watch if the last operation that has changed the watch has the specified primary term :arg if_seq_no: only update the watch if the last operation that has changed the watch has the specified sequence number :arg version: Explicit version number for concurrency control z0Empty value passed for a required argument 'id'.rrr )r r)rr r r r)rrrr rrrÚ put_watch[szWatcherClient.put_watchcCs|jjdd|d�S)zl ``_ ÚPOSTz/_watcher/_start)r )r r )rr rrrÚstartoszWatcherClient.startZemit_stacktracescCs|jjdtdd|ƒ|d�S)a% ``_ :arg metric: Controls what additional stat metrics should be include in the response :arg emit_stacktraces: Emits stack traces of currently running watches rrÚstats)r )r r r)rZmetricr rrrr"vs zWatcherClient.statscCs|jjdd|d�S)zk ``_ r z/_watcher/_stop)r )r r )rr rrrÚstopƒszWatcherClient.stop)NN)N)N)N)NNN)N)NN)N)NN)N)Ú__name__Ú __module__Ú __qualname__rrrrrrrrr!r"r#rrrrrs(         rN)ÚutilsrrrrrrrrrÚs