diff --git a/azure-mgmt-search/HISTORY.rst b/azure-mgmt-search/HISTORY.rst index c143af0d63ad..e7e96f02d0a3 100644 --- a/azure-mgmt-search/HISTORY.rst +++ b/azure-mgmt-search/HISTORY.rst @@ -3,6 +3,14 @@ Release History =============== +2.1.0 (2019-02-19) +++++++++++++++++++ + +**Features** + +- Model SearchService has a new parameter identity +- Model Resource has a new parameter identity + 2.0.0 (2018-05-21) ++++++++++++++++++ @@ -24,7 +32,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-search/README.rst b/azure-mgmt-search/README.rst index d0a245b81b69..e31f6f56c60f 100644 --- a/azure-mgmt-search/README.rst +++ b/azure-mgmt-search/README.rst @@ -14,25 +14,6 @@ For the older Azure Service Management (ASM) libraries, see For a more complete set of Azure libraries, see the `azure `__ bundle package. -Compatibility -============= - -**IMPORTANT**: If you have an earlier version of the azure package -(version < 1.0), you should uninstall it before installing this package. - -You can check the version using pip: - -.. code:: shell - - pip freeze - -If you see azure==0.11.0 (or any version below 1.0), uninstall it first: - -.. code:: shell - - pip uninstall azure - - Usage ===== diff --git a/azure-mgmt-search/azure/mgmt/search/models/__init__.py b/azure-mgmt-search/azure/mgmt/search/models/__init__.py index 1fa43c85e74e..1ce1f9f90117 100644 --- a/azure-mgmt-search/azure/mgmt/search/models/__init__.py +++ b/azure-mgmt-search/azure/mgmt/search/models/__init__.py @@ -16,6 +16,7 @@ from .query_key_py3 import QueryKey from .sku_py3 import Sku from .search_service_py3 import SearchService + from .identity_py3 import Identity from .resource_py3 import Resource from .operation_display_py3 import OperationDisplay from .operation_py3 import Operation @@ -27,6 +28,7 @@ from .query_key import QueryKey from .sku import Sku from .search_service import SearchService + from .identity import Identity from .resource import Resource from .operation_display import OperationDisplay from .operation import Operation @@ -50,6 +52,7 @@ 'QueryKey', 'Sku', 'SearchService', + 'Identity', 'Resource', 'OperationDisplay', 'Operation', diff --git a/azure-mgmt-search/azure/mgmt/search/models/identity.py b/azure-mgmt-search/azure/mgmt/search/models/identity.py new file mode 100644 index 000000000000..f526b986fc70 --- /dev/null +++ b/azure-mgmt-search/azure/mgmt/search/models/identity.py @@ -0,0 +1,48 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class Identity(Model): + """Identity for the resource. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar principal_id: The principal ID of resource identity. + :vartype principal_id: str + :ivar tenant_id: The tenant ID of resource. + :vartype tenant_id: str + :ivar type: Required. The identity type. Default value: "SystemAssigned" . + :vartype type: str + """ + + _validation = { + 'principal_id': {'readonly': True}, + 'tenant_id': {'readonly': True}, + 'type': {'required': True, 'constant': True}, + } + + _attribute_map = { + 'principal_id': {'key': 'principalId', 'type': 'str'}, + 'tenant_id': {'key': 'tenantId', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + } + + type = "SystemAssigned" + + def __init__(self, **kwargs): + super(Identity, self).__init__(**kwargs) + self.principal_id = None + self.tenant_id = None diff --git a/azure-mgmt-search/azure/mgmt/search/models/identity_py3.py b/azure-mgmt-search/azure/mgmt/search/models/identity_py3.py new file mode 100644 index 000000000000..22d25fdd85b7 --- /dev/null +++ b/azure-mgmt-search/azure/mgmt/search/models/identity_py3.py @@ -0,0 +1,48 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class Identity(Model): + """Identity for the resource. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar principal_id: The principal ID of resource identity. + :vartype principal_id: str + :ivar tenant_id: The tenant ID of resource. + :vartype tenant_id: str + :ivar type: Required. The identity type. Default value: "SystemAssigned" . + :vartype type: str + """ + + _validation = { + 'principal_id': {'readonly': True}, + 'tenant_id': {'readonly': True}, + 'type': {'required': True, 'constant': True}, + } + + _attribute_map = { + 'principal_id': {'key': 'principalId', 'type': 'str'}, + 'tenant_id': {'key': 'tenantId', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + } + + type = "SystemAssigned" + + def __init__(self, **kwargs) -> None: + super(Identity, self).__init__(**kwargs) + self.principal_id = None + self.tenant_id = None diff --git a/azure-mgmt-search/azure/mgmt/search/models/resource.py b/azure-mgmt-search/azure/mgmt/search/models/resource.py index 718a54f2e59b..8dc5dd8833f9 100644 --- a/azure-mgmt-search/azure/mgmt/search/models/resource.py +++ b/azure-mgmt-search/azure/mgmt/search/models/resource.py @@ -32,6 +32,8 @@ class Resource(Model): :type location: str :param tags: Tags to help categorize the resource in the Azure portal. :type tags: dict[str, str] + :param identity: The identity of the resource. + :type identity: ~azure.mgmt.search.models.Identity """ _validation = { @@ -46,6 +48,7 @@ class Resource(Model): 'type': {'key': 'type', 'type': 'str'}, 'location': {'key': 'location', 'type': 'str'}, 'tags': {'key': 'tags', 'type': '{str}'}, + 'identity': {'key': 'identity', 'type': 'Identity'}, } def __init__(self, **kwargs): @@ -55,3 +58,4 @@ def __init__(self, **kwargs): self.type = None self.location = kwargs.get('location', None) self.tags = kwargs.get('tags', None) + self.identity = kwargs.get('identity', None) diff --git a/azure-mgmt-search/azure/mgmt/search/models/resource_py3.py b/azure-mgmt-search/azure/mgmt/search/models/resource_py3.py index 0f2e04e0d9cc..752e7a2cbbb9 100644 --- a/azure-mgmt-search/azure/mgmt/search/models/resource_py3.py +++ b/azure-mgmt-search/azure/mgmt/search/models/resource_py3.py @@ -32,6 +32,8 @@ class Resource(Model): :type location: str :param tags: Tags to help categorize the resource in the Azure portal. :type tags: dict[str, str] + :param identity: The identity of the resource. + :type identity: ~azure.mgmt.search.models.Identity """ _validation = { @@ -46,12 +48,14 @@ class Resource(Model): 'type': {'key': 'type', 'type': 'str'}, 'location': {'key': 'location', 'type': 'str'}, 'tags': {'key': 'tags', 'type': '{str}'}, + 'identity': {'key': 'identity', 'type': 'Identity'}, } - def __init__(self, *, location: str=None, tags=None, **kwargs) -> None: + def __init__(self, *, location: str=None, tags=None, identity=None, **kwargs) -> None: super(Resource, self).__init__(**kwargs) self.id = None self.name = None self.type = None self.location = location self.tags = tags + self.identity = identity diff --git a/azure-mgmt-search/azure/mgmt/search/models/search_service.py b/azure-mgmt-search/azure/mgmt/search/models/search_service.py index 077847e78c05..6bd3de6791de 100644 --- a/azure-mgmt-search/azure/mgmt/search/models/search_service.py +++ b/azure-mgmt-search/azure/mgmt/search/models/search_service.py @@ -32,6 +32,8 @@ class SearchService(Resource): :type location: str :param tags: Tags to help categorize the resource in the Azure portal. :type tags: dict[str, str] + :param identity: The identity of the resource. + :type identity: ~azure.mgmt.search.models.Identity :param replica_count: The number of replicas in the Search service. If specified, it must be a value between 1 and 12 inclusive for standard SKUs or between 1 and 3 inclusive for basic SKU. Default value: 1 . @@ -101,6 +103,7 @@ class SearchService(Resource): 'type': {'key': 'type', 'type': 'str'}, 'location': {'key': 'location', 'type': 'str'}, 'tags': {'key': 'tags', 'type': '{str}'}, + 'identity': {'key': 'identity', 'type': 'Identity'}, 'replica_count': {'key': 'properties.replicaCount', 'type': 'int'}, 'partition_count': {'key': 'properties.partitionCount', 'type': 'int'}, 'hosting_mode': {'key': 'properties.hostingMode', 'type': 'HostingMode'}, diff --git a/azure-mgmt-search/azure/mgmt/search/models/search_service_py3.py b/azure-mgmt-search/azure/mgmt/search/models/search_service_py3.py index a0e3dd69d375..823afff5b9a5 100644 --- a/azure-mgmt-search/azure/mgmt/search/models/search_service_py3.py +++ b/azure-mgmt-search/azure/mgmt/search/models/search_service_py3.py @@ -32,6 +32,8 @@ class SearchService(Resource): :type location: str :param tags: Tags to help categorize the resource in the Azure portal. :type tags: dict[str, str] + :param identity: The identity of the resource. + :type identity: ~azure.mgmt.search.models.Identity :param replica_count: The number of replicas in the Search service. If specified, it must be a value between 1 and 12 inclusive for standard SKUs or between 1 and 3 inclusive for basic SKU. Default value: 1 . @@ -101,6 +103,7 @@ class SearchService(Resource): 'type': {'key': 'type', 'type': 'str'}, 'location': {'key': 'location', 'type': 'str'}, 'tags': {'key': 'tags', 'type': '{str}'}, + 'identity': {'key': 'identity', 'type': 'Identity'}, 'replica_count': {'key': 'properties.replicaCount', 'type': 'int'}, 'partition_count': {'key': 'properties.partitionCount', 'type': 'int'}, 'hosting_mode': {'key': 'properties.hostingMode', 'type': 'HostingMode'}, @@ -110,8 +113,8 @@ class SearchService(Resource): 'sku': {'key': 'sku', 'type': 'Sku'}, } - def __init__(self, *, location: str=None, tags=None, replica_count: int=1, partition_count: int=1, hosting_mode="default", sku=None, **kwargs) -> None: - super(SearchService, self).__init__(location=location, tags=tags, **kwargs) + def __init__(self, *, location: str=None, tags=None, identity=None, replica_count: int=1, partition_count: int=1, hosting_mode="default", sku=None, **kwargs) -> None: + super(SearchService, self).__init__(location=location, tags=tags, identity=identity, **kwargs) self.replica_count = replica_count self.partition_count = partition_count self.hosting_mode = hosting_mode diff --git a/azure-mgmt-search/azure/mgmt/search/operations/admin_keys_operations.py b/azure-mgmt-search/azure/mgmt/search/operations/admin_keys_operations.py index da5e9acb21bc..7887d302f3d4 100644 --- a/azure-mgmt-search/azure/mgmt/search/operations/admin_keys_operations.py +++ b/azure-mgmt-search/azure/mgmt/search/operations/admin_keys_operations.py @@ -82,7 +82,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: @@ -93,8 +93,8 @@ def get( header_parameters['x-ms-client-request-id'] = self._serialize.header("client_request_id", client_request_id, '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) @@ -163,7 +163,7 @@ def regenerate( # 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: @@ -174,8 +174,8 @@ def regenerate( header_parameters['x-ms-client-request-id'] = self._serialize.header("client_request_id", client_request_id, '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) diff --git a/azure-mgmt-search/azure/mgmt/search/operations/operations.py b/azure-mgmt-search/azure/mgmt/search/operations/operations.py index 5a35bf95f5d8..c83587eafb24 100644 --- a/azure-mgmt-search/azure/mgmt/search/operations/operations.py +++ b/azure-mgmt-search/azure/mgmt/search/operations/operations.py @@ -68,7 +68,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: @@ -77,9 +77,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-search/azure/mgmt/search/operations/query_keys_operations.py b/azure-mgmt-search/azure/mgmt/search/operations/query_keys_operations.py index e0ce209493e1..8fb9e29e0309 100644 --- a/azure-mgmt-search/azure/mgmt/search/operations/query_keys_operations.py +++ b/azure-mgmt-search/azure/mgmt/search/operations/query_keys_operations.py @@ -85,7 +85,7 @@ def create( # 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,8 +96,8 @@ def create( header_parameters['x-ms-client-request-id'] = self._serialize.header("client_request_id", client_request_id, '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) @@ -167,7 +167,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: @@ -178,9 +178,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['x-ms-client-request-id'] = self._serialize.header("client_request_id", client_request_id, '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) @@ -249,7 +248,6 @@ def delete( # 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: @@ -260,8 +258,8 @@ def delete( header_parameters['x-ms-client-request-id'] = self._serialize.header("client_request_id", client_request_id, '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 [200, 204, 404]: exp = CloudError(response) diff --git a/azure-mgmt-search/azure/mgmt/search/operations/services_operations.py b/azure-mgmt-search/azure/mgmt/search/operations/services_operations.py index 9a372a7c9c16..c89b0d0e364d 100644 --- a/azure-mgmt-search/azure/mgmt/search/operations/services_operations.py +++ b/azure-mgmt-search/azure/mgmt/search/operations/services_operations.py @@ -61,6 +61,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()) @@ -75,9 +76,8 @@ def _create_or_update_initial( body_content = self._serialize.body(service, 'SearchService') # 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, 201]: exp = CloudError(response) @@ -210,6 +210,7 @@ def update( # 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()) @@ -224,9 +225,8 @@ def update( body_content = self._serialize.body(service, 'SearchService') # 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) @@ -290,7 +290,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: @@ -301,8 +301,8 @@ def get( header_parameters['x-ms-client-request-id'] = self._serialize.header("client_request_id", client_request_id, '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) @@ -365,7 +365,6 @@ def delete( # 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: @@ -376,8 +375,8 @@ def delete( header_parameters['x-ms-client-request-id'] = self._serialize.header("client_request_id", client_request_id, '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 [200, 204, 404]: exp = CloudError(response) @@ -436,7 +435,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: @@ -447,9 +446,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['x-ms-client-request-id'] = self._serialize.header("client_request_id", client_request_id, '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) @@ -469,6 +467,80 @@ def internal_paging(next_link=None, raw=False): return deserialized list_by_resource_group.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Search/searchServices'} + def list_by_subscription( + self, search_management_request_options=None, custom_headers=None, raw=False, **operation_config): + """Gets a list of all Search services in the given subscription. + + :param search_management_request_options: Additional parameters for + the operation + :type search_management_request_options: + ~azure.mgmt.search.models.SearchManagementRequestOptions + :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: An iterator like instance of SearchService + :rtype: + ~azure.mgmt.search.models.SearchServicePaged[~azure.mgmt.search.models.SearchService] + :raises: :class:`CloudError` + """ + client_request_id = None + if search_management_request_options is not None: + client_request_id = search_management_request_options.client_request_id + + def internal_paging(next_link=None, raw=False): + + if not next_link: + # Construct URL + url = self.list_by_subscription.metadata['url'] + path_format_arguments = { + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') + } + 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') + + else: + url = next_link + query_parameters = {} + + # Construct headers + header_parameters = {} + 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: + 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') + if client_request_id is not None: + header_parameters['x-ms-client-request-id'] = self._serialize.header("client_request_id", client_request_id, 'str') + + # Construct and send request + 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) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + return response + + # Deserialize response + deserialized = models.SearchServicePaged(internal_paging, self._deserialize.dependencies) + + if raw: + header_dict = {} + client_raw_response = models.SearchServicePaged(internal_paging, self._deserialize.dependencies, header_dict) + return client_raw_response + + return deserialized + list_by_subscription.metadata = {'url': '/subscriptions/{subscriptionId}/providers/Microsoft.Search/searchServices'} + def check_name_availability( self, name, search_management_request_options=None, custom_headers=None, raw=False, **operation_config): """Checks whether or not the given Search service name is available for @@ -512,6 +584,7 @@ def check_name_availability( # 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()) @@ -526,9 +599,8 @@ def check_name_availability( body_content = self._serialize.body(check_name_availability_input, 'CheckNameAvailabilityInput') # 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]: exp = CloudError(response) diff --git a/azure-mgmt-search/azure/mgmt/search/version.py b/azure-mgmt-search/azure/mgmt/search/version.py index 53c4c7ea05e8..7ecf658ce13b 100644 --- a/azure-mgmt-search/azure/mgmt/search/version.py +++ b/azure-mgmt-search/azure/mgmt/search/version.py @@ -9,5 +9,4 @@ # regenerated. # -------------------------------------------------------------------------- -VERSION = "2.0.0" - +VERSION = "2.1.0" diff --git a/azure-mgmt-search/sdk_packaging.toml b/azure-mgmt-search/sdk_packaging.toml index da7f6badb68b..d7b1c8998bff 100644 --- a/azure-mgmt-search/sdk_packaging.toml +++ b/azure-mgmt-search/sdk_packaging.toml @@ -5,3 +5,4 @@ package_pprint_name = "Search Management" package_doc_id = "search" is_stable = false is_arm = true +need_msrestazure = true