U Ec_@s,ddlmZmZmZmZGdddeZdS))NamespacedClient query_params _make_path SKIP_IN_PATHc@seZdZedddZedddZedddZeddd Zedd d Zed d dddZ edddZ edddddZ dS) RollupClientNcCs,|tkrtd|jjdtdd|||dS)z Deletes an existing rollup job. ``_ :arg id: The ID of the job to delete 0Empty value passed for a required argument 'id'.DELETE_rollupjobparamsheadersr ValueError transportperform_requestrselfidr r rB/tmp/pip-target-m1bursmm/lib/python/elasticsearch/client/rollup.py delete_jobs zRollupClient.delete_jobcCs|jjdtdd|||dS)a Retrieves the configuration, stats, and status of rollup jobs. ``_ :arg id: The ID of the job(s) to fetch. Accepts glob patterns, or left blank for all jobs GETr r r rrrrrrrget_jobs%s  zRollupClient.get_jobscCs|jjdtdd|||dS)aY Returns the capabilities of any rollup jobs that have been configured for a specific index or index pattern. ``_ :arg id: The ID of the index to check rollup capabilities on, or left blank for all jobs rr datar rrrrrget_rollup_caps2s  zRollupClient.get_rollup_capscCs,|tkrtd|jjdt|dd||dS)a^ Returns the rollup capabilities of all jobs inside of a rollup index (e.g. the index where rollup data is stored). ``_ :arg index: The rollup index or index pattern to obtain rollup capabilities from. z3Empty value passed for a required argument 'index'.rr rr r)rindexr r rrrget_rollup_index_caps@s  z"RollupClient.get_rollup_index_capscCs<||fD]}|tkrtdq|jjdtdd||||dS)z Creates a rollup job. ``_ :arg id: The ID of the job to create :arg body: The job configuration +Empty value passed for a required argument.PUTr r r r bodyr)rrr"r r paramrrrput_jobQs   zRollupClient.put_jobZrest_total_hits_as_intZ typed_keyscCs<||fD]}|tkrtdq|jjdt||d|||dS)a Enables searching rolled-up data using the standard query DSL. ``_ :arg index: The indices or index-pattern(s) (containing rollup or regular data) that should be searched :arg body: The search request body :arg doc_type: The doc type inside the index :arg rest_total_hits_as_int: Indicates whether hits.total should be rendered as an integer or an object in the rest search response :arg typed_keys: Specify whether aggregation and suggester names should be prefixed by their respective types in the response rPOSTZ_rollup_searchr!r)rrr"Zdoc_typer r r#rrr rollup_searchfs   zRollupClient.rollup_searchcCs.|tkrtd|jjdtdd|d||dS)z Starts an existing, stopped rollup job. ``_ :arg id: The ID of the job to start rr%r r _startr rrrrr start_jobs zRollupClient.start_jobtimeoutZwait_for_completioncCs.|tkrtd|jjdtdd|d||dS)a Stops an existing, started rollup job. ``_ :arg id: The ID of the job to stop :arg timeout: Block for (at maximum) the specified duration while waiting for the job to stop. Defaults to 30s. :arg wait_for_completion: True if the API should block until the job has fully stopped, false if should be executed async. Defaults to false. rr%r r _stopr rrrrrstop_jobs  zRollupClient.stop_job)NN)NNN)NNN)NN)NN)NNN)NN)NN) __name__ __module__ __qualname__rrrrrr$r&r(r+rrrrrs        rN)utilsrrrrrrrrrs