12
12
from azure .core .rest import HttpRequest , HttpResponse
13
13
from azure .mgmt .core import ARMPipelineClient
14
14
15
- from . import models
15
+ from . import models as _models
16
16
from ._configuration import CosmosDBManagementClientConfiguration
17
17
from ._serialization import Deserializer , Serializer
18
18
from .operations import (
23
23
CollectionPartitionOperations ,
24
24
CollectionPartitionRegionOperations ,
25
25
CollectionRegionOperations ,
26
- DataTransferJobsOperations ,
27
26
DatabaseAccountRegionOperations ,
28
27
DatabaseAccountsOperations ,
29
28
DatabaseOperations ,
30
- GraphResourcesOperations ,
31
29
GremlinResourcesOperations ,
32
30
LocationsOperations ,
33
31
MongoDBResourcesOperations ,
@@ -95,8 +93,6 @@ class CosmosDBManagementClient: # pylint: disable=client-accepts-api-version-ke
95
93
:ivar partition_key_range_id_region: PartitionKeyRangeIdRegionOperations operations
96
94
:vartype partition_key_range_id_region:
97
95
azure.mgmt.cosmosdb.operations.PartitionKeyRangeIdRegionOperations
98
- :ivar graph_resources: GraphResourcesOperations operations
99
- :vartype graph_resources: azure.mgmt.cosmosdb.operations.GraphResourcesOperations
100
96
:ivar sql_resources: SqlResourcesOperations operations
101
97
:vartype sql_resources: azure.mgmt.cosmosdb.operations.SqlResourcesOperations
102
98
:ivar mongo_db_resources: MongoDBResourcesOperations operations
@@ -109,8 +105,6 @@ class CosmosDBManagementClient: # pylint: disable=client-accepts-api-version-ke
109
105
:vartype gremlin_resources: azure.mgmt.cosmosdb.operations.GremlinResourcesOperations
110
106
:ivar locations: LocationsOperations operations
111
107
:vartype locations: azure.mgmt.cosmosdb.operations.LocationsOperations
112
- :ivar data_transfer_jobs: DataTransferJobsOperations operations
113
- :vartype data_transfer_jobs: azure.mgmt.cosmosdb.operations.DataTransferJobsOperations
114
108
:ivar cassandra_clusters: CassandraClustersOperations operations
115
109
:vartype cassandra_clusters: azure.mgmt.cosmosdb.operations.CassandraClustersOperations
116
110
:ivar cassandra_data_centers: CassandraDataCentersOperations operations
@@ -165,8 +159,8 @@ class CosmosDBManagementClient: # pylint: disable=client-accepts-api-version-ke
165
159
:type subscription_id: str
166
160
:param base_url: Service URL. Default value is "https://management.azure.com".
167
161
:type base_url: str
168
- :keyword api_version: Api Version. Default value is "2022-08 -15-preview ". Note that overriding
169
- this default value may result in unsupported behavior.
162
+ :keyword api_version: Api Version. Default value is "2022-11 -15". Note that overriding this
163
+ default value may result in unsupported behavior.
170
164
:paramtype api_version: str
171
165
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no
172
166
Retry-After header is present.
@@ -184,7 +178,7 @@ def __init__(
184
178
)
185
179
self ._client = ARMPipelineClient (base_url = base_url , config = self ._config , ** kwargs )
186
180
187
- client_models = {k : v for k , v in models .__dict__ .items () if isinstance (v , type )}
181
+ client_models = {k : v for k , v in _models .__dict__ .items () if isinstance (v , type )}
188
182
self ._serialize = Serializer (client_models )
189
183
self ._deserialize = Deserializer (client_models )
190
184
self ._serialize .client_side_validation = False
@@ -219,7 +213,6 @@ def __init__(
219
213
self .partition_key_range_id_region = PartitionKeyRangeIdRegionOperations (
220
214
self ._client , self ._config , self ._serialize , self ._deserialize
221
215
)
222
- self .graph_resources = GraphResourcesOperations (self ._client , self ._config , self ._serialize , self ._deserialize )
223
216
self .sql_resources = SqlResourcesOperations (self ._client , self ._config , self ._serialize , self ._deserialize )
224
217
self .mongo_db_resources = MongoDBResourcesOperations (
225
218
self ._client , self ._config , self ._serialize , self ._deserialize
@@ -232,9 +225,6 @@ def __init__(
232
225
self ._client , self ._config , self ._serialize , self ._deserialize
233
226
)
234
227
self .locations = LocationsOperations (self ._client , self ._config , self ._serialize , self ._deserialize )
235
- self .data_transfer_jobs = DataTransferJobsOperations (
236
- self ._client , self ._config , self ._serialize , self ._deserialize
237
- )
238
228
self .cassandra_clusters = CassandraClustersOperations (
239
229
self ._client , self ._config , self ._serialize , self ._deserialize
240
230
)
@@ -310,15 +300,12 @@ def _send_request(self, request: HttpRequest, **kwargs: Any) -> HttpResponse:
310
300
request_copy .url = self ._client .format_url (request_copy .url )
311
301
return self ._client .send_request (request_copy , ** kwargs )
312
302
313
- def close (self ):
314
- # type: () -> None
303
+ def close (self ) -> None :
315
304
self ._client .close ()
316
305
317
- def __enter__ (self ):
318
- # type: () -> CosmosDBManagementClient
306
+ def __enter__ (self ) -> "CosmosDBManagementClient" :
319
307
self ._client .__enter__ ()
320
308
return self
321
309
322
- def __exit__ (self , * exc_details ):
323
- # type: (Any) -> None
310
+ def __exit__ (self , * exc_details ) -> None :
324
311
self ._client .__exit__ (* exc_details )
0 commit comments