From ce2cd5ff64b55582c5e9ec323fb73c70619eb1aa Mon Sep 17 00:00:00 2001 From: Azure SDK for Python bot Date: Tue, 19 Jun 2018 12:13:46 -0700 Subject: [PATCH 1/5] Generated from 6d9c73eb24e60d117da852b974504d93e47d1a3c (#2744) renaming older operation --- .../database_accounts_operations.py | 67 ++++++++++++++++++- .../azure/mgmt/cosmosdb/version.py | 2 +- 2 files changed, 67 insertions(+), 2 deletions(-) diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_accounts_operations.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_accounts_operations.py index c8e3a2f2a818..c0f783a3fa69 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_accounts_operations.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_accounts_operations.py @@ -927,6 +927,71 @@ def get_long_running_output(response): return LROPoller(self._client, raw_result, get_long_running_output, polling_method) online_region.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/onlineRegion'} + def get_read_only_keys( + self, resource_group_name, account_name, custom_headers=None, raw=False, **operation_config): + """Lists the read-only access keys for the specified Azure Cosmos DB + database account. + + :param resource_group_name: Name of an Azure resource group. + :type resource_group_name: str + :param account_name: Cosmos DB database account name. + :type account_name: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: DatabaseAccountListReadOnlyKeysResult or ClientRawResponse if + raw=true + :rtype: + ~azure.mgmt.cosmosdb.models.DatabaseAccountListReadOnlyKeysResult or + ~msrest.pipeline.ClientRawResponse + :raises: :class:`CloudError` + """ + # Construct URL + url = self.get_read_only_keys.metadata['url'] + path_format_arguments = { + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'accountName': self._serialize.url("account_name", account_name, 'str', max_length=50, min_length=3) + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.get(url, query_parameters) + response = self._client.send(request, header_parameters, stream=False, **operation_config) + + if response.status_code not in [200]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('DatabaseAccountListReadOnlyKeysResult', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + get_read_only_keys.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/readonlykeys'} + def list_read_only_keys( self, resource_group_name, account_name, custom_headers=None, raw=False, **operation_config): """Lists the read-only access keys for the specified Azure Cosmos DB @@ -972,7 +1037,7 @@ def list_read_only_keys( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) + request = self._client.post(url, query_parameters) response = self._client.send(request, header_parameters, stream=False, **operation_config) if response.status_code not in [200]: diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/version.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/version.py index e9983c0d8c01..3e682bbd5fb1 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/version.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/version.py @@ -9,5 +9,5 @@ # regenerated. # -------------------------------------------------------------------------- -VERSION = "0.4.1" +VERSION = "0.3.0" From ca7eae41396da9334701ccf4a69ca828ef27c1b7 Mon Sep 17 00:00:00 2001 From: Azure SDK for Python bot Date: Tue, 2 Oct 2018 11:11:59 -0700 Subject: [PATCH 2/5] [AutoPR cosmos-db/resource-manager] Adding parameter enableMultipleWriteLocations in Cosmos DB (#3466) * Generated from 6b73420d0a83a786389d2ef92484aa8df383c74a adding parameter enableMultipleWriteLocations when creating account to support multi-master * Packaging update of azure-mgmt-cosmosdb --- azure-mgmt-cosmosdb/MANIFEST.in | 1 - azure-mgmt-cosmosdb/README.rst | 8 +- azure-mgmt-cosmosdb/azure/__init__.py | 2 +- azure-mgmt-cosmosdb/azure/mgmt/__init__.py | 2 +- .../mgmt/cosmosdb/models/database_account.py | 5 + ...tabase_account_create_update_parameters.py | 5 + ...se_account_create_update_parameters_py3.py | 7 +- .../cosmosdb/models/database_account_py3.py | 7 +- .../operations/collection_operations.py | 21 ++-- .../collection_partition_operations.py | 14 +-- .../collection_partition_region_operations.py | 7 +- .../collection_region_operations.py | 7 +- .../database_account_region_operations.py | 7 +- .../database_accounts_operations.py | 107 ++++++++---------- .../operations/database_operations.py | 21 ++-- .../mgmt/cosmosdb/operations/operations.py | 7 +- .../partition_key_range_id_operations.py | 7 +- ...artition_key_range_id_region_operations.py | 7 +- .../operations/percentile_operations.py | 7 +- .../percentile_source_target_operations.py | 7 +- .../percentile_target_operations.py | 7 +- azure-mgmt-cosmosdb/azure_bdist_wheel.py | 54 --------- azure-mgmt-cosmosdb/sdk_packaging.toml | 7 ++ azure-mgmt-cosmosdb/setup.cfg | 1 - azure-mgmt-cosmosdb/setup.py | 23 ++-- 25 files changed, 147 insertions(+), 201 deletions(-) delete mode 100644 azure-mgmt-cosmosdb/azure_bdist_wheel.py create mode 100644 azure-mgmt-cosmosdb/sdk_packaging.toml diff --git a/azure-mgmt-cosmosdb/MANIFEST.in b/azure-mgmt-cosmosdb/MANIFEST.in index 9ecaeb15de50..bb37a2723dae 100644 --- a/azure-mgmt-cosmosdb/MANIFEST.in +++ b/azure-mgmt-cosmosdb/MANIFEST.in @@ -1,2 +1 @@ include *.rst -include azure_bdist_wheel.py \ No newline at end of file diff --git a/azure-mgmt-cosmosdb/README.rst b/azure-mgmt-cosmosdb/README.rst index 4a958d34b8db..45de4e6b43dd 100644 --- a/azure-mgmt-cosmosdb/README.rst +++ b/azure-mgmt-cosmosdb/README.rst @@ -1,12 +1,12 @@ Microsoft Azure SDK for Python ============================== -This is the Microsoft Azure Cosmos DB Management Client Library. +This is the Microsoft Azure MyService Management Client Library. Azure Resource Manager (ARM) is the next generation of management APIs that replace the old Azure Service Management (ASM). -This package has been tested with Python 2.7, 3.4, 3.5 and 3.6. +This package has been tested with Python 2.7, 3.4, 3.5, 3.6 and 3.7. For the older Azure Service Management (ASM) libraries, see `azure-servicemanagement-legacy `__ library. @@ -36,8 +36,8 @@ If you see azure==0.11.0 (or any version below 1.0), uninstall it first: Usage ===== -For code examples, see `CosmosDB Management -`__ +For code examples, see `MyService Management +`__ on docs.microsoft.com. diff --git a/azure-mgmt-cosmosdb/azure/__init__.py b/azure-mgmt-cosmosdb/azure/__init__.py index 849489fca33c..0260537a02bb 100644 --- a/azure-mgmt-cosmosdb/azure/__init__.py +++ b/azure-mgmt-cosmosdb/azure/__init__.py @@ -1 +1 @@ -__import__('pkg_resources').declare_namespace(__name__) +__path__ = __import__('pkgutil').extend_path(__path__, __name__) \ No newline at end of file diff --git a/azure-mgmt-cosmosdb/azure/mgmt/__init__.py b/azure-mgmt-cosmosdb/azure/mgmt/__init__.py index 849489fca33c..0260537a02bb 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/__init__.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/__init__.py @@ -1 +1 @@ -__import__('pkg_resources').declare_namespace(__name__) +__path__ = __import__('pkgutil').extend_path(__path__, __name__) \ No newline at end of file diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account.py index f746e080e25f..debded86eed7 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account.py @@ -77,6 +77,9 @@ class DatabaseAccount(Resource): for the Cosmos DB account. :type virtual_network_rules: list[~azure.mgmt.cosmosdb.models.VirtualNetworkRule] + :param enable_multiple_write_locations: Enables the account to write in + multiple locations + :type enable_multiple_write_locations: bool """ _validation = { @@ -110,6 +113,7 @@ class DatabaseAccount(Resource): 'read_locations': {'key': 'properties.readLocations', 'type': '[Location]'}, 'failover_policies': {'key': 'properties.failoverPolicies', 'type': '[FailoverPolicy]'}, 'virtual_network_rules': {'key': 'properties.virtualNetworkRules', 'type': '[VirtualNetworkRule]'}, + 'enable_multiple_write_locations': {'key': 'properties.enableMultipleWriteLocations', 'type': 'bool'}, } def __init__(self, **kwargs): @@ -127,3 +131,4 @@ def __init__(self, **kwargs): self.read_locations = None self.failover_policies = None self.virtual_network_rules = kwargs.get('virtual_network_rules', None) + self.enable_multiple_write_locations = kwargs.get('enable_multiple_write_locations', None) diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account_create_update_parameters.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account_create_update_parameters.py index 4cd363937f05..9ff548fc3efb 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account_create_update_parameters.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account_create_update_parameters.py @@ -62,6 +62,9 @@ class DatabaseAccountCreateUpdateParameters(Resource): for the Cosmos DB account. :type virtual_network_rules: list[~azure.mgmt.cosmosdb.models.VirtualNetworkRule] + :param enable_multiple_write_locations: Enables the account to write in + multiple locations + :type enable_multiple_write_locations: bool """ _validation = { @@ -88,6 +91,7 @@ class DatabaseAccountCreateUpdateParameters(Resource): 'enable_automatic_failover': {'key': 'properties.enableAutomaticFailover', 'type': 'bool'}, 'capabilities': {'key': 'properties.capabilities', 'type': '[Capability]'}, 'virtual_network_rules': {'key': 'properties.virtualNetworkRules', 'type': '[VirtualNetworkRule]'}, + 'enable_multiple_write_locations': {'key': 'properties.enableMultipleWriteLocations', 'type': 'bool'}, } database_account_offer_type = "Standard" @@ -102,3 +106,4 @@ def __init__(self, **kwargs): self.enable_automatic_failover = kwargs.get('enable_automatic_failover', None) self.capabilities = kwargs.get('capabilities', None) self.virtual_network_rules = kwargs.get('virtual_network_rules', None) + self.enable_multiple_write_locations = kwargs.get('enable_multiple_write_locations', None) diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account_create_update_parameters_py3.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account_create_update_parameters_py3.py index f8e8e78ee597..491e8e27b2a8 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account_create_update_parameters_py3.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account_create_update_parameters_py3.py @@ -62,6 +62,9 @@ class DatabaseAccountCreateUpdateParameters(Resource): for the Cosmos DB account. :type virtual_network_rules: list[~azure.mgmt.cosmosdb.models.VirtualNetworkRule] + :param enable_multiple_write_locations: Enables the account to write in + multiple locations + :type enable_multiple_write_locations: bool """ _validation = { @@ -88,11 +91,12 @@ class DatabaseAccountCreateUpdateParameters(Resource): 'enable_automatic_failover': {'key': 'properties.enableAutomaticFailover', 'type': 'bool'}, 'capabilities': {'key': 'properties.capabilities', 'type': '[Capability]'}, 'virtual_network_rules': {'key': 'properties.virtualNetworkRules', 'type': '[VirtualNetworkRule]'}, + 'enable_multiple_write_locations': {'key': 'properties.enableMultipleWriteLocations', 'type': 'bool'}, } database_account_offer_type = "Standard" - def __init__(self, *, location: str, locations, tags=None, kind="GlobalDocumentDB", consistency_policy=None, ip_range_filter: str=None, is_virtual_network_filter_enabled: bool=None, enable_automatic_failover: bool=None, capabilities=None, virtual_network_rules=None, **kwargs) -> None: + def __init__(self, *, location: str, locations, tags=None, kind="GlobalDocumentDB", consistency_policy=None, ip_range_filter: str=None, is_virtual_network_filter_enabled: bool=None, enable_automatic_failover: bool=None, capabilities=None, virtual_network_rules=None, enable_multiple_write_locations: bool=None, **kwargs) -> None: super(DatabaseAccountCreateUpdateParameters, self).__init__(location=location, tags=tags, **kwargs) self.kind = kind self.consistency_policy = consistency_policy @@ -102,3 +106,4 @@ def __init__(self, *, location: str, locations, tags=None, kind="GlobalDocumentD self.enable_automatic_failover = enable_automatic_failover self.capabilities = capabilities self.virtual_network_rules = virtual_network_rules + self.enable_multiple_write_locations = enable_multiple_write_locations diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account_py3.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account_py3.py index d0c6e603e9d6..98d545f416e0 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account_py3.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/models/database_account_py3.py @@ -77,6 +77,9 @@ class DatabaseAccount(Resource): for the Cosmos DB account. :type virtual_network_rules: list[~azure.mgmt.cosmosdb.models.VirtualNetworkRule] + :param enable_multiple_write_locations: Enables the account to write in + multiple locations + :type enable_multiple_write_locations: bool """ _validation = { @@ -110,9 +113,10 @@ class DatabaseAccount(Resource): 'read_locations': {'key': 'properties.readLocations', 'type': '[Location]'}, 'failover_policies': {'key': 'properties.failoverPolicies', 'type': '[FailoverPolicy]'}, 'virtual_network_rules': {'key': 'properties.virtualNetworkRules', 'type': '[VirtualNetworkRule]'}, + 'enable_multiple_write_locations': {'key': 'properties.enableMultipleWriteLocations', 'type': 'bool'}, } - def __init__(self, *, location: str, tags=None, kind="GlobalDocumentDB", provisioning_state: str=None, ip_range_filter: str=None, is_virtual_network_filter_enabled: bool=None, enable_automatic_failover: bool=None, consistency_policy=None, capabilities=None, virtual_network_rules=None, **kwargs) -> None: + def __init__(self, *, location: str, tags=None, kind="GlobalDocumentDB", provisioning_state: str=None, ip_range_filter: str=None, is_virtual_network_filter_enabled: bool=None, enable_automatic_failover: bool=None, consistency_policy=None, capabilities=None, virtual_network_rules=None, enable_multiple_write_locations: bool=None, **kwargs) -> None: super(DatabaseAccount, self).__init__(location=location, tags=tags, **kwargs) self.kind = kind self.provisioning_state = provisioning_state @@ -127,3 +131,4 @@ def __init__(self, *, location: str, tags=None, kind="GlobalDocumentDB", provisi self.read_locations = None self.failover_policies = None self.virtual_network_rules = virtual_network_rules + self.enable_multiple_write_locations = enable_multiple_write_locations diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_operations.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_operations.py index b5dc016df775..38a75081f098 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_operations.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_operations.py @@ -90,7 +90,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -99,9 +99,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -174,7 +173,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -183,9 +182,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -251,7 +249,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -260,9 +258,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_partition_operations.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_partition_operations.py index 7161a7d94b99..4b50575a8080 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_partition_operations.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_partition_operations.py @@ -90,7 +90,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -99,9 +99,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -174,7 +173,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -183,9 +182,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_partition_region_operations.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_partition_region_operations.py index 6e0db4e6a432..ee0114b6834d 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_partition_region_operations.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_partition_region_operations.py @@ -94,7 +94,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -103,9 +103,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_region_operations.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_region_operations.py index de907ce6479b..52f7f1696eb9 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_region_operations.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/collection_region_operations.py @@ -94,7 +94,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -103,9 +103,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_account_region_operations.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_account_region_operations.py index 787b0bae785b..114759936361 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_account_region_operations.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_account_region_operations.py @@ -88,7 +88,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -97,9 +97,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_accounts_operations.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_accounts_operations.py index c0f783a3fa69..b486f0ec380e 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_accounts_operations.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_accounts_operations.py @@ -73,7 +73,7 @@ def get( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -82,8 +82,8 @@ def get( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -122,6 +122,7 @@ def _patch_initial( # Construct headers header_parameters = {} + header_parameters['Accept'] = 'application/json' header_parameters['Content-Type'] = 'application/json; charset=utf-8' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) @@ -134,9 +135,8 @@ def _patch_initial( body_content = self._serialize.body(update_parameters, 'DatabaseAccountPatchParameters') # Construct and send request - request = self._client.patch(url, query_parameters) - response = self._client.send( - request, header_parameters, body_content, stream=False, **operation_config) + request = self._client.patch(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -225,6 +225,7 @@ def _create_or_update_initial( # Construct headers header_parameters = {} + header_parameters['Accept'] = 'application/json' header_parameters['Content-Type'] = 'application/json; charset=utf-8' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) @@ -237,9 +238,8 @@ def _create_or_update_initial( body_content = self._serialize.body(create_update_parameters, 'DatabaseAccountCreateUpdateParameters') # Construct and send request - request = self._client.put(url, query_parameters) - response = self._client.send( - request, header_parameters, body_content, stream=False, **operation_config) + request = self._client.put(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -327,7 +327,6 @@ def _delete_initial( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -336,8 +335,8 @@ def _delete_initial( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.delete(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.delete(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [202, 204]: exp = CloudError(response) @@ -421,9 +420,8 @@ def _failover_priority_change_initial( body_content = self._serialize.body(failover_parameters, 'FailoverPolicies') # Construct and send request - request = self._client.post(url, query_parameters) - response = self._client.send( - request, header_parameters, body_content, stream=False, **operation_config) + request = self._client.post(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [202, 204]: exp = CloudError(response) @@ -518,7 +516,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -527,9 +525,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -587,7 +584,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -596,9 +593,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -653,7 +649,7 @@ def list_keys( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -662,8 +658,8 @@ def list_keys( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.post(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.post(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -718,7 +714,7 @@ def list_connection_strings( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -727,8 +723,8 @@ def list_connection_strings( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.post(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.post(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -779,9 +775,8 @@ def _offline_region_initial( body_content = self._serialize.body(region_parameter_for_offline, 'RegionForOnlineOffline') # Construct and send request - request = self._client.post(url, query_parameters) - response = self._client.send( - request, header_parameters, body_content, stream=False, **operation_config) + request = self._client.post(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 202]: raise models.ErrorResponseException(self._deserialize, response) @@ -869,9 +864,8 @@ def _online_region_initial( body_content = self._serialize.body(region_parameter_for_online, 'RegionForOnlineOffline') # Construct and send request - request = self._client.post(url, query_parameters) - response = self._client.send( - request, header_parameters, body_content, stream=False, **operation_config) + request = self._client.post(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 202]: raise models.ErrorResponseException(self._deserialize, response) @@ -963,7 +957,7 @@ def get_read_only_keys( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -972,8 +966,8 @@ def get_read_only_keys( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -1028,7 +1022,7 @@ def list_read_only_keys( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -1037,8 +1031,8 @@ def list_read_only_keys( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.post(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.post(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -1089,9 +1083,8 @@ def _regenerate_key_initial( body_content = self._serialize.body(key_to_regenerate, 'DatabaseAccountRegenerateKeyParameters') # Construct and send request - request = self._client.post(url, query_parameters) - response = self._client.send( - request, header_parameters, body_content, stream=False, **operation_config) + request = self._client.post(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 202]: exp = CloudError(response) @@ -1179,7 +1172,6 @@ def check_name_exists( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -1188,8 +1180,8 @@ def check_name_exists( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.head(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.head(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 404]: exp = CloudError(response) @@ -1250,7 +1242,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -1259,9 +1251,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -1327,7 +1318,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -1336,9 +1327,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -1398,7 +1388,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -1407,9 +1397,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_operations.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_operations.py index c9cb0713069b..626e2282f4a2 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_operations.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/database_operations.py @@ -87,7 +87,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -96,9 +96,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -167,7 +166,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -176,9 +175,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -241,7 +239,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -250,9 +248,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/operations.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/operations.py index 245c7d5749b6..083e13901b83 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/operations.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/operations.py @@ -67,7 +67,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -76,9 +76,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/partition_key_range_id_operations.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/partition_key_range_id_operations.py index ae0f9366a7ba..a0860fa84e71 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/partition_key_range_id_operations.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/partition_key_range_id_operations.py @@ -94,7 +94,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -103,9 +103,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/partition_key_range_id_region_operations.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/partition_key_range_id_region_operations.py index d8299349f17a..2067f60b402e 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/partition_key_range_id_region_operations.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/partition_key_range_id_region_operations.py @@ -98,7 +98,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -107,9 +107,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/percentile_operations.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/percentile_operations.py index adf7d5313b57..07dead5e3111 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/percentile_operations.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/percentile_operations.py @@ -85,7 +85,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -94,9 +94,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/percentile_source_target_operations.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/percentile_source_target_operations.py index 45c02b4bba49..b2b667e70751 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/percentile_source_target_operations.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/percentile_source_target_operations.py @@ -93,7 +93,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -102,9 +102,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/percentile_target_operations.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/percentile_target_operations.py index 06395707cc59..58f5674bfdb3 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/percentile_target_operations.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/operations/percentile_target_operations.py @@ -89,7 +89,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -98,9 +98,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) diff --git a/azure-mgmt-cosmosdb/azure_bdist_wheel.py b/azure-mgmt-cosmosdb/azure_bdist_wheel.py deleted file mode 100644 index 8a81d1b61775..000000000000 --- a/azure-mgmt-cosmosdb/azure_bdist_wheel.py +++ /dev/null @@ -1,54 +0,0 @@ -#------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -#-------------------------------------------------------------------------- - -from distutils import log as logger -import os.path - -from wheel.bdist_wheel import bdist_wheel -class azure_bdist_wheel(bdist_wheel): - """The purpose of this class is to build wheel a little differently than the sdist, - without requiring to build the wheel from the sdist (i.e. you can build the wheel - directly from source). - """ - - description = "Create an Azure wheel distribution" - - user_options = bdist_wheel.user_options + \ - [('azure-namespace-package=', None, - "Name of the deepest nspkg used")] - - def initialize_options(self): - bdist_wheel.initialize_options(self) - self.azure_namespace_package = None - - def finalize_options(self): - bdist_wheel.finalize_options(self) - if self.azure_namespace_package and not self.azure_namespace_package.endswith("-nspkg"): - raise ValueError("azure_namespace_package must finish by -nspkg") - - def run(self): - if not self.distribution.install_requires: - self.distribution.install_requires = [] - self.distribution.install_requires.append( - "{}>=2.0.0".format(self.azure_namespace_package)) - bdist_wheel.run(self) - - def write_record(self, bdist_dir, distinfo_dir): - if self.azure_namespace_package: - # Split and remove last part, assuming it's "nspkg" - subparts = self.azure_namespace_package.split('-')[0:-1] - folder_with_init = [os.path.join(*subparts[0:i+1]) for i in range(len(subparts))] - for azure_sub_package in folder_with_init: - init_file = os.path.join(bdist_dir, azure_sub_package, '__init__.py') - if os.path.isfile(init_file): - logger.info("manually remove {} while building the wheel".format(init_file)) - os.remove(init_file) - else: - raise ValueError("Unable to find {}. Are you sure of your namespace package?".format(init_file)) - bdist_wheel.write_record(self, bdist_dir, distinfo_dir) -cmdclass = { - 'bdist_wheel': azure_bdist_wheel, -} diff --git a/azure-mgmt-cosmosdb/sdk_packaging.toml b/azure-mgmt-cosmosdb/sdk_packaging.toml new file mode 100644 index 000000000000..c6e64b5f08d9 --- /dev/null +++ b/azure-mgmt-cosmosdb/sdk_packaging.toml @@ -0,0 +1,7 @@ +[packaging] +package_name = "azure-mgmt-cosmosdb" +package_nspkg = "azure-mgmt-nspkg" +package_pprint_name = "MyService Management" +package_doc_id = "" +is_stable = false +is_arm = true diff --git a/azure-mgmt-cosmosdb/setup.cfg b/azure-mgmt-cosmosdb/setup.cfg index 856f4164982c..3c6e79cf31da 100644 --- a/azure-mgmt-cosmosdb/setup.cfg +++ b/azure-mgmt-cosmosdb/setup.cfg @@ -1,3 +1,2 @@ [bdist_wheel] universal=1 -azure-namespace-package=azure-mgmt-nspkg \ No newline at end of file diff --git a/azure-mgmt-cosmosdb/setup.py b/azure-mgmt-cosmosdb/setup.py index e6eefb660f17..9e03995d75fb 100644 --- a/azure-mgmt-cosmosdb/setup.py +++ b/azure-mgmt-cosmosdb/setup.py @@ -10,16 +10,10 @@ import os.path from io import open from setuptools import find_packages, setup -try: - from azure_bdist_wheel import cmdclass -except ImportError: - from distutils import log as logger - logger.warn("Wheel is not available, disabling bdist_wheel hook") - cmdclass = {} # Change the PACKAGE_NAME only to change folder and different name PACKAGE_NAME = "azure-mgmt-cosmosdb" -PACKAGE_PPRINT_NAME = "Cosmos DB Management" +PACKAGE_PPRINT_NAME = "MyService Management" # a-b-c => a/b/c package_folder_path = PACKAGE_NAME.replace('-', '/') @@ -72,13 +66,22 @@ 'Programming Language :: Python :: 3.4', 'Programming Language :: Python :: 3.5', 'Programming Language :: Python :: 3.6', + 'Programming Language :: Python :: 3.7', 'License :: OSI Approved :: MIT License', ], zip_safe=False, - packages=find_packages(exclude=["tests"]), + packages=find_packages(exclude=[ + 'tests', + # Exclude packages that will be covered by PEP420 or nspkg + 'azure', + 'azure.mgmt', + ]), install_requires=[ - 'msrestazure>=0.4.20,<2.0.0', + 'msrest>=0.5.0', + 'msrestazure>=0.4.32,<2.0.0', 'azure-common~=1.1', ], - cmdclass=cmdclass + extras_require={ + ":python_version<'3.0'": ['azure-mgmt-nspkg'], + } ) From 079cce4ac2daa1a70432553f828d5512e0f34b87 Mon Sep 17 00:00:00 2001 From: azuresdkci Date: Mon, 8 Oct 2018 19:06:52 +0000 Subject: [PATCH 3/5] Packaging update of azure-mgmt-cosmosdb --- azure-mgmt-cosmosdb/README.rst | 2 +- azure-mgmt-cosmosdb/setup.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/azure-mgmt-cosmosdb/README.rst b/azure-mgmt-cosmosdb/README.rst index 19c481fac3c7..82bd979c7bf5 100644 --- a/azure-mgmt-cosmosdb/README.rst +++ b/azure-mgmt-cosmosdb/README.rst @@ -1,7 +1,7 @@ Microsoft Azure SDK for Python ============================== -This is the Microsoft Azure MyService Management Client Library. +This is the Microsoft Azure Cosmos DB Management Client Library. Azure Resource Manager (ARM) is the next generation of management APIs that replace the old Azure Service Management (ASM). diff --git a/azure-mgmt-cosmosdb/setup.py b/azure-mgmt-cosmosdb/setup.py index 9e03995d75fb..4bec3ee72d0e 100644 --- a/azure-mgmt-cosmosdb/setup.py +++ b/azure-mgmt-cosmosdb/setup.py @@ -13,7 +13,7 @@ # Change the PACKAGE_NAME only to change folder and different name PACKAGE_NAME = "azure-mgmt-cosmosdb" -PACKAGE_PPRINT_NAME = "MyService Management" +PACKAGE_PPRINT_NAME = "Cosmos DB Management" # a-b-c => a/b/c package_folder_path = PACKAGE_NAME.replace('-', '/') From 37e5c8c075a4f018319f452a94ce24412b47cb99 Mon Sep 17 00:00:00 2001 From: Laurent Mazuel Date: Mon, 8 Oct 2018 13:48:35 -0700 Subject: [PATCH 4/5] Re-record tests --- ..._mgmt_cosmosdb.test_accounts_features.yaml | 679 ++++++++++++------ 1 file changed, 470 insertions(+), 209 deletions(-) diff --git a/azure-mgmt-cosmosdb/tests/recordings/test_mgmt_cosmosdb.test_accounts_features.yaml b/azure-mgmt-cosmosdb/tests/recordings/test_mgmt_cosmosdb.test_accounts_features.yaml index 5f09243f4a03..37bba0514a3a 100644 --- a/azure-mgmt-cosmosdb/tests/recordings/test_mgmt_cosmosdb.test_accounts_features.yaml +++ b/azure-mgmt-cosmosdb/tests/recordings/test_mgmt_cosmosdb.test_accounts_features.yaml @@ -1,39 +1,371 @@ interactions: - request: - body: null + body: '{"location": "westus", "properties": {"locations": [{"locationName": "westus"}], + "databaseAccountOfferType": "Standard"}}' headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] + Content-Length: ['121'] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.1 (Windows-10-10.0.15063-SP0) requests/2.17.3 msrest/0.4.11 - msrest_azure/0.4.9 cosmosdb/0.2.0 Azure-SDK-For-Python] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] + accept-language: [en-US] + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9?api-version=2015-04-08 + response: + body: {string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9","name":"pycosmosdbtest640310f9","location":"West + US","type":"Microsoft.DocumentDB/databaseAccounts","kind":"GlobalDocumentDB","tags":{},"properties":{"provisioningState":"Initializing","ipRangeFilter":"","enableAutomaticFailover":false,"enableMultipleWriteLocations":false,"isVirtualNetworkFilterEnabled":false,"virtualNetworkRules":[],"databaseAccountOfferType":"Standard","consistencyPolicy":{"defaultConsistencyLevel":"Session","maxIntervalInSeconds":5,"maxStalenessPrefix":100},"configurationOverrides":{},"writeLocations":[{"id":"pycosmosdbtest640310f9-westus","locationName":"West + US","provisioningState":"Initializing","failoverPriority":0}],"readLocations":[{"id":"pycosmosdbtest640310f9-westus","locationName":"West + US","provisioningState":"Initializing","failoverPriority":0}],"failoverPolicies":[{"id":"pycosmosdbtest640310f9-westus","locationName":"West + US","failoverPriority":0}],"capabilities":[]}}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['1108'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:39:37 GMT'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + transfer-encoding: [chunked] + vary: [Accept-Encoding] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] + x-ms-ratelimit-remaining-subscription-writes: ['1199'] + status: {code: 200, message: Ok} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08 + response: + body: {string: '{"status":"Dequeued","error":{}}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['32'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:40:08 GMT'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] + status: {code: 202, message: Accepted} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08 + response: + body: {string: '{"status":"Dequeued","error":{}}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['32'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:40:39 GMT'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] + status: {code: 202, message: Accepted} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08 + response: + body: {string: '{"status":"Dequeued","error":{}}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['32'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:41:10 GMT'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] + status: {code: 202, message: Accepted} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08 + response: + body: {string: '{"status":"Dequeued","error":{}}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['32'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:41:40 GMT'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] + status: {code: 202, message: Accepted} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08 + response: + body: {string: '{"status":"Dequeued","error":{}}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['32'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:42:10 GMT'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] + status: {code: 202, message: Accepted} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08 + response: + body: {string: '{"status":"Dequeued","error":{}}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['32'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:42:41 GMT'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] + status: {code: 202, message: Accepted} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08 + response: + body: {string: '{"status":"Dequeued","error":{}}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['32'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:43:11 GMT'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] + status: {code: 202, message: Accepted} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08 + response: + body: {string: '{"status":"Dequeued","error":{}}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['32'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:43:42 GMT'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] + status: {code: 202, message: Accepted} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08 + response: + body: {string: '{"status":"Dequeued","error":{}}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['32'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:44:13 GMT'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] + status: {code: 202, message: Accepted} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08 + response: + body: {string: '{"status":"Dequeued","error":{}}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['32'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:44:42 GMT'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] + status: {code: 202, message: Accepted} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08 + response: + body: {string: '{"status":"Dequeued","error":{}}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['32'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:45:13 GMT'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] + status: {code: 202, message: Accepted} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08 + response: + body: {string: '{"status":"Succeeded","error":{}}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['33'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/operationResults/cd3ce313-dfed-4543-b03f-c5b6be1c7137?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:45:43 GMT'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + transfer-encoding: [chunked] + vary: [Accept-Encoding] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] + status: {code: 200, message: Ok} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + Connection: [keep-alive] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] accept-language: [en-US] - x-ms-client-request-id: [1f342912-5ad2-11e7-819b-ecb1d756380e] method: GET uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9?api-version=2015-04-08 response: body: {string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9","name":"pycosmosdbtest640310f9","location":"West - US","type":"Microsoft.DocumentDB/databaseAccounts","kind":"GlobalDocumentDB","tags":{},"properties":{"provisioningState":"Succeeded","documentEndpoint":"https://pycosmosdbtest640310f9.documents.azure.com:443/","ipRangeFilter":"","enableAutomaticFailover":false,"databaseAccountOfferType":"Standard","consistencyPolicy":{"defaultConsistencyLevel":"Session","maxIntervalInSeconds":5,"maxStalenessPrefix":100},"configurationOverrides":{},"writeLocations":[{"id":"pycosmosdbtest640310f9-westus","locationName":"West + US","type":"Microsoft.DocumentDB/databaseAccounts","kind":"GlobalDocumentDB","tags":{},"properties":{"provisioningState":"Succeeded","documentEndpoint":"https://pycosmosdbtest640310f9.documents.azure.com:443/","ipRangeFilter":"","enableAutomaticFailover":false,"enableMultipleWriteLocations":false,"isVirtualNetworkFilterEnabled":false,"virtualNetworkRules":[],"databaseAccountOfferType":"Standard","consistencyPolicy":{"defaultConsistencyLevel":"Session","maxIntervalInSeconds":5,"maxStalenessPrefix":100},"configurationOverrides":{},"writeLocations":[{"id":"pycosmosdbtest640310f9-westus","locationName":"West US","documentEndpoint":"https://pycosmosdbtest640310f9-westus.documents.azure.com:443/","provisioningState":"Succeeded","failoverPriority":0}],"readLocations":[{"id":"pycosmosdbtest640310f9-westus","locationName":"West US","documentEndpoint":"https://pycosmosdbtest640310f9-westus.documents.azure.com:443/","provisioningState":"Succeeded","failoverPriority":0}],"failoverPolicies":[{"id":"pycosmosdbtest640310f9-westus","locationName":"West - US","failoverPriority":0}]}}'} - headers: - Cache-Control: ['no-store, no-cache'] - Content-Location: ['https://management.documents.azure.com:450/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9?api-version=2015-04-08'] - Content-Type: [application/json] - Date: ['Tue, 27 Jun 2017 00:46:56 GMT'] - Pragma: [no-cache] - Server: [Microsoft-HTTPAPI/2.0] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Transfer-Encoding: [chunked] - Vary: [Accept-Encoding] - content-length: ['1226'] - x-ms-correlation-request-id: [7d397846-d2b3-48ca-b154-e48102d807c2] - x-ms-gatewayversion: [version=1.14.33.2] - x-ms-ratelimit-remaining-subscription-reads: ['14998'] - x-ms-request-id: [7d397846-d2b3-48ca-b154-e48102d807c2] - x-ms-routing-request-id: ['WESTUS:20170627T004657Z:7d397846-d2b3-48ca-b154-e48102d807c2'] + US","failoverPriority":0}],"capabilities":[]}}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['1344'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:45:44 GMT'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + transfer-encoding: [chunked] + vary: [Accept-Encoding] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] status: {code: 200, message: Ok} - request: body: null @@ -41,35 +373,30 @@ interactions: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.1 (Windows-10-10.0.15063-SP0) requests/2.17.3 msrest/0.4.11 - msrest_azure/0.4.9 cosmosdb/0.2.0 Azure-SDK-For-Python] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] accept-language: [en-US] - x-ms-client-request-id: [1f6748f6-5ad2-11e7-b4b0-ecb1d756380e] method: GET uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts?api-version=2015-04-08 response: body: {string: '{"value":[{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9","name":"pycosmosdbtest640310f9","location":"West - US","type":"Microsoft.DocumentDB/databaseAccounts","kind":"GlobalDocumentDB","tags":{},"properties":{"provisioningState":"Succeeded","documentEndpoint":"https://pycosmosdbtest640310f9.documents.azure.com:443/","ipRangeFilter":"","enableAutomaticFailover":false,"databaseAccountOfferType":"Standard","consistencyPolicy":{"defaultConsistencyLevel":"Session","maxIntervalInSeconds":5,"maxStalenessPrefix":100},"configurationOverrides":{},"writeLocations":[{"id":"pycosmosdbtest640310f9-westus","locationName":"West + US","type":"Microsoft.DocumentDB/databaseAccounts","kind":"GlobalDocumentDB","tags":{},"properties":{"provisioningState":"Succeeded","documentEndpoint":"https://pycosmosdbtest640310f9.documents.azure.com:443/","ipRangeFilter":"","enableAutomaticFailover":false,"enableMultipleWriteLocations":false,"isVirtualNetworkFilterEnabled":false,"virtualNetworkRules":[],"databaseAccountOfferType":"Standard","consistencyPolicy":{"defaultConsistencyLevel":"Session","maxIntervalInSeconds":5,"maxStalenessPrefix":100},"configurationOverrides":{},"writeLocations":[{"id":"pycosmosdbtest640310f9-westus","locationName":"West US","documentEndpoint":"https://pycosmosdbtest640310f9-westus.documents.azure.com:443/","provisioningState":"Succeeded","failoverPriority":0}],"readLocations":[{"id":"pycosmosdbtest640310f9-westus","locationName":"West US","documentEndpoint":"https://pycosmosdbtest640310f9-westus.documents.azure.com:443/","provisioningState":"Succeeded","failoverPriority":0}],"failoverPolicies":[{"id":"pycosmosdbtest640310f9-westus","locationName":"West - US","failoverPriority":0}]}}]}'} - headers: - Cache-Control: ['no-store, no-cache'] - Content-Location: ['https://management.documents.azure.com:450/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts?api-version=2015-04-08'] - Content-Type: [application/json] - Date: ['Tue, 27 Jun 2017 00:46:57 GMT'] - Pragma: [no-cache] - Server: [Microsoft-HTTPAPI/2.0] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Transfer-Encoding: [chunked] - Vary: [Accept-Encoding] - content-length: ['1238'] - x-ms-correlation-request-id: [93bfd4c6-c221-402a-9c3e-e5728ecd2e6f] - x-ms-gatewayversion: [version=1.14.55.2] - x-ms-ratelimit-remaining-subscription-reads: ['14999'] - x-ms-request-id: [93bfd4c6-c221-402a-9c3e-e5728ecd2e6f] - x-ms-routing-request-id: ['WESTUS:20170627T004658Z:93bfd4c6-c221-402a-9c3e-e5728ecd2e6f'] + US","failoverPriority":0}],"capabilities":[]}}]}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['1356'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:45:45 GMT'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + transfer-encoding: [chunked] + vary: [Accept-Encoding] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] status: {code: 200, message: Ok} - request: body: null @@ -77,39 +404,30 @@ interactions: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.1 (Windows-10-10.0.15063-SP0) requests/2.17.3 msrest/0.4.11 - msrest_azure/0.4.9 cosmosdb/0.2.0 Azure-SDK-For-Python] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] accept-language: [en-US] - x-ms-client-request-id: [1fe5f718-5ad2-11e7-bc76-ecb1d756380e] method: GET uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DocumentDB/databaseAccounts?api-version=2015-04-08 response: body: {string: '{"value":[{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9","name":"pycosmosdbtest640310f9","location":"West - US","type":"Microsoft.DocumentDB/databaseAccounts","kind":"GlobalDocumentDB","tags":{},"properties":{"provisioningState":"Succeeded","documentEndpoint":"https://pycosmosdbtest640310f9.documents.azure.com:443/","ipRangeFilter":"","enableAutomaticFailover":false,"databaseAccountOfferType":"Standard","consistencyPolicy":{"defaultConsistencyLevel":"Session","maxIntervalInSeconds":5,"maxStalenessPrefix":100},"configurationOverrides":{},"writeLocations":[{"id":"pycosmosdbtest640310f9-westus","locationName":"West + US","type":"Microsoft.DocumentDB/databaseAccounts","kind":"GlobalDocumentDB","tags":{},"properties":{"provisioningState":"Succeeded","documentEndpoint":"https://pycosmosdbtest640310f9.documents.azure.com:443/","ipRangeFilter":"","enableAutomaticFailover":false,"enableMultipleWriteLocations":false,"isVirtualNetworkFilterEnabled":false,"virtualNetworkRules":[],"databaseAccountOfferType":"Standard","consistencyPolicy":{"defaultConsistencyLevel":"Session","maxIntervalInSeconds":5,"maxStalenessPrefix":100},"configurationOverrides":{},"writeLocations":[{"id":"pycosmosdbtest640310f9-westus","locationName":"West US","documentEndpoint":"https://pycosmosdbtest640310f9-westus.documents.azure.com:443/","provisioningState":"Succeeded","failoverPriority":0}],"readLocations":[{"id":"pycosmosdbtest640310f9-westus","locationName":"West US","documentEndpoint":"https://pycosmosdbtest640310f9-westus.documents.azure.com:443/","provisioningState":"Succeeded","failoverPriority":0}],"failoverPolicies":[{"id":"pycosmosdbtest640310f9-westus","locationName":"West - US","failoverPriority":0}]}},{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/MonitorTestsDoNotDelete/providers/Microsoft.DocumentDB/databaseAccounts/pymonitortest","name":"pymonitortest","location":"West - US","type":"Microsoft.DocumentDB/databaseAccounts","kind":"GlobalDocumentDB","tags":{},"properties":{"provisioningState":"Succeeded","documentEndpoint":"https://pymonitortest.documents.azure.com:443/","ipRangeFilter":"","enableAutomaticFailover":false,"databaseAccountOfferType":"Standard","consistencyPolicy":{"defaultConsistencyLevel":"Session","maxIntervalInSeconds":5,"maxStalenessPrefix":100},"configurationOverrides":{},"writeLocations":[{"id":"pymonitortest-westus","locationName":"West - US","documentEndpoint":"https://pymonitortest-westus.documents.azure.com:443/","provisioningState":"Succeeded","failoverPriority":0}],"readLocations":[{"id":"pymonitortest-westus","locationName":"West - US","documentEndpoint":"https://pymonitortest-westus.documents.azure.com:443/","provisioningState":"Succeeded","failoverPriority":0}],"failoverPolicies":[{"id":"pymonitortest-westus","locationName":"West - US","failoverPriority":0}]}}]}'} - headers: - Cache-Control: ['no-store, no-cache'] - Content-Location: ['https://management.documents.azure.com:450/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DocumentDB/databaseAccounts?api-version=2015-04-08'] - Content-Type: [application/json] - Date: ['Tue, 27 Jun 2017 00:46:58 GMT'] - Pragma: [no-cache] - Server: [Microsoft-HTTPAPI/2.0] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Transfer-Encoding: [chunked] - Vary: [Accept-Encoding] - content-length: ['2367'] - x-ms-correlation-request-id: [37346454-f14b-4e17-a86a-2fc321c93552] - x-ms-gatewayversion: [version=1.14.55.2] - x-ms-ratelimit-remaining-subscription-reads: ['14997'] - x-ms-request-id: [37346454-f14b-4e17-a86a-2fc321c93552] - x-ms-routing-request-id: ['WESTUS:20170627T004658Z:37346454-f14b-4e17-a86a-2fc321c93552'] + US","failoverPriority":0}],"capabilities":[]}}]}'} + headers: + cache-control: ['no-store, no-cache'] + content-length: ['1356'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/providers/Microsoft.DocumentDB/databaseAccounts?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:45:45 GMT'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + transfer-encoding: [chunked] + vary: [Accept-Encoding] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] status: {code: 200, message: Ok} - request: body: '{"failoverPolicies": [{"locationName": "westus", "failoverPriority": 0}]}' @@ -119,28 +437,25 @@ interactions: Connection: [keep-alive] Content-Length: ['73'] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.1 (Windows-10-10.0.15063-SP0) requests/2.17.3 msrest/0.4.11 - msrest_azure/0.4.9 cosmosdb/0.2.0 Azure-SDK-For-Python] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] accept-language: [en-US] - x-ms-client-request-id: [205ba9e6-5ad2-11e7-9f3f-ecb1d756380e] method: POST uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/failoverPriorityChange?api-version=2015-04-08 response: body: {string: '{"status":"Enqueued","error":{}}'} headers: - Cache-Control: ['no-store, no-cache'] - Content-Length: ['32'] - Content-Type: [application/json] - Date: ['Tue, 27 Jun 2017 00:47:01 GMT'] - Location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/failoverPriorityChange/operationResults/96109237-d52f-45dc-b79f-4e5be1eda6ba?api-version=2015-04-08'] - Pragma: [no-cache] - Server: [Microsoft-HTTPAPI/2.0] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - x-ms-correlation-request-id: [e73b4d3d-e704-4c36-a024-4c14e4813c00] - x-ms-gatewayversion: [version=1.14.55.2] + cache-control: ['no-store, no-cache'] + content-length: ['32'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:45:47 GMT'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/failoverPriorityChange/operationResults/c2b8961a-826c-41ad-a8a1-030e21d75646?api-version=2015-04-08'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] x-ms-ratelimit-remaining-subscription-writes: ['1199'] - x-ms-request-id: [96109237-d52f-45dc-b79f-4e5be1eda6ba] - x-ms-routing-request-id: ['WESTUS2:20170627T004702Z:e73b4d3d-e704-4c36-a024-4c14e4813c00'] status: {code: 202, message: Accepted} - request: body: null @@ -148,27 +463,21 @@ interactions: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.1 (Windows-10-10.0.15063-SP0) requests/2.17.3 msrest/0.4.11 - msrest_azure/0.4.9 cosmosdb/0.2.0 Azure-SDK-For-Python] - accept-language: [en-US] - x-ms-client-request-id: [205ba9e6-5ad2-11e7-9f3f-ecb1d756380e] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/failoverPriorityChange/operationResults/96109237-d52f-45dc-b79f-4e5be1eda6ba?api-version=2015-04-08 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/failoverPriorityChange/operationResults/c2b8961a-826c-41ad-a8a1-030e21d75646?api-version=2015-04-08 response: body: {string: ''} headers: - Cache-Control: ['no-store, no-cache'] - Content-Length: ['0'] - Date: ['Tue, 27 Jun 2017 00:47:31 GMT'] - Pragma: [no-cache] - Server: [Microsoft-HTTPAPI/2.0] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - x-ms-activity-id: [205ba9e6-5ad2-11e7-9f3f-ecb1d756380e] - x-ms-correlation-request-id: [61901bd8-3fa2-4ab8-9dd8-9ccef1307ecb] - x-ms-ratelimit-remaining-subscription-reads: ['14998'] - x-ms-request-id: [61901bd8-3fa2-4ab8-9dd8-9ccef1307ecb] - x-ms-routing-request-id: ['WESTUS:20170627T004732Z:61901bd8-3fa2-4ab8-9dd8-9ccef1307ecb'] + cache-control: ['no-store, no-cache'] + content-length: ['0'] + date: ['Mon, 08 Oct 2018 20:46:17 GMT'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-content-type-options: [nosniff] + x-ms-activity-id: [21a15fa8-cb3b-11e8-816d-ecb1d756380e] status: {code: 200, message: Ok} - request: body: null @@ -177,30 +486,26 @@ interactions: Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] Content-Length: ['0'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.1 (Windows-10-10.0.15063-SP0) requests/2.17.3 msrest/0.4.11 - msrest_azure/0.4.9 cosmosdb/0.2.0 Azure-SDK-For-Python] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] accept-language: [en-US] - x-ms-client-request-id: [345d17dc-5ad2-11e7-884d-ecb1d756380e] method: POST uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/listKeys?api-version=2015-04-08 response: - body: {string: '{"primaryMasterKey":"phUs3qDIL0F6Fg2KOZLgEMcEljky9VhmtqCvo0wWHfAsQFhpoYG2crRZk7z5nUuaBXHCMeKtHPcaRcYOhaF2vg==","secondaryMasterKey":"uJnsjaQNr9PgWkZPPZ9hZiJnzMIDTgYynS6N2zB4BAnbWytZiJjUvKCjiSbq9Zu3RySs84pE0XJOaD2qhBMP8Q==","primaryReadonlyMasterKey":"YXvVtPsCnnwODeE9Zh8XFpz4yRLi7NgQFJvr6u8HDvInZGYkYSrespkbdj9dJww3vN81YcEpF0yhyvzqKbobSQ==","secondaryReadonlyMasterKey":"1oikvi1OYupPSVybwNgVgwATD7nVoP44piAFFEgsWQvg5gvIjcNcQKHUQLZJs8jaGjk8maulLUCRd5IulMp48g=="}'} - headers: - Cache-Control: ['no-store, no-cache'] - Content-Type: [application/json] - Date: ['Tue, 27 Jun 2017 00:47:32 GMT'] - Pragma: [no-cache] - Server: [Microsoft-HTTPAPI/2.0] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Transfer-Encoding: [chunked] - Vary: [Accept-Encoding] + body: {string: '{"primaryMasterKey":"tVkL0QkNYnmcB6hxVMavzuOpVPxt62HvyoJyJ3stg2rFRAZGgjbUNccJw6kvzJTRG8qzBPTEM8DvEPiQi6y6yw==","secondaryMasterKey":"EFG1k59hyXKXj42aH9VdGHMIdqGodiJRSKV5zynUH14zd3I09Pg8ZEANe1mGQauf4jiUaSwQlkd38DvsWctJkg==","primaryReadonlyMasterKey":"YktaWtgT2Z1mwE1iCW7AOyUulqtTzqyMhz5JQLoUvMQXIWh4GnQg10QBPLBaoffEhEWCXSzzKILP86YxEiWlrQ==","secondaryReadonlyMasterKey":"ZCb2xqBrqpNC6b6p2fPtMExH7HhgUGKCOh7p82ryGBZnabSOk1G2IVpgOFoViiPf9k3xVeDSXW1anJ25kFq26Q=="}'} + headers: + cache-control: ['no-store, no-cache'] content-length: ['461'] - x-ms-correlation-request-id: [b2401d95-402c-49bc-9fd0-6525f3a34c9e] - x-ms-gatewayversion: [version=1.14.55.2] - x-ms-ratelimit-remaining-subscription-writes: ['1198'] - x-ms-request-id: [b2401d95-402c-49bc-9fd0-6525f3a34c9e] - x-ms-routing-request-id: ['WESTUS:20170627T004732Z:b2401d95-402c-49bc-9fd0-6525f3a34c9e'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:46:19 GMT'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + transfer-encoding: [chunked] + vary: [Accept-Encoding] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] + x-ms-ratelimit-remaining-subscription-writes: ['1199'] status: {code: 200, message: Ok} - request: body: null @@ -208,31 +513,27 @@ interactions: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.1 (Windows-10-10.0.15063-SP0) requests/2.17.3 msrest/0.4.11 - msrest_azure/0.4.9 cosmosdb/0.2.0 Azure-SDK-For-Python] + Content-Length: ['0'] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] accept-language: [en-US] - x-ms-client-request-id: [34ad085c-5ad2-11e7-bf95-ecb1d756380e] - method: GET + method: POST uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/readonlykeys?api-version=2015-04-08 response: - body: {string: '{"primaryReadonlyMasterKey":"YXvVtPsCnnwODeE9Zh8XFpz4yRLi7NgQFJvr6u8HDvInZGYkYSrespkbdj9dJww3vN81YcEpF0yhyvzqKbobSQ==","secondaryReadonlyMasterKey":"1oikvi1OYupPSVybwNgVgwATD7nVoP44piAFFEgsWQvg5gvIjcNcQKHUQLZJs8jaGjk8maulLUCRd5IulMp48g=="}'} - headers: - Cache-Control: ['no-store, no-cache'] - Content-Location: ['https://management.documents.azure.com:450/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/readonlykeys?api-version=2015-04-08'] - Content-Type: [application/json] - Date: ['Tue, 27 Jun 2017 00:47:33 GMT'] - Pragma: [no-cache] - Server: [Microsoft-HTTPAPI/2.0] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Transfer-Encoding: [chunked] - Vary: [Accept-Encoding] + body: {string: '{"primaryReadonlyMasterKey":"YktaWtgT2Z1mwE1iCW7AOyUulqtTzqyMhz5JQLoUvMQXIWh4GnQg10QBPLBaoffEhEWCXSzzKILP86YxEiWlrQ==","secondaryReadonlyMasterKey":"ZCb2xqBrqpNC6b6p2fPtMExH7HhgUGKCOh7p82ryGBZnabSOk1G2IVpgOFoViiPf9k3xVeDSXW1anJ25kFq26Q=="}'} + headers: + cache-control: ['no-store, no-cache'] content-length: ['239'] - x-ms-correlation-request-id: [17d8289b-cc30-4106-9a73-a45e4f91812d] - x-ms-gatewayversion: [version=1.14.33.2] - x-ms-ratelimit-remaining-subscription-reads: ['14999'] - x-ms-request-id: [17d8289b-cc30-4106-9a73-a45e4f91812d] - x-ms-routing-request-id: ['WESTUS:20170627T004733Z:17d8289b-cc30-4106-9a73-a45e4f91812d'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:46:19 GMT'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + transfer-encoding: [chunked] + vary: [Accept-Encoding] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] + x-ms-ratelimit-remaining-subscription-writes: ['1199'] status: {code: 200, message: Ok} - request: body: '{"keyKind": "primary"}' @@ -242,28 +543,25 @@ interactions: Connection: [keep-alive] Content-Length: ['22'] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.1 (Windows-10-10.0.15063-SP0) requests/2.17.3 msrest/0.4.11 - msrest_azure/0.4.9 cosmosdb/0.2.0 Azure-SDK-For-Python] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] accept-language: [en-US] - x-ms-client-request-id: [3501d124-5ad2-11e7-aa65-ecb1d756380e] method: POST uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/regenerateKey?api-version=2015-04-08 response: body: {string: '{"status":"Enqueued","error":{}}'} headers: - Cache-Control: ['no-store, no-cache'] - Content-Length: ['32'] - Content-Type: [application/json] - Date: ['Tue, 27 Jun 2017 00:47:35 GMT'] - Location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/regenerateKey/operationResults/2482ba80-35f1-4bd9-96d8-a1510ff5f1b9?api-version=2015-04-08'] - Pragma: [no-cache] - Server: [Microsoft-HTTPAPI/2.0] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - x-ms-correlation-request-id: [3147cd61-a0fe-422c-90ac-99b7b33c9be0] - x-ms-gatewayversion: [version=1.14.33.2] + cache-control: ['no-store, no-cache'] + content-length: ['32'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:46:21 GMT'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/regenerateKey/operationResults/2d02606a-b4db-49ed-8a9b-5d38a0c92980?api-version=2015-04-08'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] x-ms-ratelimit-remaining-subscription-writes: ['1199'] - x-ms-request-id: [2482ba80-35f1-4bd9-96d8-a1510ff5f1b9] - x-ms-routing-request-id: ['WESTUS:20170627T004735Z:3147cd61-a0fe-422c-90ac-99b7b33c9be0'] status: {code: 202, message: Accepted} - request: body: null @@ -271,61 +569,24 @@ interactions: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.1 (Windows-10-10.0.15063-SP0) requests/2.17.3 msrest/0.4.11 - msrest_azure/0.4.9 cosmosdb/0.2.0 Azure-SDK-For-Python] - accept-language: [en-US] - x-ms-client-request-id: [3501d124-5ad2-11e7-aa65-ecb1d756380e] + User-Agent: [python/3.6.4 (Windows-10-10.0.17763-SP0) requests/2.19.1 msrest/0.5.5 + msrest_azure/0.4.34 azure-mgmt-cosmosdb/0.3.0 Azure-SDK-For-Python] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/regenerateKey/operationResults/2482ba80-35f1-4bd9-96d8-a1510ff5f1b9?api-version=2015-04-08 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/regenerateKey/operationResults/2d02606a-b4db-49ed-8a9b-5d38a0c92980?api-version=2015-04-08 response: - body: {string: '{"status":"Dequeued","error":{}}'} + body: {string: '{"primaryMasterKey":"MR9IG9UgUXxTaVy3gcrNpssfD5BfDEg3yWnfBmglJng3C1ZfZ4OJ5L9JsNoQikBHr2JM6PwBJwvNbyXgovtuzA==","secondaryMasterKey":"EFG1k59hyXKXj42aH9VdGHMIdqGodiJRSKV5zynUH14zd3I09Pg8ZEANe1mGQauf4jiUaSwQlkd38DvsWctJkg==","primaryReadonlyMasterKey":"YktaWtgT2Z1mwE1iCW7AOyUulqtTzqyMhz5JQLoUvMQXIWh4GnQg10QBPLBaoffEhEWCXSzzKILP86YxEiWlrQ==","secondaryReadonlyMasterKey":"ZCb2xqBrqpNC6b6p2fPtMExH7HhgUGKCOh7p82ryGBZnabSOk1G2IVpgOFoViiPf9k3xVeDSXW1anJ25kFq26Q=="}'} headers: - Cache-Control: ['no-store, no-cache'] - Content-Length: ['32'] - Content-Location: ['https://management.documents.azure.com:450/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/regenerateKey/operationResults/2482ba80-35f1-4bd9-96d8-a1510ff5f1b9?api-version=2015-04-08'] - Content-Type: [application/json] - Date: ['Tue, 27 Jun 2017 00:48:06 GMT'] - Location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/regenerateKey/operationResults/2482ba80-35f1-4bd9-96d8-a1510ff5f1b9?api-version=2015-04-08'] - Pragma: [no-cache] - Server: [Microsoft-HTTPAPI/2.0] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - x-ms-correlation-request-id: [cae26ecf-3fc8-4111-8f95-7f92568c9317] - x-ms-gatewayversion: [version=1.14.33.2] - x-ms-ratelimit-remaining-subscription-reads: ['14995'] - x-ms-request-id: [2482ba80-35f1-4bd9-96d8-a1510ff5f1b9] - x-ms-routing-request-id: ['WESTUS:20170627T004806Z:cae26ecf-3fc8-4111-8f95-7f92568c9317'] - status: {code: 202, message: Accepted} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.1 (Windows-10-10.0.15063-SP0) requests/2.17.3 msrest/0.4.11 - msrest_azure/0.4.9 cosmosdb/0.2.0 Azure-SDK-For-Python] - accept-language: [en-US] - x-ms-client-request-id: [3501d124-5ad2-11e7-aa65-ecb1d756380e] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/regenerateKey/operationResults/2482ba80-35f1-4bd9-96d8-a1510ff5f1b9?api-version=2015-04-08 - response: - body: {string: '{"primaryMasterKey":"f2EzigVcnk7s3xFkEoD4TebjeEduiEdJJcvlg6eSMjZ3oxgT2ETZZotj7z3Md16ZRy68fIfT1Bs4Oa4nWJOEHg==","secondaryMasterKey":"uJnsjaQNr9PgWkZPPZ9hZiJnzMIDTgYynS6N2zB4BAnbWytZiJjUvKCjiSbq9Zu3RySs84pE0XJOaD2qhBMP8Q==","primaryReadonlyMasterKey":"YXvVtPsCnnwODeE9Zh8XFpz4yRLi7NgQFJvr6u8HDvInZGYkYSrespkbdj9dJww3vN81YcEpF0yhyvzqKbobSQ==","secondaryReadonlyMasterKey":"1oikvi1OYupPSVybwNgVgwATD7nVoP44piAFFEgsWQvg5gvIjcNcQKHUQLZJs8jaGjk8maulLUCRd5IulMp48g=="}'} - headers: - Cache-Control: ['no-store, no-cache'] - Content-Location: ['https://management.documents.azure.com:450/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/regenerateKey/operationResults/2482ba80-35f1-4bd9-96d8-a1510ff5f1b9?api-version=2015-04-08'] - Content-Type: [application/json] - Date: ['Tue, 27 Jun 2017 00:48:36 GMT'] - Pragma: [no-cache] - Server: [Microsoft-HTTPAPI/2.0] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Transfer-Encoding: [chunked] - Vary: [Accept-Encoding] + cache-control: ['no-store, no-cache'] content-length: ['461'] - x-ms-correlation-request-id: [a9501ddb-b7d4-48ec-800a-9cc6a99ea150] - x-ms-gatewayversion: [version=1.14.55.2] - x-ms-ratelimit-remaining-subscription-reads: ['14998'] - x-ms-request-id: [a9501ddb-b7d4-48ec-800a-9cc6a99ea150] - x-ms-routing-request-id: ['WESTUS:20170627T004836Z:a9501ddb-b7d4-48ec-800a-9cc6a99ea150'] + content-location: ['https://management.documents.azure.com:450/subscriptions/00977cdb-163f-435f-9c32-39ec8ae61f4d/resourceGroups/test_mgmt_cosmosdb_test_accounts_features640310f9/providers/Microsoft.DocumentDB/databaseAccounts/pycosmosdbtest640310f9/regenerateKey/operationResults/2d02606a-b4db-49ed-8a9b-5d38a0c92980?api-version=2015-04-08'] + content-type: [application/json] + date: ['Mon, 08 Oct 2018 20:46:52 GMT'] + pragma: [no-cache] + server: [Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + transfer-encoding: [chunked] + vary: [Accept-Encoding] + x-content-type-options: [nosniff] + x-ms-gatewayversion: [version=2.1.0.0] status: {code: 200, message: Ok} version: 1 From eb820c2b9797495b68466391b17873b175aba7f4 Mon Sep 17 00:00:00 2001 From: Laurent Mazuel Date: Mon, 8 Oct 2018 13:49:57 -0700 Subject: [PATCH 5/5] Version 0.5.0 --- azure-mgmt-cosmosdb/HISTORY.rst | 15 ++++++++++++++- .../azure/mgmt/cosmosdb/version.py | 2 +- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/azure-mgmt-cosmosdb/HISTORY.rst b/azure-mgmt-cosmosdb/HISTORY.rst index 4d879a047957..3f236aa0e211 100644 --- a/azure-mgmt-cosmosdb/HISTORY.rst +++ b/azure-mgmt-cosmosdb/HISTORY.rst @@ -3,6 +3,19 @@ Release History =============== +0.5.0 (2018-10-08) +++++++++++++++++++ + +**Features** + +- Add enable_multiple_write_locations support + +**Note** + +- `database_accounts.list_read_only_keys` is now doing a POST call, and not GET anymore. This should not impact anything. + Old behavior be can found with the `database_accounts.get_read_only_keys` **deprecated** method. +- azure-mgmt-nspkg is not installed anymore on Python 3 (PEP420-based namespace package) + 0.4.1 (2018-05-15) ++++++++++++++++++ @@ -33,7 +46,7 @@ This version uses a next-generation code generator that *might* introduce breaki - Return type changes from `msrestazure.azure_operation.AzureOperationPoller` to `msrest.polling.LROPoller`. External API is the same. - Return type is now **always** a `msrest.polling.LROPoller`, regardless of the optional parameters used. - - The behavior has changed when using `raw=True`. Instead of returning the initial call result as `ClientRawResponse`, + - The behavior has changed when using `raw=True`. Instead of returning the initial call result as `ClientRawResponse`, without polling, now this returns an LROPoller. After polling, the final resource will be returned as a `ClientRawResponse`. - New `polling` parameter. The default behavior is `Polling=True` which will poll using ARM algorithm. When `Polling=False`, the response of the initial call will be returned without polling. diff --git a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/version.py b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/version.py index 3e682bbd5fb1..266f5a486d79 100644 --- a/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/version.py +++ b/azure-mgmt-cosmosdb/azure/mgmt/cosmosdb/version.py @@ -9,5 +9,5 @@ # regenerated. # -------------------------------------------------------------------------- -VERSION = "0.3.0" +VERSION = "0.5.0"