diff --git a/sdk/rdbms/azure-mgmt-rdbms/MANIFEST.in b/sdk/rdbms/azure-mgmt-rdbms/MANIFEST.in index a3cb07df87658..3a9b6517412bc 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/MANIFEST.in +++ b/sdk/rdbms/azure-mgmt-rdbms/MANIFEST.in @@ -1,3 +1,4 @@ +include _meta.json recursive-include tests *.py *.yaml include *.md include azure/__init__.py diff --git a/sdk/rdbms/azure-mgmt-rdbms/_meta.json b/sdk/rdbms/azure-mgmt-rdbms/_meta.json new file mode 100644 index 0000000000000..5b92d27198b81 --- /dev/null +++ b/sdk/rdbms/azure-mgmt-rdbms/_meta.json @@ -0,0 +1,8 @@ +{ + "autorest": "V2", + "use": "@microsoft.azure/autorest.python@~4.0.71", + "commit": "fa3ad6f18ed5978be496909d6dccc2ce206d1143", + "repository_url": "https://github.com/Azure/azure-rest-api-specs", + "autorest_command": "autorest specification/mysql/resource-manager/readme.md --keep-version-file --multiapi --no-async --python --python-mode=update --python-sdks-folder=/home/vsts/work/1/s/azure-sdk-for-python/sdk --use=@microsoft.azure/autorest.python@~4.0.71 --version=V2", + "readme": "specification/mysql/resource-manager/readme.md" +} \ No newline at end of file diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/_my_sql_management_client.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/_my_sql_management_client.py index 5a1ec3d6105ba..12fbda6b7927c 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/_my_sql_management_client.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/_my_sql_management_client.py @@ -20,8 +20,11 @@ from .operations import VirtualNetworkRulesOperations from .operations import DatabasesOperations from .operations import ConfigurationsOperations +from .operations import ServerParametersOperations from .operations import LogFilesOperations from .operations import ServerAdministratorsOperations +from .operations import RecoverableServersOperations +from .operations import ServerBasedPerformanceTierOperations from .operations import LocationBasedPerformanceTierOperations from .operations import CheckNameAvailabilityOperations from .operations import Operations @@ -57,10 +60,16 @@ class MySQLManagementClient(MySQLManagementClientOperationsMixin, SDKClient): :vartype databases: azure.mgmt.rdbms.mysql.operations.DatabasesOperations :ivar configurations: Configurations operations :vartype configurations: azure.mgmt.rdbms.mysql.operations.ConfigurationsOperations + :ivar server_parameters: ServerParameters operations + :vartype server_parameters: azure.mgmt.rdbms.mysql.operations.ServerParametersOperations :ivar log_files: LogFiles operations :vartype log_files: azure.mgmt.rdbms.mysql.operations.LogFilesOperations :ivar server_administrators: ServerAdministrators operations :vartype server_administrators: azure.mgmt.rdbms.mysql.operations.ServerAdministratorsOperations + :ivar recoverable_servers: RecoverableServers operations + :vartype recoverable_servers: azure.mgmt.rdbms.mysql.operations.RecoverableServersOperations + :ivar server_based_performance_tier: ServerBasedPerformanceTier operations + :vartype server_based_performance_tier: azure.mgmt.rdbms.mysql.operations.ServerBasedPerformanceTierOperations :ivar location_based_performance_tier: LocationBasedPerformanceTier operations :vartype location_based_performance_tier: azure.mgmt.rdbms.mysql.operations.LocationBasedPerformanceTierOperations :ivar check_name_availability: CheckNameAvailability operations @@ -120,10 +129,16 @@ def __init__( self._client, self.config, self._serialize, self._deserialize) self.configurations = ConfigurationsOperations( self._client, self.config, self._serialize, self._deserialize) + self.server_parameters = ServerParametersOperations( + self._client, self.config, self._serialize, self._deserialize) self.log_files = LogFilesOperations( self._client, self.config, self._serialize, self._deserialize) self.server_administrators = ServerAdministratorsOperations( self._client, self.config, self._serialize, self._deserialize) + self.recoverable_servers = RecoverableServersOperations( + self._client, self.config, self._serialize, self._deserialize) + self.server_based_performance_tier = ServerBasedPerformanceTierOperations( + self._client, self.config, self._serialize, self._deserialize) self.location_based_performance_tier = LocationBasedPerformanceTierOperations( self._client, self.config, self._serialize, self._deserialize) self.check_name_availability = CheckNameAvailabilityOperations( diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/__init__.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/__init__.py index 03a54f14bfbd0..9fca39faac298 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/__init__.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/__init__.py @@ -13,6 +13,7 @@ from ._models_py3 import Advisor from ._models_py3 import AzureEntityResource from ._models_py3 import Configuration + from ._models_py3 import ConfigurationListResult from ._models_py3 import Database from ._models_py3 import ErrorAdditionalInfo from ._models_py3 import ErrorResponse @@ -31,11 +32,13 @@ from ._models_py3 import PrivateLinkResourceProperties from ._models_py3 import PrivateLinkServiceConnectionStateProperty from ._models_py3 import ProxyResource + from ._models_py3 import QueryPerformanceInsightResetDataResult from ._models_py3 import QueryStatistic from ._models_py3 import QueryText from ._models_py3 import RecommendationAction from ._models_py3 import RecommendationActionsResultList from ._models_py3 import RecommendedActionSessionsOperationStatus + from ._models_py3 import RecoverableServerResource from ._models_py3 import Resource from ._models_py3 import ResourceIdentity from ._models_py3 import Server @@ -65,6 +68,7 @@ from ._models import Advisor from ._models import AzureEntityResource from ._models import Configuration + from ._models import ConfigurationListResult from ._models import Database from ._models import ErrorAdditionalInfo from ._models import ErrorResponse @@ -83,11 +87,13 @@ from ._models import PrivateLinkResourceProperties from ._models import PrivateLinkServiceConnectionStateProperty from ._models import ProxyResource + from ._models import QueryPerformanceInsightResetDataResult from ._models import QueryStatistic from ._models import QueryText from ._models import RecommendationAction from ._models import RecommendationActionsResultList from ._models import RecommendedActionSessionsOperationStatus + from ._models import RecoverableServerResource from ._models import Resource from ._models import ResourceIdentity from ._models import Server @@ -127,6 +133,7 @@ from ._paged_models import ServerAdministratorResourcePaged from ._paged_models import ServerKeyPaged from ._paged_models import ServerPaged +from ._paged_models import ServerSecurityAlertPolicyPaged from ._paged_models import VirtualNetworkRulePaged from ._paged_models import WaitStatisticPaged from ._my_sql_management_client_enums import ( @@ -146,12 +153,14 @@ VirtualNetworkRuleState, OperationOrigin, ServerSecurityAlertPolicyState, + QueryPerformanceInsightResetDataResultState, ) __all__ = [ 'Advisor', 'AzureEntityResource', 'Configuration', + 'ConfigurationListResult', 'Database', 'ErrorAdditionalInfo', 'ErrorResponse', @@ -170,11 +179,13 @@ 'PrivateLinkResourceProperties', 'PrivateLinkServiceConnectionStateProperty', 'ProxyResource', + 'QueryPerformanceInsightResetDataResult', 'QueryStatistic', 'QueryText', 'RecommendationAction', 'RecommendationActionsResultList', 'RecommendedActionSessionsOperationStatus', + 'RecoverableServerResource', 'Resource', 'ResourceIdentity', 'Server', @@ -208,6 +219,7 @@ 'LogFilePaged', 'ServerAdministratorResourcePaged', 'PerformanceTierPropertiesPaged', + 'ServerSecurityAlertPolicyPaged', 'QueryTextPaged', 'QueryStatisticPaged', 'WaitStatisticPaged', @@ -232,4 +244,5 @@ 'VirtualNetworkRuleState', 'OperationOrigin', 'ServerSecurityAlertPolicyState', + 'QueryPerformanceInsightResetDataResultState', ] diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_models.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_models.py index d4ef96c2da751..7ea35b78c9f83 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_models.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_models.py @@ -16,16 +16,19 @@ class Resource(Model): """Resource. + Common fields that are returned in the response for all Azure Resource + Manager resources. + Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str """ @@ -49,19 +52,21 @@ def __init__(self, **kwargs): class ProxyResource(Resource): - """The resource model definition for a ARM proxy resource. It will have - everything other than required location and tags. + """Proxy Resource. + + The resource model definition for a Azure Resource Manager proxy resource. + It will not have tags and a location. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str """ @@ -87,13 +92,13 @@ class Advisor(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param properties: The properties of a recommendation action advisor. :type properties: object @@ -118,19 +123,21 @@ def __init__(self, **kwargs): class AzureEntityResource(Resource): - """The resource model definition for a Azure Resource Manager resource with an - etag. + """Entity Resource. + + The resource model definition for an Azure Resource Manager resource with + an etag. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :ivar etag: Resource Etag. :vartype etag: str @@ -189,13 +196,13 @@ class Configuration(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param value: Value of the configuration. :type value: str @@ -243,19 +250,35 @@ def __init__(self, **kwargs): self.source = kwargs.get('source', None) +class ConfigurationListResult(Model): + """A list of server configurations. + + :param value: The list of server configurations. + :type value: list[~azure.mgmt.rdbms.mysql.models.Configuration] + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': '[Configuration]'}, + } + + def __init__(self, **kwargs): + super(ConfigurationListResult, self).__init__(**kwargs) + self.value = kwargs.get('value', None) + + class Database(ProxyResource): """Represents a Database. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param charset: The charset of the database. :type charset: str @@ -312,7 +335,11 @@ def __init__(self, **kwargs): class ErrorResponse(Model): - """The resource management error response. + """Error Response. + + Common error response for all Azure Resource Manager APIs to return error + details for failed operations. (This also follows the OData error response + format.). Variables are only populated by the server, and will be ignored when sending a request. @@ -363,13 +390,13 @@ class FirewallRule(ProxyResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param start_ip_address: Required. The start IP address of the server firewall rule. Must be IPv4 format. @@ -407,13 +434,13 @@ class LogFile(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param size_in_kb: Size of the log file. :type size_in_kb: long @@ -605,6 +632,20 @@ class PerformanceTierProperties(Model): :param id: ID of the performance tier. :type id: str + :param max_backup_retention_days: Maximum Backup retention in days for the + performance tier edition + :type max_backup_retention_days: int + :param min_backup_retention_days: Minimum Backup retention in days for the + performance tier edition + :type min_backup_retention_days: int + :param max_storage_mb: Max storage allowed for a server. + :type max_storage_mb: int + :param min_large_storage_mb: Max storage allowed for a server. + :type min_large_storage_mb: int + :param max_large_storage_mb: Max storage allowed for a server. + :type max_large_storage_mb: int + :param min_storage_mb: Max storage allowed for a server. + :type min_storage_mb: int :param service_level_objectives: Service level objectives associated with the performance tier :type service_level_objectives: @@ -613,12 +654,24 @@ class PerformanceTierProperties(Model): _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, + 'max_backup_retention_days': {'key': 'maxBackupRetentionDays', 'type': 'int'}, + 'min_backup_retention_days': {'key': 'minBackupRetentionDays', 'type': 'int'}, + 'max_storage_mb': {'key': 'maxStorageMB', 'type': 'int'}, + 'min_large_storage_mb': {'key': 'minLargeStorageMB', 'type': 'int'}, + 'max_large_storage_mb': {'key': 'maxLargeStorageMB', 'type': 'int'}, + 'min_storage_mb': {'key': 'minStorageMB', 'type': 'int'}, 'service_level_objectives': {'key': 'serviceLevelObjectives', 'type': '[PerformanceTierServiceLevelObjectives]'}, } def __init__(self, **kwargs): super(PerformanceTierProperties, self).__init__(**kwargs) self.id = kwargs.get('id', None) + self.max_backup_retention_days = kwargs.get('max_backup_retention_days', None) + self.min_backup_retention_days = kwargs.get('min_backup_retention_days', None) + self.max_storage_mb = kwargs.get('max_storage_mb', None) + self.min_large_storage_mb = kwargs.get('min_large_storage_mb', None) + self.max_large_storage_mb = kwargs.get('max_large_storage_mb', None) + self.min_storage_mb = kwargs.get('min_storage_mb', None) self.service_level_objectives = kwargs.get('service_level_objectives', None) @@ -675,13 +728,13 @@ class PrivateEndpointConnection(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param private_endpoint: Private endpoint which the connection belongs to. :type private_endpoint: @@ -739,13 +792,13 @@ class PrivateLinkResource(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :ivar properties: The private link resource group id. :vartype properties: @@ -836,19 +889,41 @@ def __init__(self, **kwargs): self.actions_required = None +class QueryPerformanceInsightResetDataResult(Model): + """Result of Query Performance Insight data reset. + + :param status: Indicates result of the operation. Possible values include: + 'Succeeded', 'Failed' + :type status: str or + ~azure.mgmt.rdbms.mysql.models.QueryPerformanceInsightResetDataResultState + :param message: operation message. + :type message: str + """ + + _attribute_map = { + 'status': {'key': 'status', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(QueryPerformanceInsightResetDataResult, self).__init__(**kwargs) + self.status = kwargs.get('status', None) + self.message = kwargs.get('message', None) + + class QueryStatistic(ProxyResource): """Represents a Query Statistic. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param query_id: Database query identifier. :type query_id: str @@ -915,13 +990,13 @@ class QueryText(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param query_id: Query identifier unique to the server. :type query_id: str @@ -955,13 +1030,13 @@ class RecommendationAction(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param advisor_name: Advisor name. :type advisor_name: str @@ -1065,6 +1140,70 @@ def __init__(self, **kwargs): self.status = kwargs.get('status', None) +class RecoverableServerResource(ProxyResource): + """A recoverable server resource. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Fully qualified resource ID for the resource. Ex - + /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} + :vartype id: str + :ivar name: The name of the resource + :vartype name: str + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" + :vartype type: str + :ivar last_available_backup_date_time: The last available backup date + time. + :vartype last_available_backup_date_time: str + :ivar service_level_objective: The service level objective + :vartype service_level_objective: str + :ivar edition: Edition of the performance tier. + :vartype edition: str + :ivar v_core: vCore associated with the service level objective + :vartype v_core: int + :ivar hardware_generation: Hardware generation associated with the service + level objective + :vartype hardware_generation: str + :ivar version: The MySQL version + :vartype version: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'last_available_backup_date_time': {'readonly': True}, + 'service_level_objective': {'readonly': True}, + 'edition': {'readonly': True}, + 'v_core': {'readonly': True}, + 'hardware_generation': {'readonly': True}, + 'version': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'last_available_backup_date_time': {'key': 'properties.lastAvailableBackupDateTime', 'type': 'str'}, + 'service_level_objective': {'key': 'properties.serviceLevelObjective', 'type': 'str'}, + 'edition': {'key': 'properties.edition', 'type': 'str'}, + 'v_core': {'key': 'properties.vCore', 'type': 'int'}, + 'hardware_generation': {'key': 'properties.hardwareGeneration', 'type': 'str'}, + 'version': {'key': 'properties.version', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(RecoverableServerResource, self).__init__(**kwargs) + self.last_available_backup_date_time = None + self.service_level_objective = None + self.edition = None + self.v_core = None + self.hardware_generation = None + self.version = None + + class ResourceIdentity(Model): """Azure Active Directory identity configuration for a resource. @@ -1100,20 +1239,23 @@ def __init__(self, **kwargs): class TrackedResource(Resource): - """The resource model definition for a ARM tracked top level resource. + """Tracked Resource. + + The resource model definition for an Azure Resource Manager tracked top + level resource which has 'tags' and a 'location'. 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 id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param tags: Resource tags. :type tags: dict[str, str] @@ -1150,13 +1292,13 @@ class Server(TrackedResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param tags: Resource tags. :type tags: dict[str, str] @@ -1284,13 +1426,13 @@ class ServerAdministratorResource(ProxyResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :ivar administrator_type: Required. The type of administrator. Default value: "ActiveDirectory" . @@ -1380,13 +1522,13 @@ class ServerKey(ProxyResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :ivar kind: Kind of encryption protector used to protect the key. :vartype kind: str @@ -1852,13 +1994,13 @@ class ServerSecurityAlertPolicy(ProxyResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param state: Required. Specifies the state of the policy, whether it is enabled or disabled. Possible values include: 'Enabled', 'Disabled' @@ -2142,13 +2284,13 @@ class VirtualNetworkRule(ProxyResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param virtual_network_subnet_id: Required. The ARM resource id of the virtual network subnet. @@ -2192,13 +2334,13 @@ class WaitStatistic(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param start_time: Observation start time. :type start_time: datetime diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_models_py3.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_models_py3.py index 681dcefd279bf..79e0f2341650a 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_models_py3.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_models_py3.py @@ -16,16 +16,19 @@ class Resource(Model): """Resource. + Common fields that are returned in the response for all Azure Resource + Manager resources. + Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str """ @@ -49,19 +52,21 @@ def __init__(self, **kwargs) -> None: class ProxyResource(Resource): - """The resource model definition for a ARM proxy resource. It will have - everything other than required location and tags. + """Proxy Resource. + + The resource model definition for a Azure Resource Manager proxy resource. + It will not have tags and a location. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str """ @@ -87,13 +92,13 @@ class Advisor(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param properties: The properties of a recommendation action advisor. :type properties: object @@ -118,19 +123,21 @@ def __init__(self, *, properties=None, **kwargs) -> None: class AzureEntityResource(Resource): - """The resource model definition for a Azure Resource Manager resource with an - etag. + """Entity Resource. + + The resource model definition for an Azure Resource Manager resource with + an etag. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :ivar etag: Resource Etag. :vartype etag: str @@ -189,13 +196,13 @@ class Configuration(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param value: Value of the configuration. :type value: str @@ -243,19 +250,35 @@ def __init__(self, *, value: str=None, source: str=None, **kwargs) -> None: self.source = source +class ConfigurationListResult(Model): + """A list of server configurations. + + :param value: The list of server configurations. + :type value: list[~azure.mgmt.rdbms.mysql.models.Configuration] + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': '[Configuration]'}, + } + + def __init__(self, *, value=None, **kwargs) -> None: + super(ConfigurationListResult, self).__init__(**kwargs) + self.value = value + + class Database(ProxyResource): """Represents a Database. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param charset: The charset of the database. :type charset: str @@ -312,7 +335,11 @@ def __init__(self, **kwargs) -> None: class ErrorResponse(Model): - """The resource management error response. + """Error Response. + + Common error response for all Azure Resource Manager APIs to return error + details for failed operations. (This also follows the OData error response + format.). Variables are only populated by the server, and will be ignored when sending a request. @@ -363,13 +390,13 @@ class FirewallRule(ProxyResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param start_ip_address: Required. The start IP address of the server firewall rule. Must be IPv4 format. @@ -407,13 +434,13 @@ class LogFile(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param size_in_kb: Size of the log file. :type size_in_kb: long @@ -605,6 +632,20 @@ class PerformanceTierProperties(Model): :param id: ID of the performance tier. :type id: str + :param max_backup_retention_days: Maximum Backup retention in days for the + performance tier edition + :type max_backup_retention_days: int + :param min_backup_retention_days: Minimum Backup retention in days for the + performance tier edition + :type min_backup_retention_days: int + :param max_storage_mb: Max storage allowed for a server. + :type max_storage_mb: int + :param min_large_storage_mb: Max storage allowed for a server. + :type min_large_storage_mb: int + :param max_large_storage_mb: Max storage allowed for a server. + :type max_large_storage_mb: int + :param min_storage_mb: Max storage allowed for a server. + :type min_storage_mb: int :param service_level_objectives: Service level objectives associated with the performance tier :type service_level_objectives: @@ -613,12 +654,24 @@ class PerformanceTierProperties(Model): _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, + 'max_backup_retention_days': {'key': 'maxBackupRetentionDays', 'type': 'int'}, + 'min_backup_retention_days': {'key': 'minBackupRetentionDays', 'type': 'int'}, + 'max_storage_mb': {'key': 'maxStorageMB', 'type': 'int'}, + 'min_large_storage_mb': {'key': 'minLargeStorageMB', 'type': 'int'}, + 'max_large_storage_mb': {'key': 'maxLargeStorageMB', 'type': 'int'}, + 'min_storage_mb': {'key': 'minStorageMB', 'type': 'int'}, 'service_level_objectives': {'key': 'serviceLevelObjectives', 'type': '[PerformanceTierServiceLevelObjectives]'}, } - def __init__(self, *, id: str=None, service_level_objectives=None, **kwargs) -> None: + def __init__(self, *, id: str=None, max_backup_retention_days: int=None, min_backup_retention_days: int=None, max_storage_mb: int=None, min_large_storage_mb: int=None, max_large_storage_mb: int=None, min_storage_mb: int=None, service_level_objectives=None, **kwargs) -> None: super(PerformanceTierProperties, self).__init__(**kwargs) self.id = id + self.max_backup_retention_days = max_backup_retention_days + self.min_backup_retention_days = min_backup_retention_days + self.max_storage_mb = max_storage_mb + self.min_large_storage_mb = min_large_storage_mb + self.max_large_storage_mb = max_large_storage_mb + self.min_storage_mb = min_storage_mb self.service_level_objectives = service_level_objectives @@ -675,13 +728,13 @@ class PrivateEndpointConnection(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param private_endpoint: Private endpoint which the connection belongs to. :type private_endpoint: @@ -739,13 +792,13 @@ class PrivateLinkResource(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :ivar properties: The private link resource group id. :vartype properties: @@ -836,19 +889,41 @@ def __init__(self, *, status: str, description: str, **kwargs) -> None: self.actions_required = None +class QueryPerformanceInsightResetDataResult(Model): + """Result of Query Performance Insight data reset. + + :param status: Indicates result of the operation. Possible values include: + 'Succeeded', 'Failed' + :type status: str or + ~azure.mgmt.rdbms.mysql.models.QueryPerformanceInsightResetDataResultState + :param message: operation message. + :type message: str + """ + + _attribute_map = { + 'status': {'key': 'status', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + } + + def __init__(self, *, status=None, message: str=None, **kwargs) -> None: + super(QueryPerformanceInsightResetDataResult, self).__init__(**kwargs) + self.status = status + self.message = message + + class QueryStatistic(ProxyResource): """Represents a Query Statistic. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param query_id: Database query identifier. :type query_id: str @@ -915,13 +990,13 @@ class QueryText(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param query_id: Query identifier unique to the server. :type query_id: str @@ -955,13 +1030,13 @@ class RecommendationAction(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param advisor_name: Advisor name. :type advisor_name: str @@ -1065,6 +1140,70 @@ def __init__(self, *, name: str=None, start_time=None, status: str=None, **kwarg self.status = status +class RecoverableServerResource(ProxyResource): + """A recoverable server resource. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Fully qualified resource ID for the resource. Ex - + /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} + :vartype id: str + :ivar name: The name of the resource + :vartype name: str + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" + :vartype type: str + :ivar last_available_backup_date_time: The last available backup date + time. + :vartype last_available_backup_date_time: str + :ivar service_level_objective: The service level objective + :vartype service_level_objective: str + :ivar edition: Edition of the performance tier. + :vartype edition: str + :ivar v_core: vCore associated with the service level objective + :vartype v_core: int + :ivar hardware_generation: Hardware generation associated with the service + level objective + :vartype hardware_generation: str + :ivar version: The MySQL version + :vartype version: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'last_available_backup_date_time': {'readonly': True}, + 'service_level_objective': {'readonly': True}, + 'edition': {'readonly': True}, + 'v_core': {'readonly': True}, + 'hardware_generation': {'readonly': True}, + 'version': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'last_available_backup_date_time': {'key': 'properties.lastAvailableBackupDateTime', 'type': 'str'}, + 'service_level_objective': {'key': 'properties.serviceLevelObjective', 'type': 'str'}, + 'edition': {'key': 'properties.edition', 'type': 'str'}, + 'v_core': {'key': 'properties.vCore', 'type': 'int'}, + 'hardware_generation': {'key': 'properties.hardwareGeneration', 'type': 'str'}, + 'version': {'key': 'properties.version', 'type': 'str'}, + } + + def __init__(self, **kwargs) -> None: + super(RecoverableServerResource, self).__init__(**kwargs) + self.last_available_backup_date_time = None + self.service_level_objective = None + self.edition = None + self.v_core = None + self.hardware_generation = None + self.version = None + + class ResourceIdentity(Model): """Azure Active Directory identity configuration for a resource. @@ -1100,20 +1239,23 @@ def __init__(self, *, type=None, **kwargs) -> None: class TrackedResource(Resource): - """The resource model definition for a ARM tracked top level resource. + """Tracked Resource. + + The resource model definition for an Azure Resource Manager tracked top + level resource which has 'tags' and a 'location'. 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 id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param tags: Resource tags. :type tags: dict[str, str] @@ -1150,13 +1292,13 @@ class Server(TrackedResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param tags: Resource tags. :type tags: dict[str, str] @@ -1284,13 +1426,13 @@ class ServerAdministratorResource(ProxyResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :ivar administrator_type: Required. The type of administrator. Default value: "ActiveDirectory" . @@ -1380,13 +1522,13 @@ class ServerKey(ProxyResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :ivar kind: Kind of encryption protector used to protect the key. :vartype kind: str @@ -1852,13 +1994,13 @@ class ServerSecurityAlertPolicy(ProxyResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param state: Required. Specifies the state of the policy, whether it is enabled or disabled. Possible values include: 'Enabled', 'Disabled' @@ -2142,13 +2284,13 @@ class VirtualNetworkRule(ProxyResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param virtual_network_subnet_id: Required. The ARM resource id of the virtual network subnet. @@ -2192,13 +2334,13 @@ class WaitStatistic(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param start_time: Observation start time. :type start_time: datetime diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_my_sql_management_client_enums.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_my_sql_management_client_enums.py index 926d8bd464235..e7429ba08fab9 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_my_sql_management_client_enums.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_my_sql_management_client_enums.py @@ -119,3 +119,9 @@ class ServerSecurityAlertPolicyState(str, Enum): enabled = "Enabled" disabled = "Disabled" + + +class QueryPerformanceInsightResetDataResultState(str, Enum): + + succeeded = "Succeeded" + failed = "Failed" diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_paged_models.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_paged_models.py index 6b4fde833ccd6..9c9b5853b0837 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_paged_models.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/models/_paged_models.py @@ -116,6 +116,19 @@ class PerformanceTierPropertiesPaged(Paged): def __init__(self, *args, **kwargs): super(PerformanceTierPropertiesPaged, self).__init__(*args, **kwargs) +class ServerSecurityAlertPolicyPaged(Paged): + """ + A paging container for iterating over a list of :class:`ServerSecurityAlertPolicy ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[ServerSecurityAlertPolicy]'} + } + + def __init__(self, *args, **kwargs): + + super(ServerSecurityAlertPolicyPaged, self).__init__(*args, **kwargs) class QueryTextPaged(Paged): """ A paging container for iterating over a list of :class:`QueryText ` object diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/__init__.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/__init__.py index 10badf36caa81..9eeaca2f29d3a 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/__init__.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/__init__.py @@ -15,8 +15,11 @@ from ._virtual_network_rules_operations import VirtualNetworkRulesOperations from ._databases_operations import DatabasesOperations from ._configurations_operations import ConfigurationsOperations +from ._server_parameters_operations import ServerParametersOperations from ._log_files_operations import LogFilesOperations from ._server_administrators_operations import ServerAdministratorsOperations +from ._recoverable_servers_operations import RecoverableServersOperations +from ._server_based_performance_tier_operations import ServerBasedPerformanceTierOperations from ._location_based_performance_tier_operations import LocationBasedPerformanceTierOperations from ._check_name_availability_operations import CheckNameAvailabilityOperations from ._operations import Operations @@ -40,8 +43,11 @@ 'VirtualNetworkRulesOperations', 'DatabasesOperations', 'ConfigurationsOperations', + 'ServerParametersOperations', 'LogFilesOperations', 'ServerAdministratorsOperations', + 'RecoverableServersOperations', + 'ServerBasedPerformanceTierOperations', 'LocationBasedPerformanceTierOperations', 'CheckNameAvailabilityOperations', 'Operations', diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_advisors_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_advisors_operations.py index b20c39649dd44..c5b36762a8d8f 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_advisors_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_advisors_operations.py @@ -64,7 +64,7 @@ def get( url = self.get.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'advisorName': self._serialize.url("advisor_name", advisor_name, 'str') } @@ -129,7 +129,7 @@ def prepare_request(next_link=None): url = self.list_by_server.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_configurations_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_configurations_operations.py index 88749b621303b..4ea2c1bf2f268 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_configurations_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_configurations_operations.py @@ -50,7 +50,7 @@ def _create_or_update_initial( url = self.create_or_update.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'configurationName': self._serialize.url("configuration_name", configuration_name, 'str') } @@ -176,7 +176,7 @@ def get( url = self.get.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'configurationName': self._serialize.url("configuration_name", configuration_name, 'str') } @@ -241,7 +241,7 @@ def prepare_request(next_link=None): url = self.list_by_server.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_databases_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_databases_operations.py index 58c241fccc26c..03cd5bc6b7c21 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_databases_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_databases_operations.py @@ -50,7 +50,7 @@ def _create_or_update_initial( url = self.create_or_update.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'databaseName': self._serialize.url("database_name", database_name, 'str') } @@ -160,7 +160,7 @@ def _delete_initial( url = self.delete.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'databaseName': self._serialize.url("database_name", database_name, 'str') } @@ -262,7 +262,7 @@ def get( url = self.get.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'databaseName': self._serialize.url("database_name", database_name, 'str') } @@ -327,7 +327,7 @@ def prepare_request(next_link=None): url = self.list_by_server.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_firewall_rules_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_firewall_rules_operations.py index eef0dc56adba5..7e7f9244f5311 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_firewall_rules_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_firewall_rules_operations.py @@ -50,7 +50,7 @@ def _create_or_update_initial( url = self.create_or_update.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'firewallRuleName': self._serialize.url("firewall_rule_name", firewall_rule_name, 'str') } @@ -162,7 +162,7 @@ def _delete_initial( url = self.delete.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'firewallRuleName': self._serialize.url("firewall_rule_name", firewall_rule_name, 'str') } @@ -264,7 +264,7 @@ def get( url = self.get.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'firewallRuleName': self._serialize.url("firewall_rule_name", firewall_rule_name, 'str') } @@ -329,7 +329,7 @@ def prepare_request(next_link=None): url = self.list_by_server.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_log_files_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_log_files_operations.py index f9ed6eaa6100e..fe9cd8d4fc526 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_log_files_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_log_files_operations.py @@ -64,7 +64,7 @@ def prepare_request(next_link=None): url = self.list_by_server.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_my_sql_management_client_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_my_sql_management_client_operations.py index 100feafeb6c88..3410b793b2af1 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_my_sql_management_client_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_my_sql_management_client_operations.py @@ -19,6 +19,72 @@ class MySQLManagementClientOperationsMixin(object): + def reset_query_performance_insight_data( + self, resource_group_name, server_name, custom_headers=None, raw=False, **operation_config): + """Reset data for Query Performance Insight. + + :param resource_group_name: The name of the resource group. The name + is case insensitive. + :type resource_group_name: str + :param server_name: The name of the server. + :type server_name: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: QueryPerformanceInsightResetDataResult or ClientRawResponse + if raw=true + :rtype: + ~azure.mgmt.rdbms.mysql.models.QueryPerformanceInsightResetDataResult + or ~msrest.pipeline.ClientRawResponse + :raises: :class:`CloudError` + """ + api_version = "2018-06-01" + + # Construct URL + url = self.reset_query_performance_insight_data.metadata['url'] + path_format_arguments = { + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), + 'serverName': self._serialize.url("server_name", server_name, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("api_version", api_version, 'str', min_length=1) + + # 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') + + # Construct and send request + 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) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = None + if response.status_code == 200: + deserialized = self._deserialize('QueryPerformanceInsightResetDataResult', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + reset_query_performance_insight_data.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforMySQL/servers/{serverName}/resetQueryPerformanceInsightData'} + def _create_recommended_action_session_initial( self, resource_group_name, server_name, advisor_name, database_name, custom_headers=None, raw=False, **operation_config): @@ -28,7 +94,7 @@ def _create_recommended_action_session_initial( url = self.create_recommended_action_session.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'advisorName': self._serialize.url("advisor_name", advisor_name, 'str') } diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_private_endpoint_connections_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_private_endpoint_connections_operations.py index b91f8c8a4e3f5..6358f84375960 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_private_endpoint_connections_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_private_endpoint_connections_operations.py @@ -66,7 +66,7 @@ def get( # Construct URL url = self.get.metadata['url'] path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'privateEndpointConnectionName': self._serialize.url("private_endpoint_connection_name", private_endpoint_connection_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1) @@ -115,7 +115,7 @@ def _create_or_update_initial( # Construct URL url = self.create_or_update.metadata['url'] path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'privateEndpointConnectionName': self._serialize.url("private_endpoint_connection_name", private_endpoint_connection_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1) @@ -228,7 +228,7 @@ def _delete_initial( # Construct URL url = self.delete.metadata['url'] path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'privateEndpointConnectionName': self._serialize.url("private_endpoint_connection_name", private_endpoint_connection_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1) @@ -315,7 +315,7 @@ def _update_tags_initial( url = self.update_tags.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'privateEndpointConnectionName': self._serialize.url("private_endpoint_connection_name", private_endpoint_connection_name, 'str') } @@ -440,7 +440,7 @@ def prepare_request(next_link=None): # Construct URL url = self.list_by_server.metadata['url'] path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1) } diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_private_link_resources_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_private_link_resources_operations.py index 97fc4de5bde24..f1ebdbe9af02a 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_private_link_resources_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_private_link_resources_operations.py @@ -63,7 +63,7 @@ def prepare_request(next_link=None): # Construct URL url = self.list_by_server.metadata['url'] path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1) } @@ -136,7 +136,7 @@ def get( # Construct URL url = self.get.metadata['url'] path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'groupName': self._serialize.url("group_name", group_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_query_texts_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_query_texts_operations.py index 6e944718dcc21..63812e8352a7a 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_query_texts_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_query_texts_operations.py @@ -64,7 +64,7 @@ def get( url = self.get.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'queryId': self._serialize.url("query_id", query_id, 'str') } @@ -131,7 +131,7 @@ def prepare_request(next_link=None): url = self.list_by_server.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_recommended_actions_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_recommended_actions_operations.py index d547efd721510..e2d588042f16e 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_recommended_actions_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_recommended_actions_operations.py @@ -66,7 +66,7 @@ def get( url = self.get.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'advisorName': self._serialize.url("advisor_name", advisor_name, 'str'), 'recommendedActionName': self._serialize.url("recommended_action_name", recommended_action_name, 'str') @@ -136,7 +136,7 @@ def prepare_request(next_link=None): url = self.list_by_server.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'advisorName': self._serialize.url("advisor_name", advisor_name, 'str') } diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_recoverable_servers_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_recoverable_servers_operations.py new file mode 100644 index 0000000000000..9a745c9cbe20f --- /dev/null +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_recoverable_servers_operations.py @@ -0,0 +1,102 @@ +# 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. +# -------------------------------------------------------------------------- + +import uuid +from msrest.pipeline import ClientRawResponse +from msrestazure.azure_exceptions import CloudError + +from .. import models + + +class RecoverableServersOperations(object): + """RecoverableServersOperations operations. + + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An object model deserializer. + :ivar api_version: The API version to use for this operation. Constant value: "2017-12-01". + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + self.api_version = "2017-12-01" + + self.config = config + + def get( + self, resource_group_name, server_name, custom_headers=None, raw=False, **operation_config): + """Gets a recoverable MySQL Server. + + :param resource_group_name: The name of the resource group. The name + is case insensitive. + :type resource_group_name: str + :param server_name: The name of the server. + :type server_name: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: RecoverableServerResource or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.rdbms.mysql.models.RecoverableServerResource or + ~msrest.pipeline.ClientRawResponse + :raises: :class:`CloudError` + """ + # Construct URL + url = self.get.metadata['url'] + path_format_arguments = { + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), + 'serverName': self._serialize.url("server_name", server_name, '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', min_length=1) + + # 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') + + # 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 + + deserialized = None + if response.status_code == 200: + deserialized = self._deserialize('RecoverableServerResource', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + get.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBForMySQL/servers/{serverName}/recoverableServers'} diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_replicas_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_replicas_operations.py index cf32b2124e32f..8b07c7709df44 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_replicas_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_replicas_operations.py @@ -64,7 +64,7 @@ def prepare_request(next_link=None): url = self.list_by_server.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_administrators_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_administrators_operations.py index 2289403946ba4..c8548e03c8b25 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_administrators_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_administrators_operations.py @@ -64,7 +64,7 @@ def get( url = self.get.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -101,7 +101,7 @@ def get( return client_raw_response return deserialized - get.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBForMySQL/servers/{serverName}/Administrators/activeDirectory'} + get.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBForMySQL/servers/{serverName}/administrators/activeDirectory'} def _create_or_update_initial( @@ -110,7 +110,7 @@ def _create_or_update_initial( url = self.create_or_update.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -208,7 +208,7 @@ def get_long_running_output(response): elif polling is False: polling_method = NoPolling() else: polling_method = polling return LROPoller(self._client, raw_result, get_long_running_output, polling_method) - create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBForMySQL/servers/{serverName}/Administrators/activeDirectory'} + create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBForMySQL/servers/{serverName}/administrators/activeDirectory'} def _delete_initial( @@ -217,7 +217,7 @@ def _delete_initial( url = self.delete.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -288,7 +288,7 @@ def get_long_running_output(response): elif polling is False: polling_method = NoPolling() else: polling_method = polling return LROPoller(self._client, raw_result, get_long_running_output, polling_method) - delete.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBForMySQL/servers/{serverName}/Administrators/activeDirectory'} + delete.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBForMySQL/servers/{serverName}/administrators/activeDirectory'} def list( self, resource_group_name, server_name, custom_headers=None, raw=False, **operation_config): @@ -315,7 +315,7 @@ def prepare_request(next_link=None): url = self.list.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_based_performance_tier_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_based_performance_tier_operations.py new file mode 100644 index 0000000000000..450685ba673db --- /dev/null +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_based_performance_tier_operations.py @@ -0,0 +1,113 @@ +# 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. +# -------------------------------------------------------------------------- + +import uuid +from msrest.pipeline import ClientRawResponse +from msrestazure.azure_exceptions import CloudError + +from .. import models + + +class ServerBasedPerformanceTierOperations(object): + """ServerBasedPerformanceTierOperations operations. + + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An object model deserializer. + :ivar api_version: The API version to use for this operation. Constant value: "2017-12-01". + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + self.api_version = "2017-12-01" + + self.config = config + + def list( + self, resource_group_name, server_name, custom_headers=None, raw=False, **operation_config): + """List all the performance tiers for a MySQL server. + + :param resource_group_name: The name of the resource group. The name + is case insensitive. + :type resource_group_name: str + :param server_name: The name of the server. + :type server_name: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: An iterator like instance of PerformanceTierProperties + :rtype: + ~azure.mgmt.rdbms.mysql.models.PerformanceTierPropertiesPaged[~azure.mgmt.rdbms.mysql.models.PerformanceTierProperties] + :raises: :class:`CloudError` + """ + def prepare_request(next_link=None): + if not next_link: + # Construct URL + url = self.list.metadata['url'] + path_format_arguments = { + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), + 'serverName': self._serialize.url("server_name", server_name, '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', min_length=1) + + 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') + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + + 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 + header_dict = None + if raw: + header_dict = {} + deserialized = models.PerformanceTierPropertiesPaged(internal_paging, self._deserialize.dependencies, header_dict) + + return deserialized + list.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBForMySQL/servers/{serverName}/performanceTiers'} diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_keys_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_keys_operations.py index 7e4c360fa60f1..6cd69037a424f 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_keys_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_keys_operations.py @@ -66,7 +66,7 @@ def prepare_request(next_link=None): url = self.list.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -138,7 +138,7 @@ def get( # Construct URL url = self.get.metadata['url'] path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'keyName': self._serialize.url("key_name", key_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1) @@ -190,7 +190,7 @@ def _create_or_update_initial( 'serverName': self._serialize.url("server_name", server_name, 'str'), 'keyName': self._serialize.url("key_name", key_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$') + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1) } url = self._client.format_url(url, **path_format_arguments) @@ -298,7 +298,7 @@ def _delete_initial( 'serverName': self._serialize.url("server_name", server_name, 'str'), 'keyName': self._serialize.url("key_name", key_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$') + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1) } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_parameters_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_parameters_operations.py new file mode 100644 index 0000000000000..164559cb0a3ce --- /dev/null +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_parameters_operations.py @@ -0,0 +1,145 @@ +# 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. +# -------------------------------------------------------------------------- + +import uuid +from msrest.pipeline import ClientRawResponse +from msrestazure.azure_exceptions import CloudError +from msrest.polling import LROPoller, NoPolling +from msrestazure.polling.arm_polling import ARMPolling + +from .. import models + + +class ServerParametersOperations(object): + """ServerParametersOperations operations. + + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An object model deserializer. + :ivar api_version: The API version to use for this operation. Constant value: "2017-12-01". + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + self.api_version = "2017-12-01" + + self.config = config + + + def _list_update_configurations_initial( + self, resource_group_name, server_name, value=None, custom_headers=None, raw=False, **operation_config): + value1 = models.ConfigurationListResult(value=value) + + # Construct URL + url = self.list_update_configurations.metadata['url'] + path_format_arguments = { + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), + 'serverName': self._serialize.url("server_name", server_name, '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', min_length=1) + + # 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()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct body + body_content = self._serialize.body(value1, 'ConfigurationListResult') + + # Construct and send request + request = self._client.post(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200, 202]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('ConfigurationListResult', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + + def list_update_configurations( + self, resource_group_name, server_name, value=None, custom_headers=None, raw=False, polling=True, **operation_config): + """Update a list of configurations in a given server. + + :param resource_group_name: The name of the resource group. The name + is case insensitive. + :type resource_group_name: str + :param server_name: The name of the server. + :type server_name: str + :param value: The list of server configurations. + :type value: list[~azure.mgmt.rdbms.mysql.models.Configuration] + :param dict custom_headers: headers that will be added to the request + :param bool raw: The poller return type is ClientRawResponse, the + direct response alongside the deserialized response + :param polling: True for ARMPolling, False for no polling, or a + polling object for personal polling strategy + :return: An instance of LROPoller that returns ConfigurationListResult + or ClientRawResponse if raw==True + :rtype: + ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.rdbms.mysql.models.ConfigurationListResult] + or + ~msrestazure.azure_operation.AzureOperationPoller[~msrest.pipeline.ClientRawResponse[~azure.mgmt.rdbms.mysql.models.ConfigurationListResult]] + :raises: :class:`CloudError` + """ + raw_result = self._list_update_configurations_initial( + resource_group_name=resource_group_name, + server_name=server_name, + value=value, + custom_headers=custom_headers, + raw=True, + **operation_config + ) + + def get_long_running_output(response): + deserialized = self._deserialize('ConfigurationListResult', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + + lro_delay = operation_config.get( + 'long_running_operation_timeout', + self.config.long_running_operation_timeout) + if polling is True: polling_method = ARMPolling(lro_delay, lro_options={'final-state-via': 'azure-async-operation'}, **operation_config) + elif polling is False: polling_method = NoPolling() + else: polling_method = polling + return LROPoller(self._client, raw_result, get_long_running_output, polling_method) + list_update_configurations.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBForMySQL/servers/{serverName}/updateConfigurations'} diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_security_alert_policies_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_security_alert_policies_operations.py index 0f7cac2787228..33ea25814d591 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_security_alert_policies_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_server_security_alert_policies_operations.py @@ -65,7 +65,7 @@ def get( # Construct URL url = self.get.metadata['url'] path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'securityAlertPolicyName': self._serialize.url("self.security_alert_policy_name", self.security_alert_policy_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1) @@ -112,7 +112,7 @@ def _create_or_update_initial( # Construct URL url = self.create_or_update.metadata['url'] path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'securityAlertPolicyName': self._serialize.url("self.security_alert_policy_name", self.security_alert_policy_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1) @@ -209,3 +209,76 @@ def get_long_running_output(response): else: polling_method = polling return LROPoller(self._client, raw_result, get_long_running_output, polling_method) create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforMySQL/servers/{serverName}/securityAlertPolicies/{securityAlertPolicyName}'} + + def list_by_server( + self, resource_group_name, server_name, custom_headers=None, raw=False, **operation_config): + """Get the server's threat detection policies. + + :param resource_group_name: The name of the resource group. The name + is case insensitive. + :type resource_group_name: str + :param server_name: The name of the server. + :type server_name: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: An iterator like instance of ServerSecurityAlertPolicy + :rtype: + ~azure.mgmt.rdbms.mysql.models.ServerSecurityAlertPolicyPaged[~azure.mgmt.rdbms.mysql.models.ServerSecurityAlertPolicy] + :raises: :class:`CloudError` + """ + def prepare_request(next_link=None): + if not next_link: + # Construct URL + url = self.list_by_server.metadata['url'] + path_format_arguments = { + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), + 'serverName': self._serialize.url("server_name", server_name, 'str'), + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1) + } + 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', min_length=1) + + 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') + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + + 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 + header_dict = None + if raw: + header_dict = {} + deserialized = models.ServerSecurityAlertPolicyPaged(internal_paging, self._deserialize.dependencies, header_dict) + + return deserialized + list_by_server.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforMySQL/servers/{serverName}/securityAlertPolicies'} diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_servers_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_servers_operations.py index 725ffe6c27582..ad21a5ef55146 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_servers_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_servers_operations.py @@ -48,7 +48,7 @@ def _create_initial( url = self.create.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -155,7 +155,7 @@ def _update_initial( url = self.update.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -260,7 +260,7 @@ def _delete_initial( url = self.delete.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -358,7 +358,7 @@ def get( url = self.get.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -422,7 +422,7 @@ def prepare_request(next_link=None): url = self.list_by_resource_group.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$') + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1) } url = self._client.format_url(url, **path_format_arguments) @@ -546,7 +546,7 @@ def _restart_initial( url = self.restart.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -628,7 +628,7 @@ def _start_initial( url = self.start.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -710,7 +710,7 @@ def _stop_initial( url = self.stop.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -794,7 +794,7 @@ def _upgrade_initial( url = self.upgrade.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_top_query_statistics_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_top_query_statistics_operations.py index a7c02767679d2..b6ef1488f97f7 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_top_query_statistics_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_top_query_statistics_operations.py @@ -64,7 +64,7 @@ def get( url = self.get.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'queryStatisticId': self._serialize.url("query_statistic_id", query_statistic_id, 'str') } @@ -134,7 +134,7 @@ def prepare_request(next_link=None): url = self.list_by_server.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_virtual_network_rules_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_virtual_network_rules_operations.py index 3b0f7c80b07e1..e6b000c8336e1 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_virtual_network_rules_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_virtual_network_rules_operations.py @@ -66,7 +66,7 @@ def get( # Construct URL url = self.get.metadata['url'] path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), 'virtualNetworkRuleName': self._serialize.url("virtual_network_rule_name", virtual_network_rule_name, 'str') @@ -115,7 +115,7 @@ def _create_or_update_initial( # Construct URL url = self.create_or_update.metadata['url'] path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), 'virtualNetworkRuleName': self._serialize.url("virtual_network_rule_name", virtual_network_rule_name, 'str') @@ -228,7 +228,7 @@ def _delete_initial( # Construct URL url = self.delete.metadata['url'] path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'virtualNetworkRuleName': self._serialize.url("virtual_network_rule_name", virtual_network_rule_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1) @@ -331,7 +331,7 @@ def prepare_request(next_link=None): # Construct URL url = self.list_by_server.metadata['url'] path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1) } diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_wait_statistics_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_wait_statistics_operations.py index 147057fb84dce..530d3771cfe5c 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_wait_statistics_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql/operations/_wait_statistics_operations.py @@ -64,7 +64,7 @@ def get( url = self.get.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'waitStatisticsId': self._serialize.url("wait_statistics_id", wait_statistics_id, 'str') } @@ -132,7 +132,7 @@ def prepare_request(next_link=None): url = self.list_by_server.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/_my_sql_management_client.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/_my_sql_management_client.py index 97bd05d1a290e..9a2d4925c06fa 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/_my_sql_management_client.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/_my_sql_management_client.py @@ -68,7 +68,7 @@ def __init__( super(MySQLManagementClient, self).__init__(self.config.credentials, self.config) client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)} - self.api_version = '2020-07-01-privatepreview' + self.api_version = '2020-07-01-preview' self._serialize = Serializer(client_models) self._deserialize = Deserializer(client_models) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/models/__init__.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/models/__init__.py index 6522f3476896c..5362c136c55f0 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/models/__init__.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/models/__init__.py @@ -13,6 +13,7 @@ from ._models_py3 import AzureEntityResource from ._models_py3 import CapabilityProperties from ._models_py3 import Configuration + from ._models_py3 import ConfigurationListResult from ._models_py3 import Database from ._models_py3 import DelegatedSubnetArguments from ._models_py3 import DelegatedSubnetUsage @@ -50,6 +51,7 @@ from ._models import AzureEntityResource from ._models import CapabilityProperties from ._models import Configuration + from ._models import ConfigurationListResult from ._models import Database from ._models import DelegatedSubnetArguments from ._models import DelegatedSubnetUsage @@ -111,6 +113,7 @@ 'AzureEntityResource', 'CapabilityProperties', 'Configuration', + 'ConfigurationListResult', 'Database', 'DelegatedSubnetArguments', 'DelegatedSubnetUsage', diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/models/_models.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/models/_models.py index 06165f1209bee..fe32381263ad2 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/models/_models.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/models/_models.py @@ -16,16 +16,19 @@ class Resource(Model): """Resource. + Common fields that are returned in the response for all Azure Resource + Manager resources. + Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str """ @@ -49,19 +52,21 @@ def __init__(self, **kwargs): class AzureEntityResource(Resource): - """The resource model definition for a Azure Resource Manager resource with an - etag. + """Entity Resource. + + The resource model definition for an Azure Resource Manager resource with + an etag. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :ivar etag: Resource Etag. :vartype etag: str @@ -98,22 +103,27 @@ class CapabilityProperties(Model): server editions. :vartype supported_flexible_server_editions: list[~azure.mgmt.rdbms.mysql_flexibleservers.models.ServerEditionCapability] + :ivar status: The status of the capability. + :vartype status: str """ _validation = { 'zone': {'readonly': True}, 'supported_flexible_server_editions': {'readonly': True}, + 'status': {'readonly': True}, } _attribute_map = { 'zone': {'key': 'zone', 'type': 'str'}, 'supported_flexible_server_editions': {'key': 'supportedFlexibleServerEditions', 'type': '[ServerEditionCapability]'}, + 'status': {'key': 'status', 'type': 'str'}, } def __init__(self, **kwargs): super(CapabilityProperties, self).__init__(**kwargs) self.zone = None self.supported_flexible_server_editions = None + self.status = None class CloudError(Model): @@ -145,19 +155,21 @@ def __init__(self, deserialize, response, *args): class ProxyResource(Resource): - """The resource model definition for a ARM proxy resource. It will have - everything other than required location and tags. + """Proxy Resource. + + The resource model definition for a Azure Resource Manager proxy resource. + It will not have tags and a location. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str """ @@ -183,13 +195,13 @@ class Configuration(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param value: Value of the configuration. :type value: str @@ -258,19 +270,40 @@ def __init__(self, **kwargs): self.is_dynamic_config = None +class ConfigurationListResult(Model): + """A list of server configurations. + + :param value: The list of server configurations. + :type value: + list[~azure.mgmt.rdbms.mysql_flexibleservers.models.Configuration] + :param next_link: The link used to get the next page of operations. + :type next_link: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': '[Configuration]'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ConfigurationListResult, self).__init__(**kwargs) + self.value = kwargs.get('value', None) + self.next_link = kwargs.get('next_link', None) + + class Database(ProxyResource): """Represents a Database. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param charset: The charset of the database. :type charset: str @@ -371,7 +404,11 @@ def __init__(self, **kwargs): class ErrorResponse(Model): - """The resource management error response. + """Error Response. + + Common error response for all Azure Resource Manager APIs to return error + details for failed operations. (This also follows the OData error response + format.). Variables are only populated by the server, and will be ignored when sending a request. @@ -423,13 +460,13 @@ class FirewallRule(ProxyResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param start_ip_address: Required. The start IP address of the server firewall rule. Must be IPv4 format. @@ -586,6 +623,8 @@ class Operation(Model): operation or action. :vartype display: ~azure.mgmt.rdbms.mysql_flexibleservers.models.OperationDisplay + :param is_data_action: Indicates whether the operation is a data action + :type is_data_action: bool :ivar origin: The intended executor of the operation. Possible values include: 'NotSpecified', 'user', 'system' :vartype origin: str or @@ -604,6 +643,7 @@ class Operation(Model): _attribute_map = { 'name': {'key': 'name', 'type': 'str'}, 'display': {'key': 'display', 'type': 'OperationDisplay'}, + 'is_data_action': {'key': 'isDataAction', 'type': 'bool'}, 'origin': {'key': 'origin', 'type': 'str'}, 'properties': {'key': 'properties', 'type': '{object}'}, } @@ -612,6 +652,7 @@ def __init__(self, **kwargs): super(Operation, self).__init__(**kwargs) self.name = None self.display = None + self.is_data_action = kwargs.get('is_data_action', None) self.origin = None self.properties = None @@ -657,18 +698,24 @@ def __init__(self, **kwargs): class OperationListResult(Model): """A list of resource provider operations. - :param value: The list of resource provider operations. + :param value: Collection of available operation details :type value: list[~azure.mgmt.rdbms.mysql_flexibleservers.models.Operation] + :param next_link: URL client should use to fetch the next page (per server + side paging). + It's null for now, added for future use. + :type next_link: str """ _attribute_map = { 'value': {'key': 'value', 'type': '[Operation]'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, } def __init__(self, **kwargs): super(OperationListResult, self).__init__(**kwargs) self.value = kwargs.get('value', None) + self.next_link = kwargs.get('next_link', None) class Plan(Model): @@ -724,19 +771,19 @@ class ResourceModelWithAllowedPropertySet(Model): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts.. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param location: The geo-location where the resource lives :type location: str - :param managed_by: The fully qualified resource ID of the resource that + :param managed_by: The fully qualified resource ID of the resource that manages this resource. Indicates if this resource is managed by another - azure resource. If this is present, complete mode deployment will not + Azure resource. If this is present, complete mode deployment will not delete the resource if it is removed from the template since it is managed by another resource. :type managed_by: str @@ -929,20 +976,23 @@ def __init__(self, **kwargs): class TrackedResource(Resource): - """The resource model definition for a ARM tracked top level resource. + """Tracked Resource. + + The resource model definition for an Azure Resource Manager tracked top + level resource which has 'tags' and a 'location'. 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 id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param tags: Resource tags. :type tags: dict[str, str] @@ -979,13 +1029,13 @@ class Server(TrackedResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param tags: Resource tags. :type tags: dict[str, str] @@ -1165,18 +1215,22 @@ class ServerEditionCapability(Model): :ivar supported_server_versions: A list of supported server versions. :vartype supported_server_versions: list[~azure.mgmt.rdbms.mysql_flexibleservers.models.ServerVersionCapability] + :ivar status: The status of the capability. + :vartype status: str """ _validation = { 'name': {'readonly': True}, 'supported_storage_editions': {'readonly': True}, 'supported_server_versions': {'readonly': True}, + 'status': {'readonly': True}, } _attribute_map = { 'name': {'key': 'name', 'type': 'str'}, 'supported_storage_editions': {'key': 'supportedStorageEditions', 'type': '[StorageEditionCapability]'}, 'supported_server_versions': {'key': 'supportedServerVersions', 'type': '[ServerVersionCapability]'}, + 'status': {'key': 'status', 'type': 'str'}, } def __init__(self, **kwargs): @@ -1184,6 +1238,7 @@ def __init__(self, **kwargs): self.name = None self.supported_storage_editions = None self.supported_server_versions = None + self.status = None class ServerForUpdate(Model): @@ -1250,13 +1305,13 @@ class ServerKey(ProxyResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :ivar kind: Kind of encryption protector used to protect the key. :vartype kind: str @@ -1308,22 +1363,27 @@ class ServerVersionCapability(Model): :ivar supported_vcores: A list of supported Vcores :vartype supported_vcores: list[~azure.mgmt.rdbms.mysql_flexibleservers.models.VcoreCapability] + :ivar status: The status of the capability. + :vartype status: str """ _validation = { 'name': {'readonly': True}, 'supported_vcores': {'readonly': True}, + 'status': {'readonly': True}, } _attribute_map = { 'name': {'key': 'name', 'type': 'str'}, 'supported_vcores': {'key': 'supportedVcores', 'type': '[VcoreCapability]'}, + 'status': {'key': 'status', 'type': 'str'}, } def __init__(self, **kwargs): super(ServerVersionCapability, self).__init__(**kwargs) self.name = None self.supported_vcores = None + self.status = None class StorageEditionCapability(Model): @@ -1344,6 +1404,8 @@ class StorageEditionCapability(Model): :vartype min_backup_retention_days: long :ivar max_backup_retention_days: Maximum backup retention days :vartype max_backup_retention_days: long + :ivar status: The status of the capability. + :vartype status: str """ _validation = { @@ -1352,6 +1414,7 @@ class StorageEditionCapability(Model): 'max_storage_size': {'readonly': True}, 'min_backup_retention_days': {'readonly': True}, 'max_backup_retention_days': {'readonly': True}, + 'status': {'readonly': True}, } _attribute_map = { @@ -1360,6 +1423,7 @@ class StorageEditionCapability(Model): 'max_storage_size': {'key': 'maxStorageSize', 'type': 'StorageMBCapability'}, 'min_backup_retention_days': {'key': 'minBackupRetentionDays', 'type': 'long'}, 'max_backup_retention_days': {'key': 'maxBackupRetentionDays', 'type': 'long'}, + 'status': {'key': 'status', 'type': 'str'}, } def __init__(self, **kwargs): @@ -1369,6 +1433,7 @@ def __init__(self, **kwargs): self.max_storage_size = None self.min_backup_retention_days = None self.max_backup_retention_days = None + self.status = None class StorageMBCapability(Model): @@ -1402,6 +1467,9 @@ def __init__(self, **kwargs): class StorageProfile(Model): """Storage Profile properties of a server. + Variables are only populated by the server, and will be ignored when + sending a request. + :param backup_retention_days: Backup retention days for the server. :type backup_retention_days: int :param storage_mb: Max storage allowed for a server. @@ -1412,13 +1480,20 @@ class StorageProfile(Model): include: 'Enabled', 'Disabled' :type storage_autogrow: str or ~azure.mgmt.rdbms.mysql_flexibleservers.models.StorageAutogrow + :ivar file_storage_sku_name: The sku name of the file storage. + :vartype file_storage_sku_name: str """ + _validation = { + 'file_storage_sku_name': {'readonly': True}, + } + _attribute_map = { 'backup_retention_days': {'key': 'backupRetentionDays', 'type': 'int'}, 'storage_mb': {'key': 'storageMB', 'type': 'int'}, 'storage_iops': {'key': 'storageIops', 'type': 'int'}, 'storage_autogrow': {'key': 'storageAutogrow', 'type': 'str'}, + 'file_storage_sku_name': {'key': 'fileStorageSkuName', 'type': 'str'}, } def __init__(self, **kwargs): @@ -1427,6 +1502,7 @@ def __init__(self, **kwargs): self.storage_mb = kwargs.get('storage_mb', None) self.storage_iops = kwargs.get('storage_iops', None) self.storage_autogrow = kwargs.get('storage_autogrow', None) + self.file_storage_sku_name = None class VcoreCapability(Model): @@ -1443,6 +1519,8 @@ class VcoreCapability(Model): :vartype supported_iops: long :ivar supported_memory_per_vcore_mb: supported memory per vCore in MB :vartype supported_memory_per_vcore_mb: long + :ivar status: The status of the capability. + :vartype status: str """ _validation = { @@ -1450,6 +1528,7 @@ class VcoreCapability(Model): 'v_cores': {'readonly': True}, 'supported_iops': {'readonly': True}, 'supported_memory_per_vcore_mb': {'readonly': True}, + 'status': {'readonly': True}, } _attribute_map = { @@ -1457,6 +1536,7 @@ class VcoreCapability(Model): 'v_cores': {'key': 'vCores', 'type': 'long'}, 'supported_iops': {'key': 'supportedIops', 'type': 'long'}, 'supported_memory_per_vcore_mb': {'key': 'supportedMemoryPerVcoreMB', 'type': 'long'}, + 'status': {'key': 'status', 'type': 'str'}, } def __init__(self, **kwargs): @@ -1465,6 +1545,7 @@ def __init__(self, **kwargs): self.v_cores = None self.supported_iops = None self.supported_memory_per_vcore_mb = None + self.status = None class VirtualNetworkSubnetUsageParameter(Model): diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/models/_models_py3.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/models/_models_py3.py index 99bfb6d7ca102..ac49d3824aae9 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/models/_models_py3.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/models/_models_py3.py @@ -16,16 +16,19 @@ class Resource(Model): """Resource. + Common fields that are returned in the response for all Azure Resource + Manager resources. + Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str """ @@ -49,19 +52,21 @@ def __init__(self, **kwargs) -> None: class AzureEntityResource(Resource): - """The resource model definition for a Azure Resource Manager resource with an - etag. + """Entity Resource. + + The resource model definition for an Azure Resource Manager resource with + an etag. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :ivar etag: Resource Etag. :vartype etag: str @@ -98,22 +103,27 @@ class CapabilityProperties(Model): server editions. :vartype supported_flexible_server_editions: list[~azure.mgmt.rdbms.mysql_flexibleservers.models.ServerEditionCapability] + :ivar status: The status of the capability. + :vartype status: str """ _validation = { 'zone': {'readonly': True}, 'supported_flexible_server_editions': {'readonly': True}, + 'status': {'readonly': True}, } _attribute_map = { 'zone': {'key': 'zone', 'type': 'str'}, 'supported_flexible_server_editions': {'key': 'supportedFlexibleServerEditions', 'type': '[ServerEditionCapability]'}, + 'status': {'key': 'status', 'type': 'str'}, } def __init__(self, **kwargs) -> None: super(CapabilityProperties, self).__init__(**kwargs) self.zone = None self.supported_flexible_server_editions = None + self.status = None class CloudError(Model): @@ -145,19 +155,21 @@ def __init__(self, deserialize, response, *args): class ProxyResource(Resource): - """The resource model definition for a ARM proxy resource. It will have - everything other than required location and tags. + """Proxy Resource. + + The resource model definition for a Azure Resource Manager proxy resource. + It will not have tags and a location. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str """ @@ -183,13 +195,13 @@ class Configuration(ProxyResource): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param value: Value of the configuration. :type value: str @@ -258,19 +270,40 @@ def __init__(self, *, value: str=None, source: str=None, **kwargs) -> None: self.is_dynamic_config = None +class ConfigurationListResult(Model): + """A list of server configurations. + + :param value: The list of server configurations. + :type value: + list[~azure.mgmt.rdbms.mysql_flexibleservers.models.Configuration] + :param next_link: The link used to get the next page of operations. + :type next_link: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': '[Configuration]'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, + } + + def __init__(self, *, value=None, next_link: str=None, **kwargs) -> None: + super(ConfigurationListResult, self).__init__(**kwargs) + self.value = value + self.next_link = next_link + + class Database(ProxyResource): """Represents a Database. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param charset: The charset of the database. :type charset: str @@ -371,7 +404,11 @@ def __init__(self, **kwargs) -> None: class ErrorResponse(Model): - """The resource management error response. + """Error Response. + + Common error response for all Azure Resource Manager APIs to return error + details for failed operations. (This also follows the OData error response + format.). Variables are only populated by the server, and will be ignored when sending a request. @@ -423,13 +460,13 @@ class FirewallRule(ProxyResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param start_ip_address: Required. The start IP address of the server firewall rule. Must be IPv4 format. @@ -586,6 +623,8 @@ class Operation(Model): operation or action. :vartype display: ~azure.mgmt.rdbms.mysql_flexibleservers.models.OperationDisplay + :param is_data_action: Indicates whether the operation is a data action + :type is_data_action: bool :ivar origin: The intended executor of the operation. Possible values include: 'NotSpecified', 'user', 'system' :vartype origin: str or @@ -604,14 +643,16 @@ class Operation(Model): _attribute_map = { 'name': {'key': 'name', 'type': 'str'}, 'display': {'key': 'display', 'type': 'OperationDisplay'}, + 'is_data_action': {'key': 'isDataAction', 'type': 'bool'}, 'origin': {'key': 'origin', 'type': 'str'}, 'properties': {'key': 'properties', 'type': '{object}'}, } - def __init__(self, **kwargs) -> None: + def __init__(self, *, is_data_action: bool=None, **kwargs) -> None: super(Operation, self).__init__(**kwargs) self.name = None self.display = None + self.is_data_action = is_data_action self.origin = None self.properties = None @@ -657,18 +698,24 @@ def __init__(self, **kwargs) -> None: class OperationListResult(Model): """A list of resource provider operations. - :param value: The list of resource provider operations. + :param value: Collection of available operation details :type value: list[~azure.mgmt.rdbms.mysql_flexibleservers.models.Operation] + :param next_link: URL client should use to fetch the next page (per server + side paging). + It's null for now, added for future use. + :type next_link: str """ _attribute_map = { 'value': {'key': 'value', 'type': '[Operation]'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, } - def __init__(self, *, value=None, **kwargs) -> None: + def __init__(self, *, value=None, next_link: str=None, **kwargs) -> None: super(OperationListResult, self).__init__(**kwargs) self.value = value + self.next_link = next_link class Plan(Model): @@ -724,19 +771,19 @@ class ResourceModelWithAllowedPropertySet(Model): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts.. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param location: The geo-location where the resource lives :type location: str - :param managed_by: The fully qualified resource ID of the resource that + :param managed_by: The fully qualified resource ID of the resource that manages this resource. Indicates if this resource is managed by another - azure resource. If this is present, complete mode deployment will not + Azure resource. If this is present, complete mode deployment will not delete the resource if it is removed from the template since it is managed by another resource. :type managed_by: str @@ -929,20 +976,23 @@ def __init__(self, *, name: str, tier, **kwargs) -> None: class TrackedResource(Resource): - """The resource model definition for a ARM tracked top level resource. + """Tracked Resource. + + The resource model definition for an Azure Resource Manager tracked top + level resource which has 'tags' and a 'location'. 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 id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param tags: Resource tags. :type tags: dict[str, str] @@ -979,13 +1029,13 @@ class Server(TrackedResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param tags: Resource tags. :type tags: dict[str, str] @@ -1165,18 +1215,22 @@ class ServerEditionCapability(Model): :ivar supported_server_versions: A list of supported server versions. :vartype supported_server_versions: list[~azure.mgmt.rdbms.mysql_flexibleservers.models.ServerVersionCapability] + :ivar status: The status of the capability. + :vartype status: str """ _validation = { 'name': {'readonly': True}, 'supported_storage_editions': {'readonly': True}, 'supported_server_versions': {'readonly': True}, + 'status': {'readonly': True}, } _attribute_map = { 'name': {'key': 'name', 'type': 'str'}, 'supported_storage_editions': {'key': 'supportedStorageEditions', 'type': '[StorageEditionCapability]'}, 'supported_server_versions': {'key': 'supportedServerVersions', 'type': '[ServerVersionCapability]'}, + 'status': {'key': 'status', 'type': 'str'}, } def __init__(self, **kwargs) -> None: @@ -1184,6 +1238,7 @@ def __init__(self, **kwargs) -> None: self.name = None self.supported_storage_editions = None self.supported_server_versions = None + self.status = None class ServerForUpdate(Model): @@ -1250,13 +1305,13 @@ class ServerKey(ProxyResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :ivar kind: Kind of encryption protector used to protect the key. :vartype kind: str @@ -1308,22 +1363,27 @@ class ServerVersionCapability(Model): :ivar supported_vcores: A list of supported Vcores :vartype supported_vcores: list[~azure.mgmt.rdbms.mysql_flexibleservers.models.VcoreCapability] + :ivar status: The status of the capability. + :vartype status: str """ _validation = { 'name': {'readonly': True}, 'supported_vcores': {'readonly': True}, + 'status': {'readonly': True}, } _attribute_map = { 'name': {'key': 'name', 'type': 'str'}, 'supported_vcores': {'key': 'supportedVcores', 'type': '[VcoreCapability]'}, + 'status': {'key': 'status', 'type': 'str'}, } def __init__(self, **kwargs) -> None: super(ServerVersionCapability, self).__init__(**kwargs) self.name = None self.supported_vcores = None + self.status = None class StorageEditionCapability(Model): @@ -1344,6 +1404,8 @@ class StorageEditionCapability(Model): :vartype min_backup_retention_days: long :ivar max_backup_retention_days: Maximum backup retention days :vartype max_backup_retention_days: long + :ivar status: The status of the capability. + :vartype status: str """ _validation = { @@ -1352,6 +1414,7 @@ class StorageEditionCapability(Model): 'max_storage_size': {'readonly': True}, 'min_backup_retention_days': {'readonly': True}, 'max_backup_retention_days': {'readonly': True}, + 'status': {'readonly': True}, } _attribute_map = { @@ -1360,6 +1423,7 @@ class StorageEditionCapability(Model): 'max_storage_size': {'key': 'maxStorageSize', 'type': 'StorageMBCapability'}, 'min_backup_retention_days': {'key': 'minBackupRetentionDays', 'type': 'long'}, 'max_backup_retention_days': {'key': 'maxBackupRetentionDays', 'type': 'long'}, + 'status': {'key': 'status', 'type': 'str'}, } def __init__(self, **kwargs) -> None: @@ -1369,6 +1433,7 @@ def __init__(self, **kwargs) -> None: self.max_storage_size = None self.min_backup_retention_days = None self.max_backup_retention_days = None + self.status = None class StorageMBCapability(Model): @@ -1402,6 +1467,9 @@ def __init__(self, **kwargs) -> None: class StorageProfile(Model): """Storage Profile properties of a server. + Variables are only populated by the server, and will be ignored when + sending a request. + :param backup_retention_days: Backup retention days for the server. :type backup_retention_days: int :param storage_mb: Max storage allowed for a server. @@ -1412,13 +1480,20 @@ class StorageProfile(Model): include: 'Enabled', 'Disabled' :type storage_autogrow: str or ~azure.mgmt.rdbms.mysql_flexibleservers.models.StorageAutogrow + :ivar file_storage_sku_name: The sku name of the file storage. + :vartype file_storage_sku_name: str """ + _validation = { + 'file_storage_sku_name': {'readonly': True}, + } + _attribute_map = { 'backup_retention_days': {'key': 'backupRetentionDays', 'type': 'int'}, 'storage_mb': {'key': 'storageMB', 'type': 'int'}, 'storage_iops': {'key': 'storageIops', 'type': 'int'}, 'storage_autogrow': {'key': 'storageAutogrow', 'type': 'str'}, + 'file_storage_sku_name': {'key': 'fileStorageSkuName', 'type': 'str'}, } def __init__(self, *, backup_retention_days: int=None, storage_mb: int=None, storage_iops: int=None, storage_autogrow=None, **kwargs) -> None: @@ -1427,6 +1502,7 @@ def __init__(self, *, backup_retention_days: int=None, storage_mb: int=None, sto self.storage_mb = storage_mb self.storage_iops = storage_iops self.storage_autogrow = storage_autogrow + self.file_storage_sku_name = None class VcoreCapability(Model): @@ -1443,6 +1519,8 @@ class VcoreCapability(Model): :vartype supported_iops: long :ivar supported_memory_per_vcore_mb: supported memory per vCore in MB :vartype supported_memory_per_vcore_mb: long + :ivar status: The status of the capability. + :vartype status: str """ _validation = { @@ -1450,6 +1528,7 @@ class VcoreCapability(Model): 'v_cores': {'readonly': True}, 'supported_iops': {'readonly': True}, 'supported_memory_per_vcore_mb': {'readonly': True}, + 'status': {'readonly': True}, } _attribute_map = { @@ -1457,6 +1536,7 @@ class VcoreCapability(Model): 'v_cores': {'key': 'vCores', 'type': 'long'}, 'supported_iops': {'key': 'supportedIops', 'type': 'long'}, 'supported_memory_per_vcore_mb': {'key': 'supportedMemoryPerVcoreMB', 'type': 'long'}, + 'status': {'key': 'status', 'type': 'str'}, } def __init__(self, **kwargs) -> None: @@ -1465,6 +1545,7 @@ def __init__(self, **kwargs) -> None: self.v_cores = None self.supported_iops = None self.supported_memory_per_vcore_mb = None + self.status = None class VirtualNetworkSubnetUsageParameter(Model): diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_check_name_availability_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_check_name_availability_operations.py index 411255d377661..4a4de540d6a33 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_check_name_availability_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_check_name_availability_operations.py @@ -25,7 +25,7 @@ class CheckNameAvailabilityOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-privatepreview". + :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-preview". """ models = models @@ -35,7 +35,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2020-07-01-privatepreview" + self.api_version = "2020-07-01-preview" self.config = config diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_check_virtual_network_subnet_usage_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_check_virtual_network_subnet_usage_operations.py index 17d778fe76319..a6f99393afcc3 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_check_virtual_network_subnet_usage_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_check_virtual_network_subnet_usage_operations.py @@ -25,7 +25,7 @@ class CheckVirtualNetworkSubnetUsageOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-privatepreview". + :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-preview". """ models = models @@ -35,7 +35,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2020-07-01-privatepreview" + self.api_version = "2020-07-01-preview" self.config = config diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_configurations_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_configurations_operations.py index 103562abfc67b..8ec4d4c455fb5 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_configurations_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_configurations_operations.py @@ -27,7 +27,7 @@ class ConfigurationsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-privatepreview". + :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-preview". """ models = models @@ -37,7 +37,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2020-07-01-privatepreview" + self.api_version = "2020-07-01-preview" self.config = config @@ -50,7 +50,7 @@ def _update_initial( url = self.update.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'configurationName': self._serialize.url("configuration_name", configuration_name, 'str') } @@ -176,7 +176,7 @@ def get( url = self.get.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'configurationName': self._serialize.url("configuration_name", configuration_name, 'str') } @@ -216,6 +216,113 @@ def get( return deserialized get.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBForMySql/flexibleServers/{serverName}/configurations/{configurationName}'} + + def _batch_update_initial( + self, resource_group_name, server_name, value=None, next_link=None, custom_headers=None, raw=False, **operation_config): + value1 = models.ConfigurationListResult(value=value, next_link=next_link) + + # Construct URL + url = self.batch_update.metadata['url'] + path_format_arguments = { + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), + 'serverName': self._serialize.url("server_name", server_name, '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', min_length=1) + + # 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()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct body + body_content = self._serialize.body(value1, 'ConfigurationListResult') + + # Construct and send request + request = self._client.post(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200, 202]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('ConfigurationListResult', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + + def batch_update( + self, resource_group_name, server_name, value=None, next_link=None, custom_headers=None, raw=False, polling=True, **operation_config): + """Update a list of configurations in a given server. + + :param resource_group_name: The name of the resource group. The name + is case insensitive. + :type resource_group_name: str + :param server_name: The name of the server. + :type server_name: str + :param value: The list of server configurations. + :type value: + list[~azure.mgmt.rdbms.mysql_flexibleservers.models.Configuration] + :param next_link: The link used to get the next page of operations. + :type next_link: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: The poller return type is ClientRawResponse, the + direct response alongside the deserialized response + :param polling: True for ARMPolling, False for no polling, or a + polling object for personal polling strategy + :return: An instance of LROPoller that returns ConfigurationListResult + or ClientRawResponse if raw==True + :rtype: + ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.rdbms.mysql_flexibleservers.models.ConfigurationListResult] + or + ~msrestazure.azure_operation.AzureOperationPoller[~msrest.pipeline.ClientRawResponse[~azure.mgmt.rdbms.mysql_flexibleservers.models.ConfigurationListResult]] + :raises: :class:`CloudError` + """ + raw_result = self._batch_update_initial( + resource_group_name=resource_group_name, + server_name=server_name, + value=value, + next_link=next_link, + custom_headers=custom_headers, + raw=True, + **operation_config + ) + + def get_long_running_output(response): + deserialized = self._deserialize('ConfigurationListResult', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + + lro_delay = operation_config.get( + 'long_running_operation_timeout', + self.config.long_running_operation_timeout) + if polling is True: polling_method = ARMPolling(lro_delay, lro_options={'final-state-via': 'azure-async-operation'}, **operation_config) + elif polling is False: polling_method = NoPolling() + else: polling_method = polling + return LROPoller(self._client, raw_result, get_long_running_output, polling_method) + batch_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBForMySql/flexibleServers/{serverName}/updateConfigurations'} + def list_by_server( self, resource_group_name, server_name, custom_headers=None, raw=False, **operation_config): """List all the configurations in a given server. @@ -241,7 +348,7 @@ def prepare_request(next_link=None): url = self.list_by_server.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_databases_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_databases_operations.py index 2a0da646f3b37..ecbf3726a79b7 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_databases_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_databases_operations.py @@ -27,7 +27,7 @@ class DatabasesOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-privatepreview". + :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-preview". """ models = models @@ -37,7 +37,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2020-07-01-privatepreview" + self.api_version = "2020-07-01-preview" self.config = config @@ -50,7 +50,7 @@ def _create_or_update_initial( url = self.create_or_update.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'databaseName': self._serialize.url("database_name", database_name, 'str') } @@ -160,7 +160,7 @@ def _delete_initial( url = self.delete.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'databaseName': self._serialize.url("database_name", database_name, 'str') } @@ -262,7 +262,7 @@ def get( url = self.get.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'databaseName': self._serialize.url("database_name", database_name, 'str') } @@ -327,7 +327,7 @@ def prepare_request(next_link=None): url = self.list_by_server.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_firewall_rules_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_firewall_rules_operations.py index 85393787cffe0..5704403e796cd 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_firewall_rules_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_firewall_rules_operations.py @@ -27,7 +27,7 @@ class FirewallRulesOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-privatepreview". + :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-preview". """ models = models @@ -37,7 +37,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2020-07-01-privatepreview" + self.api_version = "2020-07-01-preview" self.config = config @@ -50,7 +50,7 @@ def _create_or_update_initial( url = self.create_or_update.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'firewallRuleName': self._serialize.url("firewall_rule_name", firewall_rule_name, 'str') } @@ -162,7 +162,7 @@ def _delete_initial( url = self.delete.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'firewallRuleName': self._serialize.url("firewall_rule_name", firewall_rule_name, 'str') } @@ -264,7 +264,7 @@ def get( url = self.get.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'firewallRuleName': self._serialize.url("firewall_rule_name", firewall_rule_name, 'str') } @@ -329,7 +329,7 @@ def prepare_request(next_link=None): url = self.list_by_server.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_location_based_capabilities_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_location_based_capabilities_operations.py index f9a360a47b095..c58ad6d10fdce 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_location_based_capabilities_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_location_based_capabilities_operations.py @@ -25,7 +25,7 @@ class LocationBasedCapabilitiesOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-privatepreview". + :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-preview". """ models = models @@ -35,7 +35,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2020-07-01-privatepreview" + self.api_version = "2020-07-01-preview" self.config = config diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_operations.py index f8a6d999a89f4..e9a61b781b9b0 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_operations.py @@ -25,7 +25,7 @@ class Operations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-privatepreview". + :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-preview". """ models = models @@ -35,7 +35,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2017-12-01" + self.api_version = "2020-07-01-preview" self.config = config diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_replicas_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_replicas_operations.py index 0e52d1935266f..1f4378eead6ca 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_replicas_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_replicas_operations.py @@ -25,7 +25,7 @@ class ReplicasOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-privatepreview". + :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-preview". """ models = models @@ -35,7 +35,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2020-07-01-privatepreview" + self.api_version = "2020-07-01-preview" self.config = config @@ -64,7 +64,7 @@ def prepare_request(next_link=None): url = self.list_by_server.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_server_keys_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_server_keys_operations.py index 322b4eb4faff8..4eee0e8297630 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_server_keys_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_server_keys_operations.py @@ -27,7 +27,7 @@ class ServerKeysOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-privatepreview". + :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-preview". """ models = models @@ -37,7 +37,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2020-07-01-privatepreview" + self.api_version = "2020-07-01-preview" self.config = config @@ -50,7 +50,7 @@ def _create_or_update_initial( url = self.create_or_update.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'keyName': self._serialize.url("key_name", key_name, 'str') } @@ -157,7 +157,7 @@ def _delete_initial( url = self.delete.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'keyName': self._serialize.url("key_name", key_name, 'str') } @@ -259,7 +259,7 @@ def get( url = self.get.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str'), 'keyName': self._serialize.url("key_name", key_name, 'str') } @@ -324,7 +324,7 @@ def prepare_request(next_link=None): url = self.list_by_server.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_servers_operations.py b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_servers_operations.py index 56561cf848c1d..8202f981271d4 100644 --- a/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_servers_operations.py +++ b/sdk/rdbms/azure-mgmt-rdbms/azure/mgmt/rdbms/mysql_flexibleservers/operations/_servers_operations.py @@ -27,7 +27,7 @@ class ServersOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-privatepreview". + :ivar api_version: The API version to use for this operation. Constant value: "2020-07-01-preview". """ models = models @@ -37,7 +37,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2020-07-01-privatepreview" + self.api_version = "2020-07-01-preview" self.config = config @@ -48,7 +48,7 @@ def _create_initial( url = self.create.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -154,7 +154,7 @@ def _update_initial( url = self.update.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -257,7 +257,7 @@ def _delete_initial( url = self.delete.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -353,7 +353,7 @@ def get( url = self.get.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -415,7 +415,7 @@ def prepare_request(next_link=None): url = self.list_by_resource_group.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$') + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1) } url = self._client.format_url(url, **path_format_arguments) @@ -535,7 +535,7 @@ def _restart_initial( url = self.restart.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -615,7 +615,7 @@ def _start_initial( url = self.start.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -695,7 +695,7 @@ def _stop_initial( url = self.stop.metadata['url'] path_format_arguments = { 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str', min_length=1), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1), 'serverName': self._serialize.url("server_name", server_name, 'str') } url = self._client.format_url(url, **path_format_arguments)