Skip to content

Commit

Permalink
CodeGen from PR 18192 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
update readme 7_10 (Azure#18192)

* update readme 7_10

* Update readme.python.md

* Update readme.python.md

* Update readme.python.md

* Update readme.python.md
  • Loading branch information
SDKAuto committed Mar 15, 2022
1 parent 14ff5a8 commit 032d955
Show file tree
Hide file tree
Showing 7 changed files with 889 additions and 892 deletions.
4 changes: 2 additions & 2 deletions sdk/sql/azure-mgmt-sql/_meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
"@autorest/python@5.12.0",
"@autorest/modelerfour@4.19.3"
],
"commit": "989a7d0e47a71a77d9a8e56f2a3eee0d366b6909",
"commit": "7ddb64b3248bb251f085e0c2a33d6744e7142f13",
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
"autorest_command": "autorest specification/sql/resource-manager/readme.md --multiapi --python --python-mode=update --python-sdks-folder=/home/vsts/work/1/azure-sdk-for-python/sdk --python3-only --track2 --use=@autorest/python@5.12.0 --use=@autorest/modelerfour@4.19.3 --version=3.7.2",
"autorest_command": "autorest specification/sql/resource-manager/readme.md --multiapi --python --python-mode=update --python-sdks-folder=/home/vsts/work/1/s/azure-sdk-for-python/sdk --python3-only --track2 --use=@autorest/python@5.12.0 --use=@autorest/modelerfour@4.19.3 --version=3.7.2",
"readme": "specification/sql/resource-manager/readme.md"
}
2 changes: 1 addition & 1 deletion sdk/sql/azure-mgmt-sql/azure/mgmt/sql/_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------

VERSION = "4.0.0b2"
VERSION = "0.9.0"

Large diffs are not rendered by default.

2 changes: 0 additions & 2 deletions sdk/sql/azure-mgmt-sql/azure/mgmt/sql/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@
from ._models_py3 import DatabaseVulnerabilityAssessmentRuleBaseline
from ._models_py3 import DatabaseVulnerabilityAssessmentRuleBaselineItem
from ._models_py3 import DatabaseVulnerabilityAssessmentScansExport
from ._models_py3 import Delegation
from ._models_py3 import DeletedServer
from ._models_py3 import DeletedServerListResult
from ._models_py3 import DistributedAvailabilityGroup
Expand Down Expand Up @@ -538,7 +537,6 @@
'DatabaseVulnerabilityAssessmentRuleBaseline',
'DatabaseVulnerabilityAssessmentRuleBaselineItem',
'DatabaseVulnerabilityAssessmentScansExport',
'Delegation',
'DeletedServer',
'DeletedServerListResult',
'DistributedAvailabilityGroup',
Expand Down
137 changes: 68 additions & 69 deletions sdk/sql/azure-mgmt-sql/azure/mgmt/sql/models/_models_py3.py
Original file line number Diff line number Diff line change
Expand Up @@ -880,10 +880,12 @@ class Database(TrackedResource):
:vartype earliest_restore_date: ~datetime.datetime
:ivar read_scale: The state of read-only routing. If enabled, connections that have application
intent set to readonly in their connection string may be routed to a readonly secondary replica
in the same region. Possible values include: "Enabled", "Disabled".
in the same region. Not applicable to a Hyperscale database within an elastic pool. Possible
values include: "Enabled", "Disabled".
:vartype read_scale: str or ~azure.mgmt.sql.models.DatabaseReadScale
:ivar high_availability_replica_count: The number of secondary replicas associated with the
database that are used to provide high availability.
database that are used to provide high availability. Not applicable to a Hyperscale database
within an elastic pool.
:vartype high_availability_replica_count: int
:ivar secondary_type: The secondary type of the database if it is a secondary. Valid values
are Geo and Named. Possible values include: "Geo", "Named".
Expand Down Expand Up @@ -920,9 +922,30 @@ class Database(TrackedResource):
:vartype is_infra_encryption_enabled: bool
:ivar federated_client_id: The Client id used for cross tenant per database CMK scenario.
:vartype federated_client_id: str
:ivar primary_delegated_identity_client_id: The Primary Delegated Identity Client id used for
per database CMK - for internal use only.
:vartype primary_delegated_identity_client_id: str
:ivar source_resource_id: The resource identifier of the source associated with the create
operation of this database.

