U wâ’i.Šã@s8dZddlmZddlZddlmZGdd„deƒZdS)a InfluxDB OSS API Service. The InfluxDB v2 API provides a programmatic interface for all interactions with InfluxDB. Access the InfluxDB API using the `/api/v2/` endpoint. # noqa: E501 OpenAPI spec version: 2.0.0 Generated by: https://openapi-generator.tech é)Úabsolute_importN)Ú _BaseServicecsâeZdZdZd5‡fdd„ Zdd„Zdd„Zd d „Zd d „Zd d„Z dd„Z dd„Z dd„Z dd„Z dd„Zdd„Zdd„Zdd„Zdd „Zd!d"„Zd#d$„Zd%d&„Zd'd(„Zd)d*„Zd+d,„Zd-d.„Zd/d0„Zd1d2„Zd3d4„Z‡ZS)6ÚReplicationsServicez‹NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech Do not edit the class manually. Ncstƒ |¡dS)z5ReplicationsService - a operation defined in OpenAPI.N)ÚsuperÚ__init__)ÚselfÚ api_client©Ú __class__©ú]/opt/alt/python38/lib/python3.8/site-packages/influxdb_client/service/replications_service.pyrszReplicationsService.__init__cKs6d|d<| d¡r |j|f|ŽS|j|f|Ž}|SdS)a"Delete a replication. This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.delete_replication_by_id(replication_id, async_req=True) >>> result = thread.get() :param async_req bool :param str replication_id: (required) :param str zap_trace_span: OpenTracing span context :return: None If the method is called asynchronously, returns the request thread. TÚ_return_http_data_onlyÚ async_reqN)ÚgetÚ'delete_replication_by_id_with_http_info©rÚreplication_idÚkwargsÚdatar r r Údelete_replication_by_id s  z,ReplicationsService.delete_replication_by_idcKsf|j|f|Ž\}}}}}|jjdd||||gidg| d¡| d¡| dd¡| d¡i| d d¡d S) a1Delete a replication. This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.delete_replication_by_id_with_http_info(replication_id, async_req=True) >>> result = thread.get() :param async_req bool :param str replication_id: (required) :param str zap_trace_span: OpenTracing span context :return: None If the method is called asynchronously, returns the request thread. ú$/api/v2/replications/{replicationID}ÚDELETENrr Ú_preload_contentTÚ_request_timeoutÚ urlopen_kw© ÚbodyZ post_paramsÚfilesZ response_typeZ auth_settingsrr rrZcollection_formatsr©Ú!_delete_replication_by_id_preparerÚcall_apir©rrrÚlocal_var_paramsÚ path_paramsÚ query_paramsÚ header_paramsÚ body_paramsr r r r6s( ÿ   ñz;ReplicationsService.delete_replication_by_id_with_http_infocËsl|j|f|Ž\}}}}}|jjdd||||gidg| d¡| d¡| dd¡| d¡i| d d¡d IdHS) a\Delete a replication. This method makes an asynchronous HTTP request. :param async_req bool :param str replication_id: (required) :param str zap_trace_span: OpenTracing span context :return: None If the method is called asynchronously, returns the request thread. rrNrr rTrrrrr!r r r Údelete_replication_by_id_asyncYs( ÿ   ñz2ReplicationsService.delete_replication_by_id_asyncc Kstƒ}ddg}| d||¡d|ks0|ddkr8tdƒ‚i}d|krP|d|d<g}i}d|krl|d|d<d}|j dg¡|d<|||||fS) NrÚzap_trace_spanrzWMissing the required parameter `replication_id` when calling `delete_replication_by_id`Ú replicationIDúZap-Trace-Spanúapplication/jsonÚAccept©ÚlocalsÚ_check_operation_paramsÚ ValueErrorrÚselect_header_accept© rrrr"Ú all_paramsr#r$r%r&r r r rys& ÿ  ÿz5ReplicationsService._delete_replication_by_id_preparecKs6d|d<| d¡r |j|f|ŽS|j|f|Ž}|SdS)a(Retrieve a replication. This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.get_replication_by_id(replication_id, async_req=True) >>> result = thread.get() :param async_req bool :param str replication_id: (required) :param str zap_trace_span: OpenTracing span context :return: Replication If the method is called asynchronously, returns the request thread. Tr rN)rÚ$get_replication_by_id_with_http_inforr r r Úget_replication_by_id”s  z)ReplicationsService.get_replication_by_idcKsf|j|f|Ž\}}}}}|jjdd||||gidg| d¡| d¡| dd¡| d¡i| d d ¡d S) a7Retrieve a replication. This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.get_replication_by_id_with_http_info(replication_id, async_req=True) >>> result = thread.get() :param async_req bool :param str replication_id: (required) :param str zap_trace_span: OpenTracing span context :return: Replication If the method is called asynchronously, returns the request thread. rÚGETÚ Replicationrr rTrrNr©Ú_get_replication_by_id_preparerr rr!r r r r4ªs( ÿ   ñz8ReplicationsService.get_replication_by_id_with_http_infocËsl|j|f|Ž\}}}}}|jjdd||||gidg| d¡| d¡| dd¡| d¡i| d d ¡d Id HS) aeRetrieve a replication. This method makes an asynchronous HTTP request. :param async_req bool :param str replication_id: (required) :param str zap_trace_span: OpenTracing span context :return: Replication If the method is called asynchronously, returns the request thread. rr6r7rr rTrrNrr8r!r r r Úget_replication_by_id_asyncÍs( ÿ   ñz/ReplicationsService.get_replication_by_id_asyncc Kstƒ}ddg}| d||¡d|ks0|ddkr8tdƒ‚i}d|krP|d|d<g}i}d|krl|d|d<d}|j dg¡|d<|||||fS) Nrr(r5zTMissing the required parameter `replication_id` when calling `get_replication_by_id`r)r*r+r,r-r2r r r r9ís& ÿ  ÿz2ReplicationsService._get_replication_by_id_preparecKs6d|d<| d¡r |j|f|ŽS|j|f|Ž}|SdS)aƒList all replications. This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.get_replications(org_id, async_req=True) >>> result = thread.get() :param async_req bool :param str org_id: The organization ID. (required) :param str zap_trace_span: OpenTracing span context :param str name: :param str remote_id: :param str local_bucket_id: :return: Replications If the method is called asynchronously, returns the request thread. Tr rN)rÚget_replications_with_http_info)rÚorg_idrrr r r Úget_replicationss  z$ReplicationsService.get_replicationscKsf|j|f|Ž\}}}}}|jjdd||||gidg| d¡| d¡| dd¡| d¡i| d d ¡d S) a’List all replications. This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.get_replications_with_http_info(org_id, async_req=True) >>> result = thread.get() :param async_req bool :param str org_id: The organization ID. (required) :param str zap_trace_span: OpenTracing span context :param str name: :param str remote_id: :param str local_bucket_id: :return: Replications If the method is called asynchronously, returns the request thread. ú/api/v2/replicationsr6Ú Replicationsrr rTrrNr©Ú_get_replications_preparerr r©rr<rr"r#r$r%r&r r r r;!s( ÿ   ñz3ReplicationsService.get_replications_with_http_infocËsl|j|f|Ž\}}}}}|jjdd||||gidg| d¡| d¡| dd¡| d¡i| d d ¡d Id HS) aÍList all replications. This method makes an asynchronous HTTP request. :param async_req bool :param str org_id: The organization ID. (required) :param str zap_trace_span: OpenTracing span context :param str name: :param str remote_id: :param str local_bucket_id: :return: Replications If the method is called asynchronously, returns the request thread. r>r6r?rr rTrrNrr@rBr r r Úget_replications_asyncGs( ÿ   ñz*ReplicationsService.get_replications_asyncc Ksêtƒ}dddddg}| d||¡d|ks6|ddkr>tdƒ‚i}g}d|kr`| d|df¡d|krz| d|df¡d|kr”| d |df¡d|kr®| d |df¡i}d|krÆ|d|d <d}|j d g¡|d <|||||fS)Nr<r(ÚnameZ remote_idZlocal_bucket_idr=zGMissing the required parameter `org_id` when calling `get_replications`ZorgIDZremoteIDZ localBucketIDr*r+r,)r.r/r0Úappendrr1) rr<rr"r3r#r$r%r&r r r rAjs2 ÿ ÿz-ReplicationsService._get_replications_preparecKs:d|d<| d¡r"|j||f|ŽS|j||f|Ž}|SdS)aïUpdate a replication. This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.patch_replication_by_id(replication_id, replication_update_request, async_req=True) >>> result = thread.get() :param async_req bool :param str replication_id: (required) :param ReplicationUpdateRequest replication_update_request: (required) :param str zap_trace_span: OpenTracing span context :param bool validate: If true, validate the updated information, but don't save it. :return: Replication If the method is called asynchronously, returns the request thread. Tr rN)rÚ&patch_replication_by_id_with_http_info)rrÚreplication_update_requestrrr r r Úpatch_replication_by_id‹s  z+ReplicationsService.patch_replication_by_idc Ksh|j||f|Ž\}}}}}|jjdd||||gidg| d¡| d¡| dd¡| d¡i| d d ¡d S) aþUpdate a replication. This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.patch_replication_by_id_with_http_info(replication_id, replication_update_request, async_req=True) >>> result = thread.get() :param async_req bool :param str replication_id: (required) :param ReplicationUpdateRequest replication_update_request: (required) :param str zap_trace_span: OpenTracing span context :param bool validate: If true, validate the updated information, but don't save it. :return: Replication If the method is called asynchronously, returns the request thread. rÚPATCHr7rr rTrrNr©Ú _patch_replication_by_id_preparerr r© rrrGrr"r#r$r%r&r r r rF£s(ÿ   ñz:ReplicationsService.patch_replication_by_id_with_http_infoc Ësn|j||f|Ž\}}}}}|jjdd||||gidg| d¡| d¡| dd¡| d¡i| d d ¡d Id HS) aUpdate a replication. This method makes an asynchronous HTTP request. :param async_req bool :param str replication_id: (required) :param ReplicationUpdateRequest replication_update_request: (required) :param str zap_trace_span: OpenTracing span context :param bool validate: If true, validate the updated information, but don't save it. :return: Replication If the method is called asynchronously, returns the request thread. rrIr7rr rTrrNrrJrLr r r Úpatch_replication_by_id_asyncÈs(ÿ   ñz1ReplicationsService.patch_replication_by_id_asyncc Ksìtƒ}ddddg}| d||¡d|ks4|ddkr>> thread = api.post_replication(replication_creation_request, async_req=True) >>> result = thread.get() :param async_req bool :param ReplicationCreationRequest replication_creation_request: (required) :param str zap_trace_span: OpenTracing span context :param bool validate: If true, validate the replication, but don't save it. :return: Replication If the method is called asynchronously, returns the request thread. Tr rN)rÚpost_replication_with_http_info)rÚreplication_creation_requestrrr r r Úpost_replications  z$ReplicationsService.post_replicationcKsf|j|f|Ž\}}}}}|jjdd||||gidg| d¡| d¡| dd¡| d¡i| d d ¡d S) a½Register a new replication. This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.post_replication_with_http_info(replication_creation_request, async_req=True) >>> result = thread.get() :param async_req bool :param ReplicationCreationRequest replication_creation_request: (required) :param str zap_trace_span: OpenTracing span context :param bool validate: If true, validate the replication, but don't save it. :return: Replication If the method is called asynchronously, returns the request thread. r>ÚPOSTr7rr rTrrNr©Ú_post_replication_preparerr r©rrRrr"r#r$r%r&r r r rQ(s( ÿ   ñz3ReplicationsService.post_replication_with_http_infocËsl|j|f|Ž\}}}}}|jjdd||||gidg| d¡| d¡| dd¡| d¡i| d d ¡d Id HS) aâRegister a new replication. This method makes an asynchronous HTTP request. :param async_req bool :param ReplicationCreationRequest replication_creation_request: (required) :param str zap_trace_span: OpenTracing span context :param bool validate: If true, validate the replication, but don't save it. :return: Replication If the method is called asynchronously, returns the request thread. r>rTr7rr rTrrNrrUrWr r r Úpost_replication_asyncLs( ÿ   ñz*ReplicationsService.post_replication_asyncc Ksºtƒ}dddg}| d||¡d|ks2|ddkr:tdƒ‚i}g}d|kr\| d|df¡i}d|krt|d|d<d}d|krˆ|d}|j dg¡|d<|j dg¡|d <|||||fS) NrRr(rNrSz]Missing the required parameter `replication_creation_request` when calling `post_replication`r*r+r,rOrP) rrRrr"r3r#r$r%r&r r r rVms0  ÿ ÿÿz-ReplicationsService._post_replication_preparecKs6d|d<| d¡r |j|f|ŽS|j|f|Ž}|SdS)a+Validate a replication. This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.post_validate_replication_by_id(replication_id, async_req=True) >>> result = thread.get() :param async_req bool :param str replication_id: (required) :param str zap_trace_span: OpenTracing span context :return: None If the method is called asynchronously, returns the request thread. Tr rN)rÚ.post_validate_replication_by_id_with_http_inforr r r Úpost_validate_replication_by_idŽs  z3ReplicationsService.post_validate_replication_by_idcKsf|j|f|Ž\}}}}}|jjdd||||gidg| d¡| d¡| dd¡| d¡i| d d¡d S) a:Validate a replication. This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.post_validate_replication_by_id_with_http_info(replication_id, async_req=True) >>> result = thread.get() :param async_req bool :param str replication_id: (required) :param str zap_trace_span: OpenTracing span context :return: None If the method is called asynchronously, returns the request thread. ú-/api/v2/replications/{replicationID}/validaterTNrr rTrrr©Ú(_post_validate_replication_by_id_preparerr rr!r r r rY¤s( ÿ   ñzBReplicationsService.post_validate_replication_by_id_with_http_infocËsl|j|f|Ž\}}}}}|jjdd||||gidg| d¡| d¡| dd¡| d¡i| d d¡d IdHS) a^Validate a replication. This method makes an asynchronous HTTP request. :param async_req bool :param str replication_id: (required) :param str zap_trace_span: OpenTracing span context :return: None If the method is called asynchronously, returns the request thread. r[rTNrr rTrrrr\r!r r r Ú%post_validate_replication_by_id_asyncÇs( ÿ   ñz9ReplicationsService.post_validate_replication_by_id_asyncc Kstƒ}ddg}| d||¡d|ks0|ddkr8tdƒ‚i}d|krP|d|d<g}i}d|krl|d|d<d}|j dg¡|d<|||||fS) Nrr(rZz^Missing the required parameter `replication_id` when calling `post_validate_replication_by_id`r)r*r+r,r-r2r r r r]çs& ÿ  ÿzs