Skip to content

Commit

Permalink
CodeGen from PR 32741 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
Merge 88de974f8bc73ef73076d2c3dda0b90d47aaf6ed into bbdbd8545dedd6436b8e30efe45270367389a9b6
  • Loading branch information
SDKAuto committed Feb 22, 2025
1 parent b27efc9 commit f916949
Show file tree
Hide file tree
Showing 49 changed files with 915 additions and 598 deletions.
4 changes: 2 additions & 2 deletions sdk/mongocluster/azure-mgmt-mongocluster/_meta.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"commit": "f93850874010501f216ceadf19459402efd16d9e",
"commit": "6e6db839a67d5a55473c25b848644ffef5ea1980",
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
"typespec_src": "specification/mongocluster/DocumentDB.MongoCluster.Management",
"@azure-tools/typespec-python": "0.33.0"
"@azure-tools/typespec-python": "0.38.4"
}
80 changes: 80 additions & 0 deletions sdk/mongocluster/azure-mgmt-mongocluster/apiview-properties.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
{
"CrossLanguagePackageId": "Microsoft.DocumentDB",
"CrossLanguageDefinitionId": {
"azure.mgmt.mongocluster.models.AdministratorProperties": "Microsoft.DocumentDB.AdministratorProperties",
"azure.mgmt.mongocluster.models.BackupProperties": "Microsoft.DocumentDB.BackupProperties",
"azure.mgmt.mongocluster.models.CheckNameAvailabilityRequest": "Azure.ResourceManager.CommonTypes.CheckNameAvailabilityRequest",
"azure.mgmt.mongocluster.models.CheckNameAvailabilityResponse": "Azure.ResourceManager.CommonTypes.CheckNameAvailabilityResponse",
"azure.mgmt.mongocluster.models.ComputeProperties": "Microsoft.DocumentDB.ComputeProperties",
"azure.mgmt.mongocluster.models.ConnectionString": "Microsoft.DocumentDB.ConnectionString",
"azure.mgmt.mongocluster.models.DataApiProperties": "Microsoft.DocumentDB.DataApiProperties",
"azure.mgmt.mongocluster.models.ErrorAdditionalInfo": "Azure.ResourceManager.CommonTypes.ErrorAdditionalInfo",
"azure.mgmt.mongocluster.models.ErrorDetail": "Azure.ResourceManager.CommonTypes.ErrorDetail",
"azure.mgmt.mongocluster.models.ErrorResponse": "Azure.ResourceManager.CommonTypes.ErrorResponse",
"azure.mgmt.mongocluster.models.Resource": "Azure.ResourceManager.CommonTypes.Resource",
"azure.mgmt.mongocluster.models.ProxyResource": "Azure.ResourceManager.CommonTypes.ProxyResource",
"azure.mgmt.mongocluster.models.FirewallRule": "Microsoft.DocumentDB.FirewallRule",
"azure.mgmt.mongocluster.models.FirewallRuleProperties": "Microsoft.DocumentDB.FirewallRuleProperties",
"azure.mgmt.mongocluster.models.HighAvailabilityProperties": "Microsoft.DocumentDB.HighAvailabilityProperties",
"azure.mgmt.mongocluster.models.ListConnectionStringsResult": "Microsoft.DocumentDB.ListConnectionStringsResult",
"azure.mgmt.mongocluster.models.TrackedResource": "Azure.ResourceManager.CommonTypes.TrackedResource",
"azure.mgmt.mongocluster.models.MongoCluster": "Microsoft.DocumentDB.MongoCluster",
"azure.mgmt.mongocluster.models.MongoClusterProperties": "Microsoft.DocumentDB.MongoClusterProperties",
"azure.mgmt.mongocluster.models.MongoClusterReplicaParameters": "Microsoft.DocumentDB.MongoClusterReplicaParameters",
"azure.mgmt.mongocluster.models.MongoClusterRestoreParameters": "Microsoft.DocumentDB.MongoClusterRestoreParameters",
"azure.mgmt.mongocluster.models.MongoClusterUpdate": "Azure.ResourceManager.Foundations.ResourceUpdateModel",
"azure.mgmt.mongocluster.models.MongoClusterUpdateProperties": "Azure.ResourceManager.Foundations.ResourceUpdateModelProperties",
"azure.mgmt.mongocluster.models.Operation": "Azure.ResourceManager.CommonTypes.Operation",
"azure.mgmt.mongocluster.models.OperationDisplay": "Azure.ResourceManager.CommonTypes.OperationDisplay",
"azure.mgmt.mongocluster.models.PrivateEndpoint": "Azure.ResourceManager.CommonTypes.PrivateEndpoint",
"azure.mgmt.mongocluster.models.PrivateEndpointConnection": "Azure.ResourceManager.CommonTypes.PrivateEndpointConnection",
"azure.mgmt.mongocluster.models.PrivateEndpointConnectionProperties": "Azure.ResourceManager.CommonTypes.PrivateEndpointConnectionProperties",
"azure.mgmt.mongocluster.models.PrivateEndpointConnectionResource": "Microsoft.DocumentDB.PrivateEndpointConnectionResource",
"azure.mgmt.mongocluster.models.PrivateLinkResource": "Microsoft.DocumentDB.PrivateLinkResource",
"azure.mgmt.mongocluster.models.PrivateLinkResourceProperties": "Azure.ResourceManager.CommonTypes.PrivateLinkResourceProperties",
"azure.mgmt.mongocluster.models.PrivateLinkServiceConnectionState": "Azure.ResourceManager.CommonTypes.PrivateLinkServiceConnectionState",
"azure.mgmt.mongocluster.models.PromoteReplicaRequest": "Microsoft.DocumentDB.PromoteReplicaRequest",
"azure.mgmt.mongocluster.models.Replica": "Microsoft.DocumentDB.Replica",
"azure.mgmt.mongocluster.models.ReplicationProperties": "Microsoft.DocumentDB.ReplicationProperties",
"azure.mgmt.mongocluster.models.ShardingProperties": "Microsoft.DocumentDB.ShardingProperties",
"azure.mgmt.mongocluster.models.StorageProperties": "Microsoft.DocumentDB.StorageProperties",
"azure.mgmt.mongocluster.models.SystemData": "Azure.ResourceManager.CommonTypes.SystemData",
"azure.mgmt.mongocluster.models.Origin": "Azure.ResourceManager.CommonTypes.Origin",
"azure.mgmt.mongocluster.models.ActionType": "Azure.ResourceManager.CommonTypes.ActionType",
"azure.mgmt.mongocluster.models.CreatedByType": "Azure.ResourceManager.CommonTypes.createdByType",
"azure.mgmt.mongocluster.models.CreateMode": "Microsoft.DocumentDB.CreateMode",
"azure.mgmt.mongocluster.models.ProvisioningState": "Microsoft.DocumentDB.ProvisioningState",
"azure.mgmt.mongocluster.models.MongoClusterStatus": "Microsoft.DocumentDB.MongoClusterStatus",
"azure.mgmt.mongocluster.models.PublicNetworkAccess": "Microsoft.DocumentDB.PublicNetworkAccess",
"azure.mgmt.mongocluster.models.HighAvailabilityMode": "Microsoft.DocumentDB.HighAvailabilityMode",
"azure.mgmt.mongocluster.models.DataApiMode": "Microsoft.DocumentDB.DataApiMode",
"azure.mgmt.mongocluster.models.PrivateEndpointServiceConnectionStatus": "Azure.ResourceManager.CommonTypes.PrivateEndpointServiceConnectionStatus",
"azure.mgmt.mongocluster.models.PrivateEndpointConnectionProvisioningState": "Azure.ResourceManager.CommonTypes.PrivateEndpointConnectionProvisioningState",
"azure.mgmt.mongocluster.models.PreviewFeature": "Microsoft.DocumentDB.PreviewFeature",
"azure.mgmt.mongocluster.models.ReplicationRole": "Microsoft.DocumentDB.ReplicationRole",
"azure.mgmt.mongocluster.models.ReplicationState": "Microsoft.DocumentDB.ReplicationState",
"azure.mgmt.mongocluster.models.CheckNameAvailabilityReason": "Azure.ResourceManager.CommonTypes.CheckNameAvailabilityReason",
"azure.mgmt.mongocluster.models.PromoteOption": "Microsoft.DocumentDB.PromoteOption",
"azure.mgmt.mongocluster.models.PromoteMode": "Microsoft.DocumentDB.PromoteMode",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.operations.list": "Azure.ResourceManager.Operations.list",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.mongo_clusters.get": "Microsoft.DocumentDB.MongoClusters.get",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.mongo_clusters.begin_create_or_update": "Microsoft.DocumentDB.MongoClusters.createOrUpdate",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.mongo_clusters.begin_update": "Microsoft.DocumentDB.MongoClusters.update",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.mongo_clusters.begin_delete": "Microsoft.DocumentDB.MongoClusters.delete",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.mongo_clusters.list_by_resource_group": "Microsoft.DocumentDB.MongoClusters.listByResourceGroup",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.mongo_clusters.list": "Microsoft.DocumentDB.MongoClusters.list",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.mongo_clusters.list_connection_strings": "Microsoft.DocumentDB.MongoClusters.listConnectionStrings",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.mongo_clusters.check_name_availability": "Microsoft.DocumentDB.MongoClusters.checkNameAvailability",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.mongo_clusters.begin_promote": "Microsoft.DocumentDB.MongoClusters.promote",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.firewall_rules.get": "Microsoft.DocumentDB.FirewallRules.get",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.firewall_rules.begin_create_or_update": "Microsoft.DocumentDB.FirewallRules.createOrUpdate",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.firewall_rules.begin_delete": "Microsoft.DocumentDB.FirewallRules.delete",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.firewall_rules.list_by_mongo_cluster": "Microsoft.DocumentDB.FirewallRules.listByMongoCluster",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.private_endpoint_connections.list_by_mongo_cluster": "Microsoft.DocumentDB.PrivateEndpointConnections.listByMongoCluster",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.private_endpoint_connections.get": "Microsoft.DocumentDB.PrivateEndpointConnections.get",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.private_endpoint_connections.begin_create": "Microsoft.DocumentDB.PrivateEndpointConnections.create",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.private_endpoint_connections.begin_delete": "Microsoft.DocumentDB.PrivateEndpointConnections.delete",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.private_links.list_by_mongo_cluster": "Microsoft.DocumentDB.PrivateLinks.listByMongoCluster",
"azure.mgmt.mongocluster.MongoClusterMgmtClient.replicas.list_by_parent": "Microsoft.DocumentDB.Replicas.listByParent"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,28 @@
# Code generated by Microsoft (R) Python Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------
# pylint: disable=wrong-import-position

from ._client import MongoClusterMgmtClient
from typing import TYPE_CHECKING

if TYPE_CHECKING:
from ._patch import * # pylint: disable=unused-wildcard-import

from ._client import MongoClusterMgmtClient # type: ignore
from ._version import VERSION

__version__ = VERSION

try:
from ._patch import __all__ as _patch_all
from ._patch import * # pylint: disable=unused-wildcard-import
from ._patch import *
except ImportError:
_patch_all = []
from ._patch import patch_sdk as _patch_sdk

__all__ = [
"MongoClusterMgmtClient",
]
__all__.extend([p for p in _patch_all if p not in __all__])
__all__.extend([p for p in _patch_all if p not in __all__]) # pyright: ignore

_patch_sdk()
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,10 @@
)

if TYPE_CHECKING:
# pylint: disable=unused-import,ungrouped-imports
from azure.core.credentials import TokenCredential


class MongoClusterMgmtClient: # pylint: disable=client-accepts-api-version-keyword
class MongoClusterMgmtClient:
"""The Microsoft Azure management API provides create, read, update, and delete functionality for
Azure Cosmos DB for MongoDB vCore resources including clusters and firewall rules.
Expand All @@ -54,8 +53,9 @@ class MongoClusterMgmtClient: # pylint: disable=client-accepts-api-version-keyw
:type subscription_id: str
:param base_url: Service host. Default value is "https://management.azure.com".
:type base_url: str
:keyword api_version: The API version to use for this operation. Default value is "2024-07-01".
Note that overriding this default value may result in unsupported behavior.
:keyword api_version: The API version to use for this operation. Default value is
"2024-10-01-preview". Note that overriding this default value may result in unsupported
behavior.
:paramtype api_version: str
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no
Retry-After header is present.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,10 @@
from ._version import VERSION

if TYPE_CHECKING:
# pylint: disable=unused-import,ungrouped-imports
from azure.core.credentials import TokenCredential


class MongoClusterMgmtClientConfiguration: # pylint: disable=too-many-instance-attributes,name-too-long
class MongoClusterMgmtClientConfiguration: # pylint: disable=too-many-instance-attributes
"""Configuration for MongoClusterMgmtClient.
Note that all parameters used to create this instance are saved as instance
Expand All @@ -30,8 +29,9 @@ class MongoClusterMgmtClientConfiguration: # pylint: disable=too-many-instance-
:type subscription_id: str
:param base_url: Service host. Default value is "https://management.azure.com".
:type base_url: str
:keyword api_version: The API version to use for this operation. Default value is "2024-07-01".
Note that overriding this default value may result in unsupported behavior.
:keyword api_version: The API version to use for this operation. Default value is
"2024-10-01-preview". Note that overriding this default value may result in unsupported
behavior.
:paramtype api_version: str
"""

Expand All @@ -42,7 +42,7 @@ def __init__(
base_url: str = "https://management.azure.com",
**kwargs: Any
) -> None:
api_version: str = kwargs.pop("api_version", "2024-07-01")
api_version: str = kwargs.pop("api_version", "2024-10-01-preview")

if credential is None:
raise ValueError("Parameter 'credential' must not be None.")
Expand Down
Loading

0 comments on commit f916949

Please sign in to comment.