diff --git a/sdk/batch/azure-mgmt-batch/MANIFEST.in b/sdk/batch/azure-mgmt-batch/MANIFEST.in index a3cb07df8765..3a9b6517412b 100644 --- a/sdk/batch/azure-mgmt-batch/MANIFEST.in +++ b/sdk/batch/azure-mgmt-batch/MANIFEST.in @@ -1,3 +1,4 @@ +include _meta.json recursive-include tests *.py *.yaml include *.md include azure/__init__.py diff --git a/sdk/batch/azure-mgmt-batch/_meta.json b/sdk/batch/azure-mgmt-batch/_meta.json new file mode 100644 index 000000000000..7d693e3d2ed1 --- /dev/null +++ b/sdk/batch/azure-mgmt-batch/_meta.json @@ -0,0 +1,11 @@ +{ + "autorest": "3.4.2", + "use": [ + "@autorest/python@5.8.1", + "@autorest/modelerfour@4.19.2" + ], + "commit": "25af5c1c0fae2bc594c1932445d06209745f5917", + "repository_url": "https://github.com/Azure/azure-rest-api-specs", + "autorest_command": "autorest specification/batch/resource-manager/readme.md --multiapi --python --python-mode=update --python-sdks-folder=/home/vsts/work/1/s/azure-sdk-for-python/sdk --track2 --use=@autorest/python@5.8.1 --use=@autorest/modelerfour@4.19.2 --version=3.4.2", + "readme": "specification/batch/resource-manager/readme.md" +} \ No newline at end of file diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/_batch_management.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/_batch_management.py index 39895f567cf2..1c5b2f0b9152 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/_batch_management.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/_batch_management.py @@ -16,6 +16,7 @@ from typing import Any, Optional from azure.core.credentials import TokenCredential + from azure.core.pipeline.transport import HttpRequest, HttpResponse from ._configuration import BatchManagementConfiguration from .operations import BatchAccountOperations @@ -74,6 +75,7 @@ def __init__( client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)} self._serialize = Serializer(client_models) + self._serialize.client_side_validation = False self._deserialize = Deserializer(client_models) self.batch_account = BatchAccountOperations( @@ -95,6 +97,24 @@ def __init__( self.pool = PoolOperations( self._client, self._config, self._serialize, self._deserialize) + def _send_request(self, http_request, **kwargs): + # type: (HttpRequest, Any) -> HttpResponse + """Runs the network request through the client's chained policies. + + :param http_request: The network request you want to make. Required. + :type http_request: ~azure.core.pipeline.transport.HttpRequest + :keyword bool stream: Whether the response payload will be streamed. Defaults to True. + :return: The response of your network call. Does not do error handling on your response. + :rtype: ~azure.core.pipeline.transport.HttpResponse + """ + path_format_arguments = { + 'subscriptionId': self._serialize.url("self._config.subscription_id", self._config.subscription_id, 'str'), + } + http_request.url = self._client.format_url(http_request.url, **path_format_arguments) + stream = kwargs.pop("stream", True) + pipeline_response = self._client._pipeline.run(http_request, stream=stream, **kwargs) + return pipeline_response.http_response + def close(self): # type: () -> None self._client.close() diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/_metadata.json b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/_metadata.json index 48c70ba2589f..788868ca768e 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/_metadata.json +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/_metadata.json @@ -9,7 +9,9 @@ "custom_base_url": null, "azure_arm": true, "has_lro_operations": true, - "client_side_validation": true + "client_side_validation": false, + "sync_imports": "{\"typing\": {\"azurecore\": {\"azure.core.credentials\": [\"TokenCredential\"]}}, \"regular\": {\"azurecore\": {\"azure.profiles\": [\"KnownProfiles\", \"ProfileDefinition\"], \"azure.profiles.multiapiclient\": [\"MultiApiClientMixin\"], \"msrest\": [\"Deserializer\", \"Serializer\"], \"azure.mgmt.core\": [\"ARMPipelineClient\"]}, \"local\": {\"._configuration\": [\"BatchManagementConfiguration\"]}}, \"conditional\": {\"stdlib\": {\"typing\": [\"Any\", \"Optional\"]}, \"azurecore\": {\"azure.core.pipeline.transport\": [\"HttpRequest\", \"HttpResponse\"]}}}", + "async_imports": "{\"typing\": {\"azurecore\": {\"azure.core.credentials_async\": [\"AsyncTokenCredential\"]}}, \"regular\": {\"azurecore\": {\"azure.profiles\": [\"KnownProfiles\", \"ProfileDefinition\"], \"azure.profiles.multiapiclient\": [\"MultiApiClientMixin\"], \"msrest\": [\"Deserializer\", \"Serializer\"], \"azure.mgmt.core\": [\"AsyncARMPipelineClient\"]}, \"local\": {\"._configuration\": [\"BatchManagementConfiguration\"]}}, \"conditional\": {\"stdlib\": {\"typing\": [\"Any\", \"Optional\"]}, \"azurecore\": {\"azure.core.pipeline.transport\": [\"AsyncHttpResponse\", \"HttpRequest\"]}}}" }, "global_parameters": { "sync": { @@ -28,13 +30,13 @@ }, "async": { "credential": { - "signature": "credential, # type: \"AsyncTokenCredential\"", + "signature": "credential: \"AsyncTokenCredential\",", "description": "Credential needed for the client to connect to Azure.", "docstring_type": "~azure.core.credentials_async.AsyncTokenCredential", "required": true }, "subscription_id": { - "signature": "subscription_id, # type: str", + "signature": "subscription_id: str,", "description": "The Azure subscription ID. This is a GUID-formatted string (e.g. 00000000-0000-0000-0000-000000000000).", "docstring_type": "str", "required": true @@ -42,14 +44,58 @@ }, "constant": { }, - "call": "credential, subscription_id" + "call": "credential, subscription_id", + "service_client_specific": { + "sync": { + "api_version": { + "signature": "api_version=None, # type: Optional[str]", + "description": "API version to use if no profile is provided, or if missing in profile.", + "docstring_type": "str", + "required": false + }, + "base_url": { + "signature": "base_url=None, # type: Optional[str]", + "description": "Service URL", + "docstring_type": "str", + "required": false + }, + "profile": { + "signature": "profile=KnownProfiles.default, # type: KnownProfiles", + "description": "A profile definition, from KnownProfiles to dict.", + "docstring_type": "azure.profiles.KnownProfiles", + "required": false + } + }, + "async": { + "api_version": { + "signature": "api_version: Optional[str] = None,", + "description": "API version to use if no profile is provided, or if missing in profile.", + "docstring_type": "str", + "required": false + }, + "base_url": { + "signature": "base_url: Optional[str] = None,", + "description": "Service URL", + "docstring_type": "str", + "required": false + }, + "profile": { + "signature": "profile: KnownProfiles = KnownProfiles.default,", + "description": "A profile definition, from KnownProfiles to dict.", + "docstring_type": "azure.profiles.KnownProfiles", + "required": false + } + } + } }, "config": { "credential": true, "credential_scopes": ["https://management.azure.com/.default"], "credential_default_policy_type": "BearerTokenCredentialPolicy", "credential_default_policy_type_has_async_version": true, - "credential_key_header_name": null + "credential_key_header_name": null, + "sync_imports": "{\"regular\": {\"azurecore\": {\"azure.core.configuration\": [\"Configuration\"], \"azure.core.pipeline\": [\"policies\"], \"azure.mgmt.core.policies\": [\"ARMHttpLoggingPolicy\"]}, \"local\": {\"._version\": [\"VERSION\"]}}, \"conditional\": {\"stdlib\": {\"typing\": [\"Any\"]}}, \"typing\": {\"azurecore\": {\"azure.core.credentials\": [\"TokenCredential\"]}}}", + "async_imports": "{\"regular\": {\"azurecore\": {\"azure.core.configuration\": [\"Configuration\"], \"azure.core.pipeline\": [\"policies\"], \"azure.mgmt.core.policies\": [\"ARMHttpLoggingPolicy\"]}, \"local\": {\".._version\": [\"VERSION\"]}}, \"conditional\": {\"stdlib\": {\"typing\": [\"Any\"]}}, \"typing\": {\"azurecore\": {\"azure.core.credentials_async\": [\"AsyncTokenCredential\"]}}}" }, "operation_groups": { "batch_account": "BatchAccountOperations", @@ -61,9 +107,5 @@ "private_link_resource": "PrivateLinkResourceOperations", "private_endpoint_connection": "PrivateEndpointConnectionOperations", "pool": "PoolOperations" - }, - "operation_mixins": { - }, - "sync_imports": "None", - "async_imports": "None" + } } \ No newline at end of file diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/_version.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/_version.py index 509d4adc872c..c23f64adb662 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/_version.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "15.0.0" +VERSION = "14.0.0b1" diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/_batch_management.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/_batch_management.py index d249e8776e1a..6ae219f861ee 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/_batch_management.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/_batch_management.py @@ -8,6 +8,7 @@ from typing import Any, Optional, TYPE_CHECKING +from azure.core.pipeline.transport import AsyncHttpResponse, HttpRequest from azure.mgmt.core import AsyncARMPipelineClient from msrest import Deserializer, Serializer @@ -71,6 +72,7 @@ def __init__( client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)} self._serialize = Serializer(client_models) + self._serialize.client_side_validation = False self._deserialize = Deserializer(client_models) self.batch_account = BatchAccountOperations( @@ -92,6 +94,23 @@ def __init__( self.pool = PoolOperations( self._client, self._config, self._serialize, self._deserialize) + async def _send_request(self, http_request: HttpRequest, **kwargs: Any) -> AsyncHttpResponse: + """Runs the network request through the client's chained policies. + + :param http_request: The network request you want to make. Required. + :type http_request: ~azure.core.pipeline.transport.HttpRequest + :keyword bool stream: Whether the response payload will be streamed. Defaults to True. + :return: The response of your network call. Does not do error handling on your response. + :rtype: ~azure.core.pipeline.transport.AsyncHttpResponse + """ + path_format_arguments = { + 'subscriptionId': self._serialize.url("self._config.subscription_id", self._config.subscription_id, 'str'), + } + http_request.url = self._client.format_url(http_request.url, **path_format_arguments) + stream = kwargs.pop("stream", True) + pipeline_response = await self._client._pipeline.run(http_request, stream=stream, **kwargs) + return pipeline_response.http_response + async def close(self) -> None: await self._client.close() diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_application_operations.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_application_operations.py index 9ecfd4a97cf0..3cf65c49c46e 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_application_operations.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_application_operations.py @@ -47,7 +47,7 @@ async def create( account_name: str, application_name: str, parameters: Optional["_models.Application"] = None, - **kwargs + **kwargs: Any ) -> "_models.Application": """Adds an application to the specified Batch account. @@ -119,7 +119,7 @@ async def delete( resource_group_name: str, account_name: str, application_name: str, - **kwargs + **kwargs: Any ) -> None: """Deletes an application. @@ -178,7 +178,7 @@ async def get( resource_group_name: str, account_name: str, application_name: str, - **kwargs + **kwargs: Any ) -> "_models.Application": """Gets information about the specified application. @@ -241,7 +241,7 @@ async def update( account_name: str, application_name: str, parameters: "_models.Application", - **kwargs + **kwargs: Any ) -> "_models.Application": """Updates settings for the specified application. @@ -310,7 +310,7 @@ def list( resource_group_name: str, account_name: str, maxresults: Optional[int] = None, - **kwargs + **kwargs: Any ) -> AsyncIterable["_models.ListApplicationsResult"]: """Lists all of the applications in the specified account. diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_application_package_operations.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_application_package_operations.py index 0531798f35d2..c91aeb7ce9db 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_application_package_operations.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_application_package_operations.py @@ -48,7 +48,7 @@ async def activate( application_name: str, version_name: str, parameters: "_models.ActivateApplicationPackageParameters", - **kwargs + **kwargs: Any ) -> "_models.ApplicationPackage": """Activates the specified application package. This should be done after the ``ApplicationPackage`` was created and uploaded. This needs to be done before an @@ -124,7 +124,7 @@ async def create( application_name: str, version_name: str, parameters: Optional["_models.ApplicationPackage"] = None, - **kwargs + **kwargs: Any ) -> "_models.ApplicationPackage": """Creates an application package record. The record contains the SAS where the package should be uploaded to. Once it is uploaded the ``ApplicationPackage`` needs to be activated using @@ -202,7 +202,7 @@ async def delete( account_name: str, application_name: str, version_name: str, - **kwargs + **kwargs: Any ) -> None: """Deletes an application package record and its associated binary file. @@ -265,7 +265,7 @@ async def get( account_name: str, application_name: str, version_name: str, - **kwargs + **kwargs: Any ) -> "_models.ApplicationPackage": """Gets information about the specified application package. @@ -331,7 +331,7 @@ def list( account_name: str, application_name: str, maxresults: Optional[int] = None, - **kwargs + **kwargs: Any ) -> AsyncIterable["_models.ListApplicationPackagesResult"]: """Lists all of the application packages in the specified application. diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_batch_account_operations.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_batch_account_operations.py index a365b66623bc..3bd5784c2e62 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_batch_account_operations.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_batch_account_operations.py @@ -48,7 +48,7 @@ async def _create_initial( resource_group_name: str, account_name: str, parameters: "_models.BatchAccountCreateParameters", - **kwargs + **kwargs: Any ) -> Optional["_models.BatchAccount"]: cls = kwargs.pop('cls', None) # type: ClsType[Optional["_models.BatchAccount"]] error_map = { @@ -108,7 +108,7 @@ async def begin_create( resource_group_name: str, account_name: str, parameters: "_models.BatchAccountCreateParameters", - **kwargs + **kwargs: Any ) -> AsyncLROPoller["_models.BatchAccount"]: """Creates a new Batch account with the specified parameters. Existing accounts cannot be updated with this API and should instead be updated with the Update Batch Account API. @@ -125,8 +125,8 @@ async def begin_create( :type parameters: ~azure.mgmt.batch.models.BatchAccountCreateParameters :keyword callable cls: A custom type or function that will be passed the direct response :keyword str continuation_token: A continuation token to restart a poller from a saved state. - :keyword polling: True for ARMPolling, False for no polling, or a - polling object for personal polling strategy + :keyword polling: By default, your polling method will be AsyncARMPolling. + Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy. :paramtype polling: bool or ~azure.core.polling.AsyncPollingMethod :keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present. :return: An instance of AsyncLROPoller that returns either BatchAccount or the result of cls(response) @@ -184,7 +184,7 @@ async def update( resource_group_name: str, account_name: str, parameters: "_models.BatchAccountUpdateParameters", - **kwargs + **kwargs: Any ) -> "_models.BatchAccount": """Updates the properties of an existing Batch account. @@ -249,7 +249,7 @@ async def _delete_initial( self, resource_group_name: str, account_name: str, - **kwargs + **kwargs: Any ) -> None: cls = kwargs.pop('cls', None) # type: ClsType[None] error_map = { @@ -298,7 +298,7 @@ async def begin_delete( self, resource_group_name: str, account_name: str, - **kwargs + **kwargs: Any ) -> AsyncLROPoller[None]: """Deletes the specified Batch account. @@ -308,8 +308,8 @@ async def begin_delete( :type account_name: str :keyword callable cls: A custom type or function that will be passed the direct response :keyword str continuation_token: A continuation token to restart a poller from a saved state. - :keyword polling: True for ARMPolling, False for no polling, or a - polling object for personal polling strategy + :keyword polling: By default, your polling method will be AsyncARMPolling. + Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy. :paramtype polling: bool or ~azure.core.polling.AsyncPollingMethod :keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present. :return: An instance of AsyncLROPoller that returns either None or the result of cls(response) @@ -362,7 +362,7 @@ async def get( self, resource_group_name: str, account_name: str, - **kwargs + **kwargs: Any ) -> "_models.BatchAccount": """Gets information about the specified Batch account. @@ -418,7 +418,7 @@ async def get( def list( self, - **kwargs + **kwargs: Any ) -> AsyncIterable["_models.BatchAccountListResult"]: """Gets information about the Batch accounts associated with the subscription. @@ -485,7 +485,7 @@ async def get_next(next_link=None): def list_by_resource_group( self, resource_group_name: str, - **kwargs + **kwargs: Any ) -> AsyncIterable["_models.BatchAccountListResult"]: """Gets information about the Batch accounts associated with the specified resource group. @@ -556,7 +556,7 @@ async def synchronize_auto_storage_keys( self, resource_group_name: str, account_name: str, - **kwargs + **kwargs: Any ) -> None: """Synchronizes access keys for the auto-storage account configured for the specified Batch account. @@ -613,7 +613,7 @@ async def regenerate_key( resource_group_name: str, account_name: str, parameters: "_models.BatchAccountRegenerateKeyParameters", - **kwargs + **kwargs: Any ) -> "_models.BatchAccountKeys": """Regenerates the specified account key for the Batch account. @@ -678,7 +678,7 @@ async def get_keys( self, resource_group_name: str, account_name: str, - **kwargs + **kwargs: Any ) -> "_models.BatchAccountKeys": """Gets the account keys for the specified Batch account. diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_certificate_operations.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_certificate_operations.py index b186aad4a97e..057e469e1b44 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_certificate_operations.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_certificate_operations.py @@ -50,7 +50,7 @@ def list_by_batch_account( maxresults: Optional[int] = None, select: Optional[str] = None, filter: Optional[str] = None, - **kwargs + **kwargs: Any ) -> AsyncIterable["_models.ListCertificatesResult"]: """Lists all of the certificates in the specified account. @@ -143,7 +143,7 @@ async def create( parameters: "_models.CertificateCreateOrUpdateParameters", if_match: Optional[str] = None, if_none_match: Optional[str] = None, - **kwargs + **kwargs: Any ) -> "_models.Certificate": """Creates a new certificate inside the specified account. @@ -229,7 +229,7 @@ async def update( certificate_name: str, parameters: "_models.CertificateCreateOrUpdateParameters", if_match: Optional[str] = None, - **kwargs + **kwargs: Any ) -> "_models.Certificate": """Updates the properties of an existing certificate. @@ -307,7 +307,7 @@ async def _delete_initial( resource_group_name: str, account_name: str, certificate_name: str, - **kwargs + **kwargs: Any ) -> None: cls = kwargs.pop('cls', None) # type: ClsType[None] error_map = { @@ -358,7 +358,7 @@ async def begin_delete( resource_group_name: str, account_name: str, certificate_name: str, - **kwargs + **kwargs: Any ) -> AsyncLROPoller[None]: """Deletes the specified certificate. @@ -372,8 +372,8 @@ async def begin_delete( :type certificate_name: str :keyword callable cls: A custom type or function that will be passed the direct response :keyword str continuation_token: A continuation token to restart a poller from a saved state. - :keyword polling: True for ARMPolling, False for no polling, or a - polling object for personal polling strategy + :keyword polling: By default, your polling method will be AsyncARMPolling. + Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy. :paramtype polling: bool or ~azure.core.polling.AsyncPollingMethod :keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present. :return: An instance of AsyncLROPoller that returns either None or the result of cls(response) @@ -429,7 +429,7 @@ async def get( resource_group_name: str, account_name: str, certificate_name: str, - **kwargs + **kwargs: Any ) -> "_models.Certificate": """Gets information about the specified certificate. @@ -495,7 +495,7 @@ async def cancel_deletion( resource_group_name: str, account_name: str, certificate_name: str, - **kwargs + **kwargs: Any ) -> "_models.Certificate": """Cancels a failed deletion of a certificate from the specified account. diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_location_operations.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_location_operations.py index 3ccf31f9e3a3..5d2029b407cb 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_location_operations.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_location_operations.py @@ -43,7 +43,7 @@ def __init__(self, client, config, serializer, deserializer) -> None: async def get_quotas( self, location_name: str, - **kwargs + **kwargs: Any ) -> "_models.BatchLocationQuota": """Gets the Batch service quotas for the specified subscription at the given location. @@ -98,7 +98,7 @@ async def check_name_availability( self, location_name: str, parameters: "_models.CheckNameAvailabilityParameters", - **kwargs + **kwargs: Any ) -> "_models.CheckNameAvailabilityResult": """Checks whether the Batch account name is available in the specified region. diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_operations.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_operations.py index fdf8f325da6d..6e76c549b443 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_operations.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_operations.py @@ -43,7 +43,7 @@ def __init__(self, client, config, serializer, deserializer) -> None: def list( self, - **kwargs + **kwargs: Any ) -> AsyncIterable["_models.OperationListResult"]: """Lists available operations for the Microsoft.Batch provider. diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_pool_operations.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_pool_operations.py index f836c4dfe9fb..80ce28665600 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_pool_operations.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_pool_operations.py @@ -50,7 +50,7 @@ def list_by_batch_account( maxresults: Optional[int] = None, select: Optional[str] = None, filter: Optional[str] = None, - **kwargs + **kwargs: Any ) -> AsyncIterable["_models.ListPoolsResult"]: """Lists all of the pools in the specified account. @@ -154,7 +154,7 @@ async def create( parameters: "_models.Pool", if_match: Optional[str] = None, if_none_match: Optional[str] = None, - **kwargs + **kwargs: Any ) -> "_models.Pool": """Creates a new pool inside the specified account. @@ -238,7 +238,7 @@ async def update( pool_name: str, parameters: "_models.Pool", if_match: Optional[str] = None, - **kwargs + **kwargs: Any ) -> "_models.Pool": """Updates the properties of an existing pool. @@ -315,7 +315,7 @@ async def _delete_initial( resource_group_name: str, account_name: str, pool_name: str, - **kwargs + **kwargs: Any ) -> None: cls = kwargs.pop('cls', None) # type: ClsType[None] error_map = { @@ -366,7 +366,7 @@ async def begin_delete( resource_group_name: str, account_name: str, pool_name: str, - **kwargs + **kwargs: Any ) -> AsyncLROPoller[None]: """Deletes the specified pool. @@ -378,8 +378,8 @@ async def begin_delete( :type pool_name: str :keyword callable cls: A custom type or function that will be passed the direct response :keyword str continuation_token: A continuation token to restart a poller from a saved state. - :keyword polling: True for ARMPolling, False for no polling, or a - polling object for personal polling strategy + :keyword polling: By default, your polling method will be AsyncARMPolling. + Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy. :paramtype polling: bool or ~azure.core.polling.AsyncPollingMethod :keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present. :return: An instance of AsyncLROPoller that returns either None or the result of cls(response) @@ -435,7 +435,7 @@ async def get( resource_group_name: str, account_name: str, pool_name: str, - **kwargs + **kwargs: Any ) -> "_models.Pool": """Gets information about the specified pool. @@ -499,7 +499,7 @@ async def disable_auto_scale( resource_group_name: str, account_name: str, pool_name: str, - **kwargs + **kwargs: Any ) -> "_models.Pool": """Disables automatic scaling for a pool. @@ -563,7 +563,7 @@ async def stop_resize( resource_group_name: str, account_name: str, pool_name: str, - **kwargs + **kwargs: Any ) -> "_models.Pool": """Stops an ongoing resize operation on the pool. diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_private_endpoint_connection_operations.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_private_endpoint_connection_operations.py index 3710ee0f94cd..558a83e7614c 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_private_endpoint_connection_operations.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_private_endpoint_connection_operations.py @@ -48,7 +48,7 @@ def list_by_batch_account( resource_group_name: str, account_name: str, maxresults: Optional[int] = None, - **kwargs + **kwargs: Any ) -> AsyncIterable["_models.ListPrivateEndpointConnectionsResult"]: """Lists all of the private endpoint connections in the specified account. @@ -127,7 +127,7 @@ async def get( resource_group_name: str, account_name: str, private_endpoint_connection_name: str, - **kwargs + **kwargs: Any ) -> "_models.PrivateEndpointConnection": """Gets information about the specified private endpoint connection. @@ -192,7 +192,7 @@ async def _update_initial( private_endpoint_connection_name: str, parameters: "_models.PrivateEndpointConnection", if_match: Optional[str] = None, - **kwargs + **kwargs: Any ) -> Optional["_models.PrivateEndpointConnection"]: cls = kwargs.pop('cls', None) # type: ClsType[Optional["_models.PrivateEndpointConnection"]] error_map = { @@ -257,7 +257,7 @@ async def begin_update( private_endpoint_connection_name: str, parameters: "_models.PrivateEndpointConnection", if_match: Optional[str] = None, - **kwargs + **kwargs: Any ) -> AsyncLROPoller["_models.PrivateEndpointConnection"]: """Updates the properties of an existing private endpoint connection. @@ -276,8 +276,8 @@ async def begin_update( :type if_match: str :keyword callable cls: A custom type or function that will be passed the direct response :keyword str continuation_token: A continuation token to restart a poller from a saved state. - :keyword polling: True for ARMPolling, False for no polling, or a - polling object for personal polling strategy + :keyword polling: By default, your polling method will be AsyncARMPolling. + Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy. :paramtype polling: bool or ~azure.core.polling.AsyncPollingMethod :keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present. :return: An instance of AsyncLROPoller that returns either PrivateEndpointConnection or the result of cls(response) diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_private_link_resource_operations.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_private_link_resource_operations.py index fe2b13884966..a789f5c3ab3d 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_private_link_resource_operations.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_private_link_resource_operations.py @@ -46,7 +46,7 @@ def list_by_batch_account( resource_group_name: str, account_name: str, maxresults: Optional[int] = None, - **kwargs + **kwargs: Any ) -> AsyncIterable["_models.ListPrivateLinkResourcesResult"]: """Lists all of the private link resources in the specified account. @@ -125,7 +125,7 @@ async def get( resource_group_name: str, account_name: str, private_link_resource_name: str, - **kwargs + **kwargs: Any ) -> "_models.PrivateLinkResource": """Gets information about the specified private link resource. diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/models/_batch_management_enums.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/models/_batch_management_enums.py index 7706a62afdef..3687660bab5b 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/models/_batch_management_enums.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/models/_batch_management_enums.py @@ -30,16 +30,24 @@ class AccountKeyType(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The type of account key to regenerate. """ - PRIMARY = "Primary" #: The primary account key. - SECONDARY = "Secondary" #: The secondary account key. + #: The primary account key. + PRIMARY = "Primary" + #: The secondary account key. + SECONDARY = "Secondary" class AllocationState(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """Whether the pool is resizing. """ - STEADY = "Steady" #: The pool is not resizing. There are no changes to the number of nodes in the pool in progress. A pool enters this state when it is created and when no operations are being performed on the pool to change the number of nodes. - RESIZING = "Resizing" #: The pool is resizing; that is, compute nodes are being added to or removed from the pool. - STOPPING = "Stopping" #: The pool was resizing, but the user has requested that the resize be stopped, but the stop request has not yet been completed. + #: The pool is not resizing. There are no changes to the number of nodes in the pool in progress. + #: A pool enters this state when it is created and when no operations are being performed on the + #: pool to change the number of nodes. + STEADY = "Steady" + #: The pool is resizing; that is, compute nodes are being added to or removed from the pool. + RESIZING = "Resizing" + #: The pool was resizing, but the user has requested that the resize be stopped, but the stop + #: request has not yet been completed. + STOPPING = "Stopping" class AutoUserScope(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The default value is Pool. If the pool is running Windows a value of Task should be specified @@ -48,29 +56,46 @@ class AutoUserScope(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): which should not be accessible by normal tasks but should be accessible by start tasks. """ - TASK = "Task" #: Specifies that the service should create a new user for the task. - POOL = "Pool" #: Specifies that the task runs as the common auto user account which is created on every node in a pool. + #: Specifies that the service should create a new user for the task. + TASK = "Task" + #: Specifies that the task runs as the common auto user account which is created on every node in + #: a pool. + POOL = "Pool" class CachingType(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The type of caching to enable for the disk. """ - NONE = "None" #: The caching mode for the disk is not enabled. - READ_ONLY = "ReadOnly" #: The caching mode for the disk is read only. - READ_WRITE = "ReadWrite" #: The caching mode for the disk is read and write. + #: The caching mode for the disk is not enabled. + NONE = "None" + #: The caching mode for the disk is read only. + READ_ONLY = "ReadOnly" + #: The caching mode for the disk is read and write. + READ_WRITE = "ReadWrite" class CertificateFormat(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The format of the certificate - either Pfx or Cer. If omitted, the default is Pfx. """ - PFX = "Pfx" #: The certificate is a PFX (PKCS#12) formatted certificate or certificate chain. - CER = "Cer" #: The certificate is a base64-encoded X.509 certificate. + #: The certificate is a PFX (PKCS#12) formatted certificate or certificate chain. + PFX = "Pfx" + #: The certificate is a base64-encoded X.509 certificate. + CER = "Cer" class CertificateProvisioningState(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): - SUCCEEDED = "Succeeded" #: The certificate is available for use in pools. - DELETING = "Deleting" #: The user has requested that the certificate be deleted, but the delete operation has not yet completed. You may not reference the certificate when creating or updating pools. - FAILED = "Failed" #: The user requested that the certificate be deleted, but there are pools that still have references to the certificate, or it is still installed on one or more compute nodes. (The latter can occur if the certificate has been removed from the pool, but the node has not yet restarted. Nodes refresh their certificates only when they restart.) You may use the cancel certificate delete operation to cancel the delete, or the delete certificate operation to retry the delete. + #: The certificate is available for use in pools. + SUCCEEDED = "Succeeded" + #: The user has requested that the certificate be deleted, but the delete operation has not yet + #: completed. You may not reference the certificate when creating or updating pools. + DELETING = "Deleting" + #: The user requested that the certificate be deleted, but there are pools that still have + #: references to the certificate, or it is still installed on one or more compute nodes. (The + #: latter can occur if the certificate has been removed from the pool, but the node has not yet + #: restarted. Nodes refresh their certificates only when they restart.) You may use the cancel + #: certificate delete operation to cancel the delete, or the delete certificate operation to retry + #: the delete. + FAILED = "Failed" class CertificateStoreLocation(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The default value is currentUser. This property is applicable only for pools configured with @@ -82,60 +107,91 @@ class CertificateStoreLocation(with_metaclass(_CaseInsensitiveEnumMeta, str, Enu directory (e.g., /home/{user-name}/certs) and certificates are placed in that directory. """ - CURRENT_USER = "CurrentUser" #: Certificates should be installed to the CurrentUser certificate store. - LOCAL_MACHINE = "LocalMachine" #: Certificates should be installed to the LocalMachine certificate store. + #: Certificates should be installed to the CurrentUser certificate store. + CURRENT_USER = "CurrentUser" + #: Certificates should be installed to the LocalMachine certificate store. + LOCAL_MACHINE = "LocalMachine" class CertificateVisibility(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): - START_TASK = "StartTask" #: The certificate should be visible to the user account under which the start task is run. Note that if AutoUser Scope is Pool for both the StartTask and a Task, this certificate will be visible to the Task as well. - TASK = "Task" #: The certificate should be visible to the user accounts under which job tasks are run. - REMOTE_USER = "RemoteUser" #: The certificate should be visible to the user accounts under which users remotely access the node. + #: The certificate should be visible to the user account under which the start task is run. Note + #: that if AutoUser Scope is Pool for both the StartTask and a Task, this certificate will be + #: visible to the Task as well. + START_TASK = "StartTask" + #: The certificate should be visible to the user accounts under which job tasks are run. + TASK = "Task" + #: The certificate should be visible to the user accounts under which users remotely access the + #: node. + REMOTE_USER = "RemoteUser" class ComputeNodeDeallocationOption(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """Determines what to do with a node and its running task(s) after it has been selected for deallocation. """ - REQUEUE = "Requeue" #: Terminate running task processes and requeue the tasks. The tasks will run again when a node is available. Remove nodes as soon as tasks have been terminated. - TERMINATE = "Terminate" #: Terminate running tasks. The tasks will be completed with failureInfo indicating that they were terminated, and will not run again. Remove nodes as soon as tasks have been terminated. - TASK_COMPLETION = "TaskCompletion" #: Allow currently running tasks to complete. Schedule no new tasks while waiting. Remove nodes when all tasks have completed. - RETAINED_DATA = "RetainedData" #: Allow currently running tasks to complete, then wait for all task data retention periods to expire. Schedule no new tasks while waiting. Remove nodes when all task retention periods have expired. + #: Terminate running task processes and requeue the tasks. The tasks will run again when a node is + #: available. Remove nodes as soon as tasks have been terminated. + REQUEUE = "Requeue" + #: Terminate running tasks. The tasks will be completed with failureInfo indicating that they were + #: terminated, and will not run again. Remove nodes as soon as tasks have been terminated. + TERMINATE = "Terminate" + #: Allow currently running tasks to complete. Schedule no new tasks while waiting. Remove nodes + #: when all tasks have completed. + TASK_COMPLETION = "TaskCompletion" + #: Allow currently running tasks to complete, then wait for all task data retention periods to + #: expire. Schedule no new tasks while waiting. Remove nodes when all task retention periods have + #: expired. + RETAINED_DATA = "RetainedData" class ComputeNodeFillType(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """How tasks should be distributed across compute nodes. """ - SPREAD = "Spread" #: Tasks should be assigned evenly across all nodes in the pool. - PACK = "Pack" #: As many tasks as possible (taskSlotsPerNode) should be assigned to each node in the pool before any tasks are assigned to the next node in the pool. + #: Tasks should be assigned evenly across all nodes in the pool. + SPREAD = "Spread" + #: As many tasks as possible (taskSlotsPerNode) should be assigned to each node in the pool before + #: any tasks are assigned to the next node in the pool. + PACK = "Pack" class ContainerWorkingDirectory(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """A flag to indicate where the container task working directory is. The default is 'taskWorkingDirectory'. """ - TASK_WORKING_DIRECTORY = "TaskWorkingDirectory" #: Use the standard Batch service task working directory, which will contain the Task resource files populated by Batch. - CONTAINER_IMAGE_DEFAULT = "ContainerImageDefault" #: Using container image defined working directory. Beware that this directory will not contain the resource files downloaded by Batch. + #: Use the standard Batch service task working directory, which will contain the Task resource + #: files populated by Batch. + TASK_WORKING_DIRECTORY = "TaskWorkingDirectory" + #: Using container image defined working directory. Beware that this directory will not contain + #: the resource files downloaded by Batch. + CONTAINER_IMAGE_DEFAULT = "ContainerImageDefault" class DiskEncryptionTarget(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """If omitted, no disks on the compute nodes in the pool will be encrypted. """ - OS_DISK = "OsDisk" #: The OS Disk on the compute node is encrypted. - TEMPORARY_DISK = "TemporaryDisk" #: The temporary disk on the compute node is encrypted. On Linux this encryption applies to other partitions (such as those on mounted data disks) when encryption occurs at boot time. + #: The OS Disk on the compute node is encrypted. + OS_DISK = "OsDisk" + #: The temporary disk on the compute node is encrypted. On Linux this encryption applies to other + #: partitions (such as those on mounted data disks) when encryption occurs at boot time. + TEMPORARY_DISK = "TemporaryDisk" class ElevationLevel(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The elevation level of the user. """ - NON_ADMIN = "NonAdmin" #: The user is a standard user without elevated access. - ADMIN = "Admin" #: The user is a user with elevated access and operates with full Administrator permissions. + #: The user is a standard user without elevated access. + NON_ADMIN = "NonAdmin" + #: The user is a user with elevated access and operates with full Administrator permissions. + ADMIN = "Admin" class InboundEndpointProtocol(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The protocol of the endpoint. """ - TCP = "TCP" #: Use TCP for the endpoint. - UDP = "UDP" #: Use UDP for the endpoint. + #: Use TCP for the endpoint. + TCP = "TCP" + #: Use UDP for the endpoint. + UDP = "UDP" class InterNodeCommunicationState(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """This imposes restrictions on which nodes can be assigned to the pool. Enabling this value can @@ -143,128 +199,183 @@ class InterNodeCommunicationState(with_metaclass(_CaseInsensitiveEnumMeta, str, specified, this value defaults to 'Disabled'. """ - ENABLED = "Enabled" #: Enable network communication between virtual machines. - DISABLED = "Disabled" #: Disable network communication between virtual machines. + #: Enable network communication between virtual machines. + ENABLED = "Enabled" + #: Disable network communication between virtual machines. + DISABLED = "Disabled" class IPAddressProvisioningType(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The provisioning type for Public IP Addresses for the Batch Pool. """ - BATCH_MANAGED = "BatchManaged" #: A public IP will be created and managed by Batch. There may be multiple public IPs depending on the size of the Pool. - USER_MANAGED = "UserManaged" #: Public IPs are provided by the user and will be used to provision the Compute Nodes. - NO_PUBLIC_IP_ADDRESSES = "NoPublicIPAddresses" #: No public IP Address will be created for the Compute Nodes in the Pool. + #: A public IP will be created and managed by Batch. There may be multiple public IPs depending on + #: the size of the Pool. + BATCH_MANAGED = "BatchManaged" + #: Public IPs are provided by the user and will be used to provision the Compute Nodes. + USER_MANAGED = "UserManaged" + #: No public IP Address will be created for the Compute Nodes in the Pool. + NO_PUBLIC_IP_ADDRESSES = "NoPublicIPAddresses" class KeySource(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """Type of the key source. """ - MICROSOFT_BATCH = "Microsoft.Batch" #: Batch creates and manages the encryption keys used to protect the account data. - MICROSOFT_KEY_VAULT = "Microsoft.KeyVault" #: The encryption keys used to protect the account data are stored in an external key vault. If this is set then the Batch Account identity must be set to ``SystemAssigned`` and a valid Key Identifier must also be supplied under the keyVaultProperties. + #: Batch creates and manages the encryption keys used to protect the account data. + MICROSOFT_BATCH = "Microsoft.Batch" + #: The encryption keys used to protect the account data are stored in an external key vault. If + #: this is set then the Batch Account identity must be set to ``SystemAssigned`` and a valid Key + #: Identifier must also be supplied under the keyVaultProperties. + MICROSOFT_KEY_VAULT = "Microsoft.KeyVault" class LoginMode(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """Specifies login mode for the user. The default value for VirtualMachineConfiguration pools is interactive mode and for CloudServiceConfiguration pools is batch mode. """ - BATCH = "Batch" #: The LOGON32_LOGON_BATCH Win32 login mode. The batch login mode is recommended for long running parallel processes. - INTERACTIVE = "Interactive" #: The LOGON32_LOGON_INTERACTIVE Win32 login mode. Some applications require having permissions associated with the interactive login mode. If this is the case for an application used in your task, then this option is recommended. + #: The LOGON32_LOGON_BATCH Win32 login mode. The batch login mode is recommended for long running + #: parallel processes. + BATCH = "Batch" + #: The LOGON32_LOGON_INTERACTIVE Win32 login mode. Some applications require having permissions + #: associated with the interactive login mode. If this is the case for an application used in your + #: task, then this option is recommended. + INTERACTIVE = "Interactive" class NameAvailabilityReason(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """Gets the reason that a Batch account name could not be used. The Reason element is only returned if NameAvailable is false. """ - INVALID = "Invalid" #: The requested name is invalid. - ALREADY_EXISTS = "AlreadyExists" #: The requested name is already in use. + #: The requested name is invalid. + INVALID = "Invalid" + #: The requested name is already in use. + ALREADY_EXISTS = "AlreadyExists" class NetworkSecurityGroupRuleAccess(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The action that should be taken for a specified IP address, subnet range or tag. """ - ALLOW = "Allow" #: Allow access. - DENY = "Deny" #: Deny access. + #: Allow access. + ALLOW = "Allow" + #: Deny access. + DENY = "Deny" class NodePlacementPolicyType(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The default value is regional. """ - REGIONAL = "Regional" #: All nodes in the pool will be allocated in the same region. - ZONAL = "Zonal" #: Nodes in the pool will be spread across different zones with best effort balancing. + #: All nodes in the pool will be allocated in the same region. + REGIONAL = "Regional" + #: Nodes in the pool will be spread across different zones with best effort balancing. + ZONAL = "Zonal" class PackageState(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The current state of the application package. """ - PENDING = "Pending" #: The application package has been created but has not yet been activated. - ACTIVE = "Active" #: The application package is ready for use. + #: The application package has been created but has not yet been activated. + PENDING = "Pending" + #: The application package is ready for use. + ACTIVE = "Active" class PoolAllocationMode(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The allocation mode for creating pools in the Batch account. """ - BATCH_SERVICE = "BatchService" #: Pools will be allocated in subscriptions owned by the Batch service. - USER_SUBSCRIPTION = "UserSubscription" #: Pools will be allocated in a subscription owned by the user. + #: Pools will be allocated in subscriptions owned by the Batch service. + BATCH_SERVICE = "BatchService" + #: Pools will be allocated in a subscription owned by the user. + USER_SUBSCRIPTION = "UserSubscription" class PoolIdentityType(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The type of identity used for the Batch Pool. """ - USER_ASSIGNED = "UserAssigned" #: Batch pool has user assigned identities with it. - NONE = "None" #: Batch pool has no identity associated with it. Setting ``None`` in update pool will remove existing identities. + #: Batch pool has user assigned identities with it. + USER_ASSIGNED = "UserAssigned" + #: Batch pool has no identity associated with it. Setting ``None`` in update pool will remove + #: existing identities. + NONE = "None" class PoolProvisioningState(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The current state of the pool. """ - SUCCEEDED = "Succeeded" #: The pool is available to run tasks subject to the availability of compute nodes. - DELETING = "Deleting" #: The user has requested that the pool be deleted, but the delete operation has not yet completed. + #: The pool is available to run tasks subject to the availability of compute nodes. + SUCCEEDED = "Succeeded" + #: The user has requested that the pool be deleted, but the delete operation has not yet + #: completed. + DELETING = "Deleting" class PrivateEndpointConnectionProvisioningState(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The provisioning state of the private endpoint connection. """ - SUCCEEDED = "Succeeded" #: The connection status is final and is ready for use if Status is Approved. - UPDATING = "Updating" #: The user has requested that the connection status be updated, but the update operation has not yet completed. You may not reference the connection when connecting the Batch account. - FAILED = "Failed" #: The user requested that the connection be updated and it failed. You may retry the update operation. + #: The connection status is final and is ready for use if Status is Approved. + SUCCEEDED = "Succeeded" + #: The user has requested that the connection status be updated, but the update operation has not + #: yet completed. You may not reference the connection when connecting the Batch account. + UPDATING = "Updating" + #: The user requested that the connection be updated and it failed. You may retry the update + #: operation. + FAILED = "Failed" class PrivateLinkServiceConnectionStatus(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The status of the Batch private endpoint connection """ - APPROVED = "Approved" #: The private endpoint connection is approved and can be used to access Batch account. - PENDING = "Pending" #: The private endpoint connection is pending and cannot be used to access Batch account. - REJECTED = "Rejected" #: The private endpoint connection is rejected and cannot be used to access Batch account. - DISCONNECTED = "Disconnected" #: The private endpoint connection is disconnected and cannot be used to access Batch account. + #: The private endpoint connection is approved and can be used to access Batch account. + APPROVED = "Approved" + #: The private endpoint connection is pending and cannot be used to access Batch account. + PENDING = "Pending" + #: The private endpoint connection is rejected and cannot be used to access Batch account. + REJECTED = "Rejected" + #: The private endpoint connection is disconnected and cannot be used to access Batch account. + DISCONNECTED = "Disconnected" class ProvisioningState(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The provisioned state of the resource """ - INVALID = "Invalid" #: The account is in an invalid state. - CREATING = "Creating" #: The account is being created. - DELETING = "Deleting" #: The account is being deleted. - SUCCEEDED = "Succeeded" #: The account has been created and is ready for use. - FAILED = "Failed" #: The last operation for the account is failed. - CANCELLED = "Cancelled" #: The last operation for the account is cancelled. + #: The account is in an invalid state. + INVALID = "Invalid" + #: The account is being created. + CREATING = "Creating" + #: The account is being deleted. + DELETING = "Deleting" + #: The account has been created and is ready for use. + SUCCEEDED = "Succeeded" + #: The last operation for the account is failed. + FAILED = "Failed" + #: The last operation for the account is cancelled. + CANCELLED = "Cancelled" class PublicNetworkAccessType(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The network access type for operating on the resources in the Batch account. """ - ENABLED = "Enabled" #: Enables connectivity to Azure Batch through public DNS. - DISABLED = "Disabled" #: Disables public connectivity and enables private connectivity to Azure Batch Service through private endpoint resource. + #: Enables connectivity to Azure Batch through public DNS. + ENABLED = "Enabled" + #: Disables public connectivity and enables private connectivity to Azure Batch Service through + #: private endpoint resource. + DISABLED = "Disabled" class ResourceIdentityType(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The type of identity used for the Batch account. """ - SYSTEM_ASSIGNED = "SystemAssigned" #: Batch account has a system assigned identity with it. - USER_ASSIGNED = "UserAssigned" #: Batch account has user assigned identities with it. - NONE = "None" #: Batch account has no identity associated with it. Setting ``None`` in update account will remove existing identities. + #: Batch account has a system assigned identity with it. + SYSTEM_ASSIGNED = "SystemAssigned" + #: Batch account has user assigned identities with it. + USER_ASSIGNED = "UserAssigned" + #: Batch account has no identity associated with it. Setting ``None`` in update account will + #: remove existing identities. + NONE = "None" class StorageAccountType(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)): """The storage account type for use in creating data disks. """ - STANDARD_LRS = "Standard_LRS" #: The data disk should use standard locally redundant storage. - PREMIUM_LRS = "Premium_LRS" #: The data disk should use premium locally redundant storage. + #: The data disk should use standard locally redundant storage. + STANDARD_LRS = "Standard_LRS" + #: The data disk should use premium locally redundant storage. + PREMIUM_LRS = "Premium_LRS" diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/models/_models.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/models/_models.py index c998938bfd70..3d9f9b7dbac4 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/models/_models.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/models/_models.py @@ -1297,7 +1297,7 @@ class CheckNameAvailabilityParameters(msrest.serialization.Model): :param name: Required. The name to check for availability. :type name: str - :ivar type: Required. The resource type. Default value: "Microsoft.Batch/batchAccounts". + :ivar type: The resource type. Has constant value: "Microsoft.Batch/batchAccounts". :vartype type: str """ @@ -1448,8 +1448,7 @@ class CloudServiceConfiguration(msrest.serialization.Model): 2008 R2 SP1. 3 - OS Family 3, equivalent to Windows Server 2012. 4 - OS Family 4, equivalent to Windows Server 2012 R2. 5 - OS Family 5, equivalent to Windows Server 2016. 6 - OS Family 6, equivalent to Windows Server 2019. For more information, see Azure Guest OS Releases - (https://azure.microsoft.com/documentation/articles/cloud-services-guestos-update- - matrix/#releases). + (https://azure.microsoft.com/documentation/articles/cloud-services-guestos-update-matrix/#releases). :type os_family: str :param os_version: The default value is * which specifies the latest operating system version for the specified OS family. @@ -1541,7 +1540,7 @@ class ContainerConfiguration(msrest.serialization.Model): All required parameters must be populated in order to send to Azure. - :ivar type: Required. The container technology to be used. Default value: "DockerCompatible". + :ivar type: The container technology to be used. Has constant value: "DockerCompatible". :vartype type: str :param container_image_names: This is the full image reference, as would be specified to "docker pull". An image will be sourced from the default Docker registry unless the image is @@ -1622,8 +1621,8 @@ class DataDisk(msrest.serialization.Model): readWrite - The caching mode for the disk is read and write. The default value for caching is none. For information about the caching options see: - https://blogs.msdn.microsoft.com/windowsazurestorage/2012/06/27/exploring-windows-azure-drives- - disks-and-images/. Possible values include: "None", "ReadOnly", "ReadWrite". + https://blogs.msdn.microsoft.com/windowsazurestorage/2012/06/27/exploring-windows-azure-drives-disks-and-images/. + Possible values include: "None", "ReadOnly", "ReadWrite". :type caching: str or ~azure.mgmt.batch.models.CachingType :param disk_size_gb: Required. The initial disk size in GB when creating new data disk. :type disk_size_gb: int @@ -1850,8 +1849,7 @@ class ImageReference(msrest.serialization.Model): :param id: This property is mutually exclusive with other properties. The Shared Image Gallery image must have replicas in the same region as the Azure Batch account. For information about the firewall settings for the Batch node agent to communicate with the Batch service see - https://docs.microsoft.com/en-us/azure/batch/batch-api-basics#virtual-network-vnet-and- - firewall-configuration. + https://docs.microsoft.com/en-us/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration. :type id: str """ @@ -2248,8 +2246,8 @@ class NetworkConfiguration(msrest.serialization.Model): 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. For pools created with a cloud service configuration, enable ports 10100, 20100, and 30100. Also enable outbound connections to Azure Storage on port 443. For cloudServiceConfiguration pools, only 'classic' - VNETs are supported. For more details see: https://docs.microsoft.com/en-us/azure/batch/batch- - api-basics#virtual-network-vnet-and-firewall-configuration. + VNETs are supported. For more details see: + https://docs.microsoft.com/en-us/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration. :type subnet_id: str :param endpoint_configuration: Pool endpoint configuration is only supported on pools with the virtualMachineConfiguration property. @@ -2389,7 +2387,7 @@ class Operation(msrest.serialization.Model): :param origin: The intended executor of the operation. :type origin: str :param properties: Any object. - :type properties: object + :type properties: any """ _attribute_map = { @@ -2506,9 +2504,10 @@ class Pool(ProxyResource): sizes for pools using images from the Virtual Machines Marketplace (pools created with virtualMachineConfiguration) see Sizes for Virtual Machines (Linux) (https://azure.microsoft.com/documentation/articles/virtual-machines-linux-sizes/) or Sizes for - Virtual Machines (Windows) (https://azure.microsoft.com/documentation/articles/virtual- - machines-windows-sizes/). Batch supports all Azure VM sizes except STANDARD_A0 and those with - premium storage (STANDARD_GS, STANDARD_DS, and STANDARD_DSV2 series). + Virtual Machines (Windows) + (https://azure.microsoft.com/documentation/articles/virtual-machines-windows-sizes/). Batch + supports all Azure VM sizes except STANDARD_A0 and those with premium storage (STANDARD_GS, + STANDARD_DS, and STANDARD_DSV2 series). :type vm_size: str :param deployment_configuration: Using CloudServiceConfiguration specifies that the nodes should be creating using Azure Cloud Services (PaaS), while VirtualMachineConfiguration uses @@ -3370,10 +3369,10 @@ class VMExtension(msrest.serialization.Model): upgrade minor versions unless redeployed, even with this property set to true. :type auto_upgrade_minor_version: bool :param settings: Any object. - :type settings: object + :type settings: any :param protected_settings: The extension can contain either protectedSettings or protectedSettingsFromKeyVault or no protected settings at all. - :type protected_settings: object + :type protected_settings: any :param provision_after_extensions: Collection of extension names after which this extension needs to be provisioned. :type provision_after_extensions: list[str] diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/models/_models_py3.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/models/_models_py3.py index 584f7cbd85bb..4a19756646eb 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/models/_models_py3.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/models/_models_py3.py @@ -7,7 +7,7 @@ # -------------------------------------------------------------------------- import datetime -from typing import Dict, List, Optional, Union +from typing import Any, Dict, List, Optional, Union import msrest.serialization @@ -1399,7 +1399,7 @@ class CheckNameAvailabilityParameters(msrest.serialization.Model): :param name: Required. The name to check for availability. :type name: str - :ivar type: Required. The resource type. Default value: "Microsoft.Batch/batchAccounts". + :ivar type: The resource type. Has constant value: "Microsoft.Batch/batchAccounts". :vartype type: str """ @@ -1563,8 +1563,7 @@ class CloudServiceConfiguration(msrest.serialization.Model): 2008 R2 SP1. 3 - OS Family 3, equivalent to Windows Server 2012. 4 - OS Family 4, equivalent to Windows Server 2012 R2. 5 - OS Family 5, equivalent to Windows Server 2016. 6 - OS Family 6, equivalent to Windows Server 2019. For more information, see Azure Guest OS Releases - (https://azure.microsoft.com/documentation/articles/cloud-services-guestos-update- - matrix/#releases). + (https://azure.microsoft.com/documentation/articles/cloud-services-guestos-update-matrix/#releases). :type os_family: str :param os_version: The default value is * which specifies the latest operating system version for the specified OS family. @@ -1659,7 +1658,7 @@ class ContainerConfiguration(msrest.serialization.Model): All required parameters must be populated in order to send to Azure. - :ivar type: Required. The container technology to be used. Default value: "DockerCompatible". + :ivar type: The container technology to be used. Has constant value: "DockerCompatible". :vartype type: str :param container_image_names: This is the full image reference, as would be specified to "docker pull". An image will be sourced from the default Docker registry unless the image is @@ -1747,8 +1746,8 @@ class DataDisk(msrest.serialization.Model): readWrite - The caching mode for the disk is read and write. The default value for caching is none. For information about the caching options see: - https://blogs.msdn.microsoft.com/windowsazurestorage/2012/06/27/exploring-windows-azure-drives- - disks-and-images/. Possible values include: "None", "ReadOnly", "ReadWrite". + https://blogs.msdn.microsoft.com/windowsazurestorage/2012/06/27/exploring-windows-azure-drives-disks-and-images/. + Possible values include: "None", "ReadOnly", "ReadWrite". :type caching: str or ~azure.mgmt.batch.models.CachingType :param disk_size_gb: Required. The initial disk size in GB when creating new data disk. :type disk_size_gb: int @@ -2001,8 +2000,7 @@ class ImageReference(msrest.serialization.Model): :param id: This property is mutually exclusive with other properties. The Shared Image Gallery image must have replicas in the same region as the Azure Batch account. For information about the firewall settings for the Batch node agent to communicate with the Batch service see - https://docs.microsoft.com/en-us/azure/batch/batch-api-basics#virtual-network-vnet-and- - firewall-configuration. + https://docs.microsoft.com/en-us/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration. :type id: str """ @@ -2447,8 +2445,8 @@ class NetworkConfiguration(msrest.serialization.Model): 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. For pools created with a cloud service configuration, enable ports 10100, 20100, and 30100. Also enable outbound connections to Azure Storage on port 443. For cloudServiceConfiguration pools, only 'classic' - VNETs are supported. For more details see: https://docs.microsoft.com/en-us/azure/batch/batch- - api-basics#virtual-network-vnet-and-firewall-configuration. + VNETs are supported. For more details see: + https://docs.microsoft.com/en-us/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration. :type subnet_id: str :param endpoint_configuration: Pool endpoint configuration is only supported on pools with the virtualMachineConfiguration property. @@ -2603,7 +2601,7 @@ class Operation(msrest.serialization.Model): :param origin: The intended executor of the operation. :type origin: str :param properties: Any object. - :type properties: object + :type properties: any """ _attribute_map = { @@ -2619,7 +2617,7 @@ def __init__( name: Optional[str] = None, display: Optional["OperationDisplay"] = None, origin: Optional[str] = None, - properties: Optional[object] = None, + properties: Optional[Any] = None, **kwargs ): super(Operation, self).__init__(**kwargs) @@ -2733,9 +2731,10 @@ class Pool(ProxyResource): sizes for pools using images from the Virtual Machines Marketplace (pools created with virtualMachineConfiguration) see Sizes for Virtual Machines (Linux) (https://azure.microsoft.com/documentation/articles/virtual-machines-linux-sizes/) or Sizes for - Virtual Machines (Windows) (https://azure.microsoft.com/documentation/articles/virtual- - machines-windows-sizes/). Batch supports all Azure VM sizes except STANDARD_A0 and those with - premium storage (STANDARD_GS, STANDARD_DS, and STANDARD_DSV2 series). + Virtual Machines (Windows) + (https://azure.microsoft.com/documentation/articles/virtual-machines-windows-sizes/). Batch + supports all Azure VM sizes except STANDARD_A0 and those with premium storage (STANDARD_GS, + STANDARD_DS, and STANDARD_DSV2 series). :type vm_size: str :param deployment_configuration: Using CloudServiceConfiguration specifies that the nodes should be creating using Azure Cloud Services (PaaS), while VirtualMachineConfiguration uses @@ -3680,10 +3679,10 @@ class VMExtension(msrest.serialization.Model): upgrade minor versions unless redeployed, even with this property set to true. :type auto_upgrade_minor_version: bool :param settings: Any object. - :type settings: object + :type settings: any :param protected_settings: The extension can contain either protectedSettings or protectedSettingsFromKeyVault or no protected settings at all. - :type protected_settings: object + :type protected_settings: any :param provision_after_extensions: Collection of extension names after which this extension needs to be provisioned. :type provision_after_extensions: list[str] @@ -3714,8 +3713,8 @@ def __init__( type: str, type_handler_version: Optional[str] = None, auto_upgrade_minor_version: Optional[bool] = None, - settings: Optional[object] = None, - protected_settings: Optional[object] = None, + settings: Optional[Any] = None, + protected_settings: Optional[Any] = None, provision_after_extensions: Optional[List[str]] = None, **kwargs ): diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_batch_account_operations.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_batch_account_operations.py index f75f8917b143..bb5c130f0562 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_batch_account_operations.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_batch_account_operations.py @@ -131,8 +131,8 @@ def begin_create( :type parameters: ~azure.mgmt.batch.models.BatchAccountCreateParameters :keyword callable cls: A custom type or function that will be passed the direct response :keyword str continuation_token: A continuation token to restart a poller from a saved state. - :keyword polling: True for ARMPolling, False for no polling, or a - polling object for personal polling strategy + :keyword polling: By default, your polling method will be ARMPolling. + Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy. :paramtype polling: bool or ~azure.core.polling.PollingMethod :keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present. :return: An instance of LROPoller that returns either BatchAccount or the result of cls(response) @@ -317,8 +317,8 @@ def begin_delete( :type account_name: str :keyword callable cls: A custom type or function that will be passed the direct response :keyword str continuation_token: A continuation token to restart a poller from a saved state. - :keyword polling: True for ARMPolling, False for no polling, or a - polling object for personal polling strategy + :keyword polling: By default, your polling method will be ARMPolling. + Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy. :paramtype polling: bool or ~azure.core.polling.PollingMethod :keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present. :return: An instance of LROPoller that returns either None or the result of cls(response) diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_certificate_operations.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_certificate_operations.py index 460052244c3a..c28bda191342 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_certificate_operations.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_certificate_operations.py @@ -381,8 +381,8 @@ def begin_delete( :type certificate_name: str :keyword callable cls: A custom type or function that will be passed the direct response :keyword str continuation_token: A continuation token to restart a poller from a saved state. - :keyword polling: True for ARMPolling, False for no polling, or a - polling object for personal polling strategy + :keyword polling: By default, your polling method will be ARMPolling. + Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy. :paramtype polling: bool or ~azure.core.polling.PollingMethod :keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present. :return: An instance of LROPoller that returns either None or the result of cls(response) diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_pool_operations.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_pool_operations.py index ba4d46fb4394..f8753eb28d22 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_pool_operations.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_pool_operations.py @@ -387,8 +387,8 @@ def begin_delete( :type pool_name: str :keyword callable cls: A custom type or function that will be passed the direct response :keyword str continuation_token: A continuation token to restart a poller from a saved state. - :keyword polling: True for ARMPolling, False for no polling, or a - polling object for personal polling strategy + :keyword polling: By default, your polling method will be ARMPolling. + Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy. :paramtype polling: bool or ~azure.core.polling.PollingMethod :keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present. :return: An instance of LROPoller that returns either None or the result of cls(response) diff --git a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_private_endpoint_connection_operations.py b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_private_endpoint_connection_operations.py index e4ceaefcda4f..6bcb1b3580f7 100644 --- a/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_private_endpoint_connection_operations.py +++ b/sdk/batch/azure-mgmt-batch/azure/mgmt/batch/operations/_private_endpoint_connection_operations.py @@ -284,8 +284,8 @@ def begin_update( :type if_match: str :keyword callable cls: A custom type or function that will be passed the direct response :keyword str continuation_token: A continuation token to restart a poller from a saved state. - :keyword polling: True for ARMPolling, False for no polling, or a - polling object for personal polling strategy + :keyword polling: By default, your polling method will be ARMPolling. + Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy. :paramtype polling: bool or ~azure.core.polling.PollingMethod :keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present. :return: An instance of LROPoller that returns either PrivateEndpointConnection or the result of cls(response)