When sourceResourceId is specified, sourceDatabaseId, recoverableDatabaseId,
restorableDroppedDatabaseId and sourceDatabaseDeletionDate must not be specified and CreateMode
must be PointInTimeRestore, Restore or Recover.

When createMode is PointInTimeRestore, sourceResourceId must be the resource ID of an existing
database or existing sql pool, and restorePointInTime must be specified.

When createMode is Restore, sourceResourceId must be the resource ID of restorable dropped
database or restorable dropped sql pool.

When createMode is Recover, sourceResourceId must be the resource ID of recoverable database
or recoverable sql pool.

This property allows to restore across subscriptions which is only supported for DataWarehouse
edition.

When source subscription belongs to a different tenant than target subscription,
“x-ms-authorization-auxiliary” header must contain authentication token for the source tenant.
For more details about “x-ms-authorization-auxiliary” header see
https://docs.microsoft.com/en-us/azure/azure-resource-manager/management/authenticate-multi-tenant.
:vartype source_resource_id: str
"""

_validation = {
Expand Down Expand Up @@ -996,7 +1019,7 @@ class Database(TrackedResource):
'is_ledger_on': {'key': 'properties.isLedgerOn', 'type': 'bool'},
'is_infra_encryption_enabled': {'key': 'properties.isInfraEncryptionEnabled', 'type': 'bool'},
'federated_client_id': {'key': 'properties.federatedClientId', 'type': 'str'},
'primary_delegated_identity_client_id': {'key': 'properties.primaryDelegatedIdentityClientId', 'type': 'str'},
'source_resource_id': {'key': 'properties.sourceResourceId', 'type': 'str'},
}

def __init__(
Expand Down Expand Up @@ -1030,7 +1053,7 @@ def __init__(
maintenance_configuration_id: Optional[str] = None,
is_ledger_on: Optional[bool] = None,
federated_client_id: Optional[str] = None,
primary_delegated_identity_client_id: Optional[str] = None,
source_resource_id: Optional[str] = None,
**kwargs
):
"""
Expand Down Expand Up @@ -1130,10 +1153,12 @@ def __init__(
:paramtype license_type: str or ~azure.mgmt.sql.models.DatabaseLicenseType
:keyword read_scale: The state of read-only routing. If enabled, connections that have
application intent set to readonly in their connection string may be routed to a readonly
secondary replica in the same region. Possible values include: "Enabled", "Disabled".
secondary replica in the same region. Not applicable to a Hyperscale database within an elastic
pool. Possible values include: "Enabled", "Disabled".
:paramtype read_scale: str or ~azure.mgmt.sql.models.DatabaseReadScale
:keyword high_availability_replica_count: The number of secondary replicas associated with the
database that are used to provide high availability.
database that are used to provide high availability. Not applicable to a Hyperscale database
within an elastic pool.
:paramtype high_availability_replica_count: int
:keyword secondary_type: The secondary type of the database if it is a secondary. Valid values
are Geo and Named. Possible values include: "Geo", "Named".
Expand All @@ -1157,9 +1182,30 @@ def __init__(
:paramtype is_ledger_on: bool
:keyword federated_client_id: The Client id used for cross tenant per database CMK scenario.
:paramtype federated_client_id: str
:keyword primary_delegated_identity_client_id: The Primary Delegated Identity Client id used
for per database CMK - for internal use only.
:paramtype primary_delegated_identity_client_id: str
:keyword source_resource_id: The resource identifier of the source associated with the create
operation of this database.

When sourceResourceId is specified, sourceDatabaseId, recoverableDatabaseId,
restorableDroppedDatabaseId and sourceDatabaseDeletionDate must not be specified and CreateMode
must be PointInTimeRestore, Restore or Recover.

When createMode is PointInTimeRestore, sourceResourceId must be the resource ID of an existing
database or existing sql pool, and restorePointInTime must be specified.

When createMode is Restore, sourceResourceId must be the resource ID of restorable dropped
database or restorable dropped sql pool.

When createMode is Recover, sourceResourceId must be the resource ID of recoverable database
or recoverable sql pool.

This property allows to restore across subscriptions which is only supported for DataWarehouse
edition.

When source subscription belongs to a different tenant than target subscription,
“x-ms-authorization-auxiliary” header must contain authentication token for the source tenant.
For more details about “x-ms-authorization-auxiliary” header see
https://docs.microsoft.com/en-us/azure/azure-resource-manager/management/authenticate-multi-tenant.
:paramtype source_resource_id: str
"""
super(Database, self).__init__(location=location, tags=tags, **kwargs)
self.sku = sku
Expand Down Expand Up @@ -1204,7 +1250,7 @@ def __init__(
self.is_ledger_on = is_ledger_on
self.is_infra_encryption_enabled = None
self.federated_client_id = federated_client_id
self.primary_delegated_identity_client_id = primary_delegated_identity_client_id
self.source_resource_id = source_resource_id


class DatabaseAutomaticTuning(ProxyResource):
Expand Down Expand Up @@ -1781,8 +1827,6 @@ class DatabaseIdentity(msrest.serialization.Model):
:vartype tenant_id: str
:ivar user_assigned_identities: The resource ids of the user assigned identities to use.
:vartype user_assigned_identities: dict[str, ~azure.mgmt.sql.models.DatabaseUserIdentity]
:ivar delegated_resources: Resources delegated to the database - Internal Use Only.
:vartype delegated_resources: dict[str, ~azure.mgmt.sql.models.Delegation]
"""

_validation = {
Expand All @@ -1793,30 +1837,25 @@ class DatabaseIdentity(msrest.serialization.Model):
'type': {'key': 'type', 'type': 'str'},
'tenant_id': {'key': 'tenantId', 'type': 'str'},
'user_assigned_identities': {'key': 'userAssignedIdentities', 'type': '{DatabaseUserIdentity}'},
'delegated_resources': {'key': 'delegatedResources', 'type': '{Delegation}'},
}

def __init__(
self,
*,
type: Optional[Union[str, "DatabaseIdentityType"]] = None,
user_assigned_identities: Optional[Dict[str, "DatabaseUserIdentity"]] = None,
delegated_resources: Optional[Dict[str, "Delegation"]] = None,
**kwargs
):
"""
:keyword type: The identity type. Possible values include: "None", "UserAssigned".
:paramtype type: str or ~azure.mgmt.sql.models.DatabaseIdentityType
:keyword user_assigned_identities: The resource ids of the user assigned identities to use.
:paramtype user_assigned_identities: dict[str, ~azure.mgmt.sql.models.DatabaseUserIdentity]
:keyword delegated_resources: Resources delegated to the database - Internal Use Only.
:paramtype delegated_resources: dict[str, ~azure.mgmt.sql.models.Delegation]
"""
super(DatabaseIdentity, self).__init__(**kwargs)
self.type = type
self.tenant_id = None
self.user_assigned_identities = user_assigned_identities
self.delegated_resources = delegated_resources


class DatabaseListResult(msrest.serialization.Model):
Expand Down Expand Up @@ -2279,7 +2318,7 @@ def __init__(


class DatabaseUpdate(msrest.serialization.Model):
"""A database resource.
"""A database update resource.

Variables are only populated by the server, and will be ignored when sending a request.

Expand Down Expand Up @@ -2386,10 +2425,12 @@ class DatabaseUpdate(msrest.serialization.Model):
:vartype earliest_restore_date: ~datetime.datetime
:ivar read_scale: The state of read-only routing. If enabled, connections that have application
intent set to readonly in their connection string may be routed to a readonly secondary replica
in the same region. Possible values include: "Enabled", "Disabled".
in the same region. Not applicable to a Hyperscale database within an elastic pool. Possible
values include: "Enabled", "Disabled".
:vartype read_scale: str or ~azure.mgmt.sql.models.DatabaseReadScale
:ivar high_availability_replica_count: The number of secondary replicas associated with the
database that are used to provide high availability.
database that are used to provide high availability. Not applicable to a Hyperscale database
within an elastic pool.
:vartype high_availability_replica_count: int
:ivar secondary_type: The secondary type of the database if it is a secondary. Valid values
are Geo and Named. Possible values include: "Geo", "Named".
Expand Down Expand Up @@ -2426,9 +2467,6 @@ class DatabaseUpdate(msrest.serialization.Model):
:vartype is_infra_encryption_enabled: bool
:ivar federated_client_id: The Client id used for cross tenant per database CMK scenario.
:vartype federated_client_id: str
:ivar primary_delegated_identity_client_id: The Primary Delegated Identity Client id used for
per database CMK - for internal use only.
:vartype primary_delegated_identity_client_id: str
"""

_validation = {
Expand Down Expand Up @@ -2490,7 +2528,6 @@ class DatabaseUpdate(msrest.serialization.Model):
'is_ledger_on': {'key': 'properties.isLedgerOn', 'type': 'bool'},
'is_infra_encryption_enabled': {'key': 'properties.isInfraEncryptionEnabled', 'type': 'bool'},
'federated_client_id': {'key': 'properties.federatedClientId', 'type': 'str'},
'primary_delegated_identity_client_id': {'key': 'properties.primaryDelegatedIdentityClientId', 'type': 'str'},
}

def __init__(
Expand Down Expand Up @@ -2523,7 +2560,6 @@ def __init__(
maintenance_configuration_id: Optional[str] = None,
is_ledger_on: Optional[bool] = None,
federated_client_id: Optional[str] = None,
primary_delegated_identity_client_id: Optional[str] = None,
**kwargs
):
"""
Expand Down Expand Up @@ -2606,10 +2642,12 @@ def __init__(
:paramtype license_type: str or ~azure.mgmt.sql.models.DatabaseLicenseType
:keyword read_scale: The state of read-only routing. If enabled, connections that have
application intent set to readonly in their connection string may be routed to a readonly
secondary replica in the same region. Possible values include: "Enabled", "Disabled".
secondary replica in the same region. Not applicable to a Hyperscale database within an elastic
pool. Possible values include: "Enabled", "Disabled".
:paramtype read_scale: str or ~azure.mgmt.sql.models.DatabaseReadScale
:keyword high_availability_replica_count: The number of secondary replicas associated with the
database that are used to provide high availability.
database that are used to provide high availability. Not applicable to a Hyperscale database
within an elastic pool.
:paramtype high_availability_replica_count: int
:keyword secondary_type: The secondary type of the database if it is a secondary. Valid values
are Geo and Named. Possible values include: "Geo", "Named".
Expand All @@ -2633,9 +2671,6 @@ def __init__(
:paramtype is_ledger_on: bool
:keyword federated_client_id: The Client id used for cross tenant per database CMK scenario.
:paramtype federated_client_id: str
:keyword primary_delegated_identity_client_id: The Primary Delegated Identity Client id used
for per database CMK - for internal use only.
:paramtype primary_delegated_identity_client_id: str
"""
super(DatabaseUpdate, self).__init__(**kwargs)
self.sku = sku
Expand Down Expand Up @@ -2679,7 +2714,6 @@ def __init__(
self.is_ledger_on = is_ledger_on
self.is_infra_encryption_enabled = None
self.federated_client_id = federated_client_id
self.primary_delegated_identity_client_id = primary_delegated_identity_client_id


class DatabaseUsage(ProxyResource):
Expand Down Expand Up @@ -3343,41 +3377,6 @@ def __init__(
self.next_link = None


class Delegation(msrest.serialization.Model):
"""Delegated Resource Properties - Internal Use Only.

Variables are only populated by the server, and will be ignored when sending a request.

:ivar resource_id: The resource id of the source resource - Internal Use Only.
:vartype resource_id: str
:ivar tenant_id: AAD tenant guid of the source resource identity - Internal Use Only.
:vartype tenant_id: str
"""

_validation = {
'tenant_id': {'readonly': True},
}

_attribute_map = {
'resource_id': {'key': 'resourceId', 'type': 'str'},
'tenant_id': {'key': 'tenantId', 'type': 'str'},
}

def __init__(
self,
*,
resource_id: Optional[str] = None,
**kwargs
):
"""
:keyword resource_id: The resource id of the source resource - Internal Use Only.
:paramtype resource_id: str
"""
super(Delegation, self).__init__(**kwargs)
self.resource_id = resource_id
self.tenant_id = None


class DeletedServer(ProxyResource):
"""A deleted server.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -279,7 +279,7 @@ class DatabaseLicenseType(with_metaclass(CaseInsensitiveEnumMeta, str, Enum)):
class DatabaseReadScale(with_metaclass(CaseInsensitiveEnumMeta, str, Enum)):
"""The state of read-only routing. If enabled, connections that have application intent set to
readonly in their connection string may be routed to a readonly secondary replica in the same
region.
region. Not applicable to a Hyperscale database within an elastic pool.
"""

ENABLED = "Enabled"
Expand Down
Loading

0 comments on commit 032d955

Please sign in to comment.