From ce9add8fb65e2cf1e610483346a59f49edbbb074 Mon Sep 17 00:00:00 2001 From: Wei Wei Date: Wed, 19 Feb 2025 09:11:11 +0800 Subject: [PATCH] [Storage] Support SRP new API version 2024-01-01 (#48213) --- .../CHANGELOG.md | 14 +- .../Azure.ResourceManager.Storage.net8.0.cs | 171 ++++- ....ResourceManager.Storage.netstandard2.0.cs | 171 ++++- .../Azure.ResourceManager.Storage/assets.json | 2 +- .../Samples/Sample_BlobContainerCollection.cs | 22 +- .../Samples/Sample_BlobContainerResource.cs | 20 +- .../Sample_BlobInventoryPolicyResource.cs | 10 +- .../Samples/Sample_BlobServiceResource.cs | 8 +- .../Sample_DeletedAccountCollection.cs | 6 +- .../Samples/Sample_DeletedAccountResource.cs | 2 +- .../Sample_EncryptionScopeCollection.cs | 12 +- .../Samples/Sample_EncryptionScopeResource.cs | 4 +- .../Samples/Sample_FileServiceResource.cs | 8 +- .../Sample_FileServiceUsageResource.cs | 48 ++ .../Samples/Sample_FileShareCollection.cs | 393 ++++++++++- .../Samples/Sample_FileShareResource.cs | 155 +++- .../Sample_ImmutabilityPolicyResource.cs | 12 +- ...ecurityPerimeterConfigurationCollection.cs | 8 +- ...kSecurityPerimeterConfigurationResource.cs | 4 +- ...ample_ObjectReplicationPolicyCollection.cs | 20 +- .../Sample_ObjectReplicationPolicyResource.cs | 16 +- .../Samples/Sample_QueueServiceResource.cs | 4 +- .../Sample_StorageAccountCollection.cs | 62 +- ...ample_StorageAccountLocalUserCollection.cs | 16 +- .../Sample_StorageAccountLocalUserResource.cs | 14 +- ..._StorageAccountManagementPolicyResource.cs | 20 +- ...ample_StorageAccountMigrationCollection.cs | 12 +- .../Sample_StorageAccountMigrationResource.cs | 4 +- .../Samples/Sample_StorageAccountResource.cs | 58 +- ...ragePrivateEndpointConnectionCollection.cs | 10 +- ...toragePrivateEndpointConnectionResource.cs | 6 +- .../Samples/Sample_StorageQueueCollection.cs | 12 +- .../Samples/Sample_StorageQueueResource.cs | 6 +- .../Sample_StorageTaskAssignmentCollection.cs | 12 +- .../Sample_StorageTaskAssignmentResource.cs | 8 +- .../Sample_SubscriptionResourceExtensions.cs | 10 +- .../Samples/Sample_TableCollection.cs | 12 +- .../Generated/Samples/Sample_TableResource.cs | 8 +- .../Samples/Sample_TableServiceResource.cs | 4 +- .../src/Azure.ResourceManager.Storage.csproj | 2 +- .../src/Generated/ArmStorageModelFactory.cs | 180 ++++- .../src/Generated/BlobContainerCollection.cs | 20 +- .../src/Generated/BlobContainerResource.cs | 28 +- .../Generated/BlobInventoryPolicyResource.cs | 12 +- .../src/Generated/BlobServiceResource.cs | 12 +- .../src/Generated/DeletedAccountCollection.cs | 12 +- .../src/Generated/DeletedAccountResource.cs | 4 +- .../Generated/EncryptionScopeCollection.cs | 20 +- .../src/Generated/EncryptionScopeResource.cs | 8 +- .../Extensions/MockableStorageArmClient.cs | 12 + .../MockableStorageResourceGroupResource.cs | 4 +- .../MockableStorageSubscriptionResource.cs | 24 +- .../Generated/Extensions/StorageExtensions.cs | 47 +- .../src/Generated/FileServiceResource.cs | 19 +- .../FileServiceUsageData.Serialization.cs | 241 +++++++ .../src/Generated/FileServiceUsageData.cs | 76 ++ .../FileServiceUsageResource.Serialization.cs | 26 + .../src/Generated/FileServiceUsageResource.cs | 170 +++++ .../src/Generated/FileShareCollection.cs | 20 +- .../Generated/FileShareData.Serialization.cs | 251 +++++++ .../src/Generated/FileShareData.cs | 46 +- .../src/Generated/FileShareResource.cs | 20 +- .../Generated/ImmutabilityPolicyResource.cs | 40 +- .../Models/BurstingConstants.Serialization.cs | 226 ++++++ .../src/Generated/Models/BurstingConstants.cs | 76 ++ .../FileServiceAccountLimits.Serialization.cs | 256 +++++++ .../Models/FileServiceAccountLimits.cs | 81 +++ .../FileServiceAccountUsage.Serialization.cs | 196 +++++ .../Models/FileServiceAccountUsage.cs | 71 ++ ...rviceAccountUsageElements.Serialization.cs | 256 +++++++ .../Models/FileServiceAccountUsageElements.cs | 81 +++ ...ileServiceUsageProperties.Serialization.cs | 292 ++++++++ .../Models/FileServiceUsageProperties.cs | 86 +++ .../Models/FileServiceUsages.Serialization.cs | 219 ++++++ .../src/Generated/Models/FileServiceUsages.cs | 70 ++ .../Models/FileShareLimits.Serialization.cs | 323 +++++++++ .../src/Generated/Models/FileShareLimits.cs | 91 +++ ...tiesFileSharePaidBursting.Serialization.cs | 227 ++++++ ...ileSharePropertiesFileSharePaidBursting.cs | 76 ++ .../FileShareRecommendations.Serialization.cs | 256 +++++++ .../Models/FileShareRecommendations.cs | 81 +++ ...onPolicyPropertiesMetrics.Serialization.cs | 167 +++++ ...bjectReplicationPolicyPropertiesMetrics.cs | 66 ++ .../src/Generated/Models/StorageSkuName.cs | 18 + ...ecurityPerimeterConfigurationCollection.cs | 16 +- ...kSecurityPerimeterConfigurationResource.cs | 8 +- .../ObjectReplicationPolicyCollection.cs | 20 +- ...jectReplicationPolicyData.Serialization.cs | 36 + .../Generated/ObjectReplicationPolicyData.cs | 18 +- .../ObjectReplicationPolicyResource.cs | 12 +- .../src/Generated/QueueServiceResource.cs | 12 +- .../BlobContainersRestOperations.cs | 22 +- .../BlobInventoryPoliciesRestOperations.cs | 2 +- .../BlobServicesRestOperations.cs | 2 +- .../DeletedAccountsRestOperations.cs | 2 +- .../EncryptionScopesRestOperations.cs | 2 +- .../FileServicesRestOperations.cs | 300 +++++++- .../FileSharesRestOperations.cs | 2 +- .../LocalUsersRestOperations.cs | 2 +- .../ManagementPoliciesRestOperations.cs | 2 +- ...tyPerimeterConfigurationsRestOperations.cs | 2 +- ...ObjectReplicationPoliciesRestOperations.cs | 2 +- ...rivateEndpointConnectionsRestOperations.cs | 2 +- .../PrivateLinkResourcesRestOperations.cs | 2 +- .../RestOperations/QueueRestOperations.cs | 2 +- .../QueueServicesRestOperations.cs | 2 +- .../RestOperations/SkusRestOperations.cs | 2 +- .../StorageAccountsRestOperations.cs | 2 +- ...AssignmentInstancesReportRestOperations.cs | 2 +- ...ssignmentsInstancesReportRestOperations.cs | 2 +- .../StorageTaskAssignmentsRestOperations.cs | 2 +- .../RestOperations/TableRestOperations.cs | 2 +- .../TableServicesRestOperations.cs | 2 +- .../RestOperations/UsagesRestOperations.cs | 2 +- .../src/Generated/StorageAccountCollection.cs | 20 +- .../StorageAccountLocalUserCollection.cs | 20 +- .../StorageAccountLocalUserResource.cs | 20 +- .../StorageAccountManagementPolicyResource.cs | 12 +- .../StorageAccountMigrationCollection.cs | 12 +- .../StorageAccountMigrationResource.cs | 4 +- .../src/Generated/StorageAccountResource.cs | 96 +-- ...ragePrivateEndpointConnectionCollection.cs | 20 +- ...toragePrivateEndpointConnectionResource.cs | 12 +- .../src/Generated/StorageQueueCollection.cs | 20 +- .../src/Generated/StorageQueueResource.cs | 12 +- .../StorageTaskAssignmentCollection.cs | 20 +- .../StorageTaskAssignmentResource.cs | 16 +- .../src/Generated/TableCollection.cs | 20 +- .../src/Generated/TableResource.cs | 12 +- .../src/Generated/TableServiceResource.cs | 12 +- .../src/autorest.md | 668 +++++++++--------- .../tests/Tests/BlobContainerTests.cs | 3 + .../tests/Tests/FileShareTests.cs | 156 ++++ 133 files changed, 6588 insertions(+), 946 deletions(-) create mode 100644 sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileServiceUsageResource.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageData.Serialization.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageData.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageResource.Serialization.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageResource.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/BurstingConstants.Serialization.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/BurstingConstants.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountLimits.Serialization.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountLimits.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsage.Serialization.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsage.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsageElements.Serialization.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsageElements.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsageProperties.Serialization.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsageProperties.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsages.Serialization.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsages.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareLimits.Serialization.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareLimits.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileSharePropertiesFileSharePaidBursting.Serialization.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileSharePropertiesFileSharePaidBursting.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareRecommendations.Serialization.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareRecommendations.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/ObjectReplicationPolicyPropertiesMetrics.Serialization.cs create mode 100644 sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/ObjectReplicationPolicyPropertiesMetrics.cs diff --git a/sdk/storage/Azure.ResourceManager.Storage/CHANGELOG.md b/sdk/storage/Azure.ResourceManager.Storage/CHANGELOG.md index 50e8d5858d32..ac5326a89f60 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/CHANGELOG.md +++ b/sdk/storage/Azure.ResourceManager.Storage/CHANGELOG.md @@ -1,17 +1,17 @@ # Release History -## 1.4.0-beta.1 (Unreleased) +## 1.4.0 (2025-02-18) ### Features Added +- Upgraded api-version tag from 'package-2023-05' to 'package-2024-01'. Tag detail available at https://github.com/Azure/azure-rest-api-specs/blob/982bec06ab5076c1e91935640a09a15857761b66/specification/storage/resource-manager/readme.md. + - Supported new Storage Account Sku: "StandardV2_LRS", "StandardV2_GRS", "StandardV2_ZRS", "StandardV2_GZRS", "PremiumV2_LRS", "PremiumV2_ZRS". + - Supported Get File Service Usage on Files Provisioned v2 account type. + - Supported new File Share properties on Files Provisioned v2 account type: editable properties: "provisionedIops", "provisionedBandwidthMibps"; readonly properties: "includedBurstIops", "maxBurstCreditsForIops","nextAllowedQuotaDowngradeTime", "nextAllowedProvisionedIopsDowngradeTime", "nextAllowedProvisionedBandwidthDowngradeTime". + - Supported new File Share properties on Files Provisioned v1 SSD account type: "fileSharePaidBursting", which include child properties "paidBurstingMaxIops", "paidBurstingMaxIops", "paidBurstingMaxBandwidthMibps". + - Supported new ObjectReplicationPolicy Properties: "metrics.enabled". - Exposed `JsonModelWriteCore` for model serialization procedure. -### Breaking Changes - -### Bugs Fixed - -### Other Changes - ## 1.3.0 (2024-06-28) ### Features Added diff --git a/sdk/storage/Azure.ResourceManager.Storage/api/Azure.ResourceManager.Storage.net8.0.cs b/sdk/storage/Azure.ResourceManager.Storage/api/Azure.ResourceManager.Storage.net8.0.cs index 41966cf11ed0..f31e45a1c584 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/api/Azure.ResourceManager.Storage.net8.0.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/api/Azure.ResourceManager.Storage.net8.0.cs @@ -267,6 +267,7 @@ protected FileServiceResource() { } public static Azure.Core.ResourceIdentifier CreateResourceIdentifier(string subscriptionId, string resourceGroupName, string accountName) { throw null; } public virtual Azure.Response Get(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.ResourceManager.Storage.FileServiceUsageResource GetFileServiceUsage() { throw null; } public virtual Azure.Response GetFileShare(string shareName, string expand = null, string xMsSnapshot = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetFileShareAsync(string shareName, string expand = null, string xMsSnapshot = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.Storage.FileShareCollection GetFileShares() { throw null; } @@ -276,6 +277,32 @@ protected FileServiceResource() { } string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class FileServiceUsageData : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public FileServiceUsageData() { } + public Azure.ResourceManager.Storage.Models.FileServiceUsageProperties Properties { get { throw null; } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.FileServiceUsageData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.FileServiceUsageData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class FileServiceUsageResource : Azure.ResourceManager.ArmResource, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public static readonly Azure.Core.ResourceType ResourceType; + protected FileServiceUsageResource() { } + public virtual Azure.ResourceManager.Storage.FileServiceUsageData Data { get { throw null; } } + public virtual bool HasData { get { throw null; } } + public static Azure.Core.ResourceIdentifier CreateResourceIdentifier(string subscriptionId, string resourceGroupName, string accountName) { throw null; } + public virtual Azure.Response Get(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + Azure.ResourceManager.Storage.FileServiceUsageData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.FileServiceUsageData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class FileShareCollection : Azure.ResourceManager.ArmCollection, System.Collections.Generic.IAsyncEnumerable, System.Collections.Generic.IEnumerable, System.Collections.IEnumerable { protected FileShareCollection() { } @@ -304,12 +331,20 @@ public FileShareData() { } public System.DateTimeOffset? DeletedOn { get { throw null; } } public Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol? EnabledProtocol { get { throw null; } set { } } public Azure.ETag? ETag { get { throw null; } } + public Azure.ResourceManager.Storage.Models.FileSharePropertiesFileSharePaidBursting FileSharePaidBursting { get { throw null; } set { } } + public int? IncludedBurstIops { get { throw null; } } public bool? IsDeleted { get { throw null; } } public System.DateTimeOffset? LastModifiedOn { get { throw null; } } public Azure.ResourceManager.Storage.Models.StorageLeaseDurationType? LeaseDuration { get { throw null; } } public Azure.ResourceManager.Storage.Models.StorageLeaseState? LeaseState { get { throw null; } } public Azure.ResourceManager.Storage.Models.StorageLeaseStatus? LeaseStatus { get { throw null; } } + public long? MaxBurstCreditsForIops { get { throw null; } } public System.Collections.Generic.IDictionary Metadata { get { throw null; } } + public System.DateTimeOffset? NextAllowedProvisionedBandwidthDowngradeOn { get { throw null; } } + public System.DateTimeOffset? NextAllowedProvisionedIopsDowngradeOn { get { throw null; } } + public System.DateTimeOffset? NextAllowedQuotaDowngradeOn { get { throw null; } } + public int? ProvisionedBandwidthMibps { get { throw null; } set { } } + public int? ProvisionedIops { get { throw null; } set { } } public int? RemainingRetentionDays { get { throw null; } } public Azure.ResourceManager.Storage.Models.RootSquashType? RootSquash { get { throw null; } set { } } public int? ShareQuota { get { throw null; } set { } } @@ -454,6 +489,7 @@ public partial class ObjectReplicationPolicyData : Azure.ResourceManager.Models. public ObjectReplicationPolicyData() { } public string DestinationAccount { get { throw null; } set { } } public System.DateTimeOffset? EnabledOn { get { throw null; } } + public bool? IsMetricsEnabled { get { throw null; } set { } } public string PolicyId { get { throw null; } } public System.Collections.Generic.IList Rules { get { throw null; } } public string SourceAccount { get { throw null; } set { } } @@ -836,6 +872,7 @@ public static partial class StorageExtensions public static Azure.AsyncPageable GetDeletedAccountsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Storage.EncryptionScopeResource GetEncryptionScopeResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Storage.FileServiceResource GetFileServiceResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } + public static Azure.ResourceManager.Storage.FileServiceUsageResource GetFileServiceUsageResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Storage.FileShareResource GetFileShareResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Storage.ImmutabilityPolicyResource GetImmutabilityPolicyResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Storage.NetworkSecurityPerimeterConfigurationResource GetNetworkSecurityPerimeterConfigurationResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } @@ -1099,6 +1136,7 @@ protected MockableStorageArmClient() { } public virtual Azure.ResourceManager.Storage.DeletedAccountResource GetDeletedAccountResource(Azure.Core.ResourceIdentifier id) { throw null; } public virtual Azure.ResourceManager.Storage.EncryptionScopeResource GetEncryptionScopeResource(Azure.Core.ResourceIdentifier id) { throw null; } public virtual Azure.ResourceManager.Storage.FileServiceResource GetFileServiceResource(Azure.Core.ResourceIdentifier id) { throw null; } + public virtual Azure.ResourceManager.Storage.FileServiceUsageResource GetFileServiceUsageResource(Azure.Core.ResourceIdentifier id) { throw null; } public virtual Azure.ResourceManager.Storage.FileShareResource GetFileShareResource(Azure.Core.ResourceIdentifier id) { throw null; } public virtual Azure.ResourceManager.Storage.ImmutabilityPolicyResource GetImmutabilityPolicyResource(Azure.Core.ResourceIdentifier id) { throw null; } public virtual Azure.ResourceManager.Storage.NetworkSecurityPerimeterConfigurationResource GetNetworkSecurityPerimeterConfigurationResource(Azure.Core.ResourceIdentifier id) { throw null; } @@ -1236,11 +1274,21 @@ public static partial class ArmStorageModelFactory public static Azure.ResourceManager.Storage.Models.BlobInventoryPolicySchema BlobInventoryPolicySchema(bool isEnabled = false, string destination = null, Azure.ResourceManager.Storage.Models.BlobInventoryRuleType ruleType = default(Azure.ResourceManager.Storage.Models.BlobInventoryRuleType), System.Collections.Generic.IEnumerable rules = null) { throw null; } public static Azure.ResourceManager.Storage.Models.BlobRestoreStatus BlobRestoreStatus(Azure.ResourceManager.Storage.Models.BlobRestoreProgressStatus? status = default(Azure.ResourceManager.Storage.Models.BlobRestoreProgressStatus?), string failureReason = null, string restoreId = null, Azure.ResourceManager.Storage.Models.BlobRestoreContent parameters = null) { throw null; } public static Azure.ResourceManager.Storage.BlobServiceData BlobServiceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Storage.Models.StorageSku sku = null, System.Collections.Generic.IEnumerable corsRules = null, string defaultServiceVersion = null, Azure.ResourceManager.Storage.Models.DeleteRetentionPolicy deleteRetentionPolicy = null, bool? isVersioningEnabled = default(bool?), bool? isAutomaticSnapshotPolicyEnabled = default(bool?), Azure.ResourceManager.Storage.Models.BlobServiceChangeFeed changeFeed = null, Azure.ResourceManager.Storage.Models.RestorePolicy restorePolicy = null, Azure.ResourceManager.Storage.Models.DeleteRetentionPolicy containerDeleteRetentionPolicy = null, Azure.ResourceManager.Storage.Models.LastAccessTimeTrackingPolicy lastAccessTimeTrackingPolicy = null) { throw null; } + public static Azure.ResourceManager.Storage.Models.BurstingConstants BurstingConstants(int? burstFloorIops = default(int?), double? burstIOScalar = default(double?), int? burstTimeframeSeconds = default(int?)) { throw null; } public static Azure.ResourceManager.Storage.DeletedAccountData DeletedAccountData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.Core.ResourceIdentifier storageAccountResourceId = null, Azure.Core.AzureLocation? location = default(Azure.Core.AzureLocation?), string restoreReference = null, System.DateTimeOffset? createdOn = default(System.DateTimeOffset?), System.DateTimeOffset? deletedOn = default(System.DateTimeOffset?)) { throw null; } public static Azure.ResourceManager.Storage.EncryptionScopeData EncryptionScopeData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Storage.Models.EncryptionScopeSource? source = default(Azure.ResourceManager.Storage.Models.EncryptionScopeSource?), Azure.ResourceManager.Storage.Models.EncryptionScopeState? state = default(Azure.ResourceManager.Storage.Models.EncryptionScopeState?), System.DateTimeOffset? createdOn = default(System.DateTimeOffset?), System.DateTimeOffset? lastModifiedOn = default(System.DateTimeOffset?), Azure.ResourceManager.Storage.Models.EncryptionScopeKeyVaultProperties keyVaultProperties = null, bool? requireInfrastructureEncryption = default(bool?)) { throw null; } public static Azure.ResourceManager.Storage.Models.EncryptionScopeKeyVaultProperties EncryptionScopeKeyVaultProperties(System.Uri keyUri = null, string currentVersionedKeyIdentifier = null, System.DateTimeOffset? lastKeyRotationTimestamp = default(System.DateTimeOffset?)) { throw null; } + public static Azure.ResourceManager.Storage.Models.FileServiceAccountLimits FileServiceAccountLimits(int? maxFileShares = default(int?), int? maxProvisionedStorageGiB = default(int?), int? maxProvisionedIops = default(int?), int? maxProvisionedBandwidthMiBPerSec = default(int?)) { throw null; } + public static Azure.ResourceManager.Storage.Models.FileServiceAccountUsage FileServiceAccountUsage(Azure.ResourceManager.Storage.Models.FileServiceAccountUsageElements liveShares = null, Azure.ResourceManager.Storage.Models.FileServiceAccountUsageElements softDeletedShares = null) { throw null; } + public static Azure.ResourceManager.Storage.Models.FileServiceAccountUsageElements FileServiceAccountUsageElements(int? fileShareCount = default(int?), int? provisionedStorageGiB = default(int?), int? provisionedIops = default(int?), int? provisionedBandwidthMiBPerSec = default(int?)) { throw null; } public static Azure.ResourceManager.Storage.FileServiceData FileServiceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Storage.Models.StorageSku sku = null, System.Collections.Generic.IEnumerable corsRules = null, Azure.ResourceManager.Storage.Models.DeleteRetentionPolicy shareDeleteRetentionPolicy = null, Azure.ResourceManager.Storage.Models.SmbSetting protocolSmbSetting = null) { throw null; } - public static Azure.ResourceManager.Storage.FileShareData FileShareData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, System.DateTimeOffset? lastModifiedOn = default(System.DateTimeOffset?), System.Collections.Generic.IDictionary metadata = null, int? shareQuota = default(int?), Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol? enabledProtocol = default(Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol?), Azure.ResourceManager.Storage.Models.RootSquashType? rootSquash = default(Azure.ResourceManager.Storage.Models.RootSquashType?), string version = null, bool? isDeleted = default(bool?), System.DateTimeOffset? deletedOn = default(System.DateTimeOffset?), int? remainingRetentionDays = default(int?), Azure.ResourceManager.Storage.Models.FileShareAccessTier? accessTier = default(Azure.ResourceManager.Storage.Models.FileShareAccessTier?), System.DateTimeOffset? accessTierChangeOn = default(System.DateTimeOffset?), string accessTierStatus = null, long? shareUsageBytes = default(long?), Azure.ResourceManager.Storage.Models.StorageLeaseStatus? leaseStatus = default(Azure.ResourceManager.Storage.Models.StorageLeaseStatus?), Azure.ResourceManager.Storage.Models.StorageLeaseState? leaseState = default(Azure.ResourceManager.Storage.Models.StorageLeaseState?), Azure.ResourceManager.Storage.Models.StorageLeaseDurationType? leaseDuration = default(Azure.ResourceManager.Storage.Models.StorageLeaseDurationType?), System.Collections.Generic.IEnumerable signedIdentifiers = null, System.DateTimeOffset? snapshotOn = default(System.DateTimeOffset?), Azure.ETag? etag = default(Azure.ETag?)) { throw null; } + public static Azure.ResourceManager.Storage.FileServiceUsageData FileServiceUsageData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Storage.Models.FileServiceUsageProperties properties = null) { throw null; } + public static Azure.ResourceManager.Storage.Models.FileServiceUsageProperties FileServiceUsageProperties(Azure.ResourceManager.Storage.Models.FileServiceAccountLimits storageAccountLimits = null, Azure.ResourceManager.Storage.Models.FileShareLimits fileShareLimits = null, Azure.ResourceManager.Storage.Models.FileShareRecommendations fileShareRecommendations = null, Azure.ResourceManager.Storage.Models.BurstingConstants burstingConstants = null, Azure.ResourceManager.Storage.Models.FileServiceAccountUsage storageAccountUsage = null) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public static Azure.ResourceManager.Storage.FileShareData FileShareData(Azure.Core.ResourceIdentifier id, string name, Azure.Core.ResourceType resourceType, Azure.ResourceManager.Models.SystemData systemData, System.DateTimeOffset? lastModifiedOn, System.Collections.Generic.IDictionary metadata, int? shareQuota, Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol? enabledProtocol, Azure.ResourceManager.Storage.Models.RootSquashType? rootSquash, string version, bool? isDeleted, System.DateTimeOffset? deletedOn, int? remainingRetentionDays, Azure.ResourceManager.Storage.Models.FileShareAccessTier? accessTier, System.DateTimeOffset? accessTierChangeOn, string accessTierStatus, long? shareUsageBytes, Azure.ResourceManager.Storage.Models.StorageLeaseStatus? leaseStatus, Azure.ResourceManager.Storage.Models.StorageLeaseState? leaseState, Azure.ResourceManager.Storage.Models.StorageLeaseDurationType? leaseDuration, System.Collections.Generic.IEnumerable signedIdentifiers, System.DateTimeOffset? snapshotOn, Azure.ETag? etag) { throw null; } + public static Azure.ResourceManager.Storage.FileShareData FileShareData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, System.DateTimeOffset? lastModifiedOn = default(System.DateTimeOffset?), System.Collections.Generic.IDictionary metadata = null, int? shareQuota = default(int?), int? provisionedIops = default(int?), int? provisionedBandwidthMibps = default(int?), int? includedBurstIops = default(int?), long? maxBurstCreditsForIops = default(long?), System.DateTimeOffset? nextAllowedQuotaDowngradeOn = default(System.DateTimeOffset?), System.DateTimeOffset? nextAllowedProvisionedIopsDowngradeOn = default(System.DateTimeOffset?), System.DateTimeOffset? nextAllowedProvisionedBandwidthDowngradeOn = default(System.DateTimeOffset?), Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol? enabledProtocol = default(Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol?), Azure.ResourceManager.Storage.Models.RootSquashType? rootSquash = default(Azure.ResourceManager.Storage.Models.RootSquashType?), string version = null, bool? isDeleted = default(bool?), System.DateTimeOffset? deletedOn = default(System.DateTimeOffset?), int? remainingRetentionDays = default(int?), Azure.ResourceManager.Storage.Models.FileShareAccessTier? accessTier = default(Azure.ResourceManager.Storage.Models.FileShareAccessTier?), System.DateTimeOffset? accessTierChangeOn = default(System.DateTimeOffset?), string accessTierStatus = null, long? shareUsageBytes = default(long?), Azure.ResourceManager.Storage.Models.StorageLeaseStatus? leaseStatus = default(Azure.ResourceManager.Storage.Models.StorageLeaseStatus?), Azure.ResourceManager.Storage.Models.StorageLeaseState? leaseState = default(Azure.ResourceManager.Storage.Models.StorageLeaseState?), Azure.ResourceManager.Storage.Models.StorageLeaseDurationType? leaseDuration = default(Azure.ResourceManager.Storage.Models.StorageLeaseDurationType?), System.Collections.Generic.IEnumerable signedIdentifiers = null, System.DateTimeOffset? snapshotOn = default(System.DateTimeOffset?), Azure.ResourceManager.Storage.Models.FileSharePropertiesFileSharePaidBursting fileSharePaidBursting = null, Azure.ETag? etag = default(Azure.ETag?)) { throw null; } + public static Azure.ResourceManager.Storage.Models.FileShareLimits FileShareLimits(int? minProvisionedStorageGiB = default(int?), int? maxProvisionedStorageGiB = default(int?), int? minProvisionedIops = default(int?), int? maxProvisionedIops = default(int?), int? minProvisionedBandwidthMiBPerSec = default(int?), int? maxProvisionedBandwidthMiBPerSec = default(int?)) { throw null; } + public static Azure.ResourceManager.Storage.Models.FileShareRecommendations FileShareRecommendations(int? baseIops = default(int?), double? ioScalar = default(double?), int? baseBandwidthMiBPerSec = default(int?), double? bandwidthScalar = default(double?)) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public static Azure.ResourceManager.Storage.Models.GeoReplicationStatistics GeoReplicationStatistics(Azure.ResourceManager.Storage.Models.GeoReplicationStatus? status, System.DateTimeOffset? lastSyncOn, bool? canFailover) { throw null; } public static Azure.ResourceManager.Storage.Models.GeoReplicationStatistics GeoReplicationStatistics(Azure.ResourceManager.Storage.Models.GeoReplicationStatus? status = default(Azure.ResourceManager.Storage.Models.GeoReplicationStatus?), System.DateTimeOffset? lastSyncOn = default(System.DateTimeOffset?), bool? canFailover = default(bool?), bool? canPlannedFailover = default(bool?), Azure.ResourceManager.Storage.Models.PostFailoverRedundancy? postFailoverRedundancy = default(Azure.ResourceManager.Storage.Models.PostFailoverRedundancy?), Azure.ResourceManager.Storage.Models.PostPlannedFailoverRedundancy? postPlannedFailoverRedundancy = default(Azure.ResourceManager.Storage.Models.PostPlannedFailoverRedundancy?)) { throw null; } @@ -1265,7 +1313,9 @@ public static partial class ArmStorageModelFactory public static Azure.ResourceManager.Storage.Models.NetworkSecurityPerimeterProvisioningIssueProperties NetworkSecurityPerimeterProvisioningIssueProperties(Azure.ResourceManager.Storage.Models.NetworkSecurityPerimeterProvisioningIssueType? issueType = default(Azure.ResourceManager.Storage.Models.NetworkSecurityPerimeterProvisioningIssueType?), Azure.ResourceManager.Storage.Models.NetworkSecurityPerimeterProvisioningIssueSeverity? severity = default(Azure.ResourceManager.Storage.Models.NetworkSecurityPerimeterProvisioningIssueSeverity?), string description = null) { throw null; } public static Azure.ResourceManager.Storage.Models.NspAccessRule NspAccessRule(string name = null, Azure.ResourceManager.Storage.Models.NspAccessRuleProperties properties = null) { throw null; } public static Azure.ResourceManager.Storage.Models.NspAccessRuleProperties NspAccessRuleProperties(Azure.ResourceManager.Storage.Models.NspAccessRuleDirection? direction = default(Azure.ResourceManager.Storage.Models.NspAccessRuleDirection?), System.Collections.Generic.IEnumerable addressPrefixes = null, System.Collections.Generic.IEnumerable subscriptions = null, System.Collections.Generic.IEnumerable networkSecurityPerimeters = null, System.Collections.Generic.IEnumerable fullyQualifiedDomainNames = null) { throw null; } - public static Azure.ResourceManager.Storage.ObjectReplicationPolicyData ObjectReplicationPolicyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, string policyId = null, System.DateTimeOffset? enabledOn = default(System.DateTimeOffset?), string sourceAccount = null, string destinationAccount = null, System.Collections.Generic.IEnumerable rules = null) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public static Azure.ResourceManager.Storage.ObjectReplicationPolicyData ObjectReplicationPolicyData(Azure.Core.ResourceIdentifier id, string name, Azure.Core.ResourceType resourceType, Azure.ResourceManager.Models.SystemData systemData, string policyId, System.DateTimeOffset? enabledOn, string sourceAccount, string destinationAccount, System.Collections.Generic.IEnumerable rules) { throw null; } + public static Azure.ResourceManager.Storage.ObjectReplicationPolicyData ObjectReplicationPolicyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, string policyId = null, System.DateTimeOffset? enabledOn = default(System.DateTimeOffset?), string sourceAccount = null, string destinationAccount = null, System.Collections.Generic.IEnumerable rules = null, bool? isMetricsEnabled = default(bool?)) { throw null; } public static Azure.ResourceManager.Storage.Models.ProtectedAppendWritesHistory ProtectedAppendWritesHistory(bool? allowProtectedAppendWritesAll = default(bool?), System.DateTimeOffset? timestamp = default(System.DateTimeOffset?)) { throw null; } public static Azure.ResourceManager.Storage.QueueServiceData QueueServiceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, System.Collections.Generic.IEnumerable corsRules = null) { throw null; } public static Azure.ResourceManager.Storage.Models.RestorePolicy RestorePolicy(bool isEnabled = false, int? days = default(int?), System.DateTimeOffset? lastEnabledOn = default(System.DateTimeOffset?), System.DateTimeOffset? minRestoreOn = default(System.DateTimeOffset?)) { throw null; } @@ -1559,6 +1609,19 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class BurstingConstants : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal BurstingConstants() { } + public int? BurstFloorIops { get { throw null; } } + public double? BurstIOScalar { get { throw null; } } + public int? BurstTimeframeSeconds { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.BurstingConstants System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.BurstingConstants System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct CorsRuleAllowedMethod : System.IEquatable { @@ -1850,6 +1913,61 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public static bool operator !=(Azure.ResourceManager.Storage.Models.ExpirationAction left, Azure.ResourceManager.Storage.Models.ExpirationAction right) { throw null; } public override string ToString() { throw null; } } + public partial class FileServiceAccountLimits : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal FileServiceAccountLimits() { } + public int? MaxFileShares { get { throw null; } } + public int? MaxProvisionedBandwidthMiBPerSec { get { throw null; } } + public int? MaxProvisionedIops { get { throw null; } } + public int? MaxProvisionedStorageGiB { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceAccountLimits System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceAccountLimits System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class FileServiceAccountUsage : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal FileServiceAccountUsage() { } + public Azure.ResourceManager.Storage.Models.FileServiceAccountUsageElements LiveShares { get { throw null; } } + public Azure.ResourceManager.Storage.Models.FileServiceAccountUsageElements SoftDeletedShares { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceAccountUsage System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceAccountUsage System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class FileServiceAccountUsageElements : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal FileServiceAccountUsageElements() { } + public int? FileShareCount { get { throw null; } } + public int? ProvisionedBandwidthMiBPerSec { get { throw null; } } + public int? ProvisionedIops { get { throw null; } } + public int? ProvisionedStorageGiB { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceAccountUsageElements System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceAccountUsageElements System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class FileServiceUsageProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal FileServiceUsageProperties() { } + public Azure.ResourceManager.Storage.Models.BurstingConstants BurstingConstants { get { throw null; } } + public Azure.ResourceManager.Storage.Models.FileShareLimits FileShareLimits { get { throw null; } } + public Azure.ResourceManager.Storage.Models.FileShareRecommendations FileShareRecommendations { get { throw null; } } + public Azure.ResourceManager.Storage.Models.FileServiceAccountLimits StorageAccountLimits { get { throw null; } } + public Azure.ResourceManager.Storage.Models.FileServiceAccountUsage StorageAccountUsage { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceUsageProperties System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceUsageProperties System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct FileShareAccessTier : System.IEquatable { @@ -1888,6 +2006,49 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public static bool operator !=(Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol left, Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol right) { throw null; } public override string ToString() { throw null; } } + public partial class FileShareLimits : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal FileShareLimits() { } + public int? MaxProvisionedBandwidthMiBPerSec { get { throw null; } } + public int? MaxProvisionedIops { get { throw null; } } + public int? MaxProvisionedStorageGiB { get { throw null; } } + public int? MinProvisionedBandwidthMiBPerSec { get { throw null; } } + public int? MinProvisionedIops { get { throw null; } } + public int? MinProvisionedStorageGiB { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileShareLimits System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileShareLimits System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class FileSharePropertiesFileSharePaidBursting : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public FileSharePropertiesFileSharePaidBursting() { } + public bool? PaidBurstingEnabled { get { throw null; } set { } } + public int? PaidBurstingMaxBandwidthMibps { get { throw null; } set { } } + public int? PaidBurstingMaxIops { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileSharePropertiesFileSharePaidBursting System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileSharePropertiesFileSharePaidBursting System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class FileShareRecommendations : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal FileShareRecommendations() { } + public double? BandwidthScalar { get { throw null; } } + public int? BaseBandwidthMiBPerSec { get { throw null; } } + public int? BaseIops { get { throw null; } } + public double? IoScalar { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileShareRecommendations System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileShareRecommendations System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class FilesIdentityBasedAuthentication : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public FilesIdentityBasedAuthentication(Azure.ResourceManager.Storage.Models.DirectoryServiceOption directoryServiceOptions) { } @@ -3783,12 +3944,18 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer private readonly int _dummyPrimitive; public StorageSkuName(string value) { throw null; } public static Azure.ResourceManager.Storage.Models.StorageSkuName PremiumLrs { get { throw null; } } + public static Azure.ResourceManager.Storage.Models.StorageSkuName PremiumV2Lrs { get { throw null; } } + public static Azure.ResourceManager.Storage.Models.StorageSkuName PremiumV2Zrs { get { throw null; } } public static Azure.ResourceManager.Storage.Models.StorageSkuName PremiumZrs { get { throw null; } } public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardGrs { get { throw null; } } public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardGzrs { get { throw null; } } public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardLrs { get { throw null; } } public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardRagrs { get { throw null; } } public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardRagzrs { get { throw null; } } + public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardV2Grs { get { throw null; } } + public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardV2Gzrs { get { throw null; } } + public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardV2Lrs { get { throw null; } } + public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardV2Zrs { get { throw null; } } public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardZrs { get { throw null; } } public bool Equals(Azure.ResourceManager.Storage.Models.StorageSkuName other) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] diff --git a/sdk/storage/Azure.ResourceManager.Storage/api/Azure.ResourceManager.Storage.netstandard2.0.cs b/sdk/storage/Azure.ResourceManager.Storage/api/Azure.ResourceManager.Storage.netstandard2.0.cs index 41966cf11ed0..f31e45a1c584 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/api/Azure.ResourceManager.Storage.netstandard2.0.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/api/Azure.ResourceManager.Storage.netstandard2.0.cs @@ -267,6 +267,7 @@ protected FileServiceResource() { } public static Azure.Core.ResourceIdentifier CreateResourceIdentifier(string subscriptionId, string resourceGroupName, string accountName) { throw null; } public virtual Azure.Response Get(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.ResourceManager.Storage.FileServiceUsageResource GetFileServiceUsage() { throw null; } public virtual Azure.Response GetFileShare(string shareName, string expand = null, string xMsSnapshot = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetFileShareAsync(string shareName, string expand = null, string xMsSnapshot = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.Storage.FileShareCollection GetFileShares() { throw null; } @@ -276,6 +277,32 @@ protected FileServiceResource() { } string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class FileServiceUsageData : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public FileServiceUsageData() { } + public Azure.ResourceManager.Storage.Models.FileServiceUsageProperties Properties { get { throw null; } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.FileServiceUsageData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.FileServiceUsageData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class FileServiceUsageResource : Azure.ResourceManager.ArmResource, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public static readonly Azure.Core.ResourceType ResourceType; + protected FileServiceUsageResource() { } + public virtual Azure.ResourceManager.Storage.FileServiceUsageData Data { get { throw null; } } + public virtual bool HasData { get { throw null; } } + public static Azure.Core.ResourceIdentifier CreateResourceIdentifier(string subscriptionId, string resourceGroupName, string accountName) { throw null; } + public virtual Azure.Response Get(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + Azure.ResourceManager.Storage.FileServiceUsageData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.FileServiceUsageData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class FileShareCollection : Azure.ResourceManager.ArmCollection, System.Collections.Generic.IAsyncEnumerable, System.Collections.Generic.IEnumerable, System.Collections.IEnumerable { protected FileShareCollection() { } @@ -304,12 +331,20 @@ public FileShareData() { } public System.DateTimeOffset? DeletedOn { get { throw null; } } public Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol? EnabledProtocol { get { throw null; } set { } } public Azure.ETag? ETag { get { throw null; } } + public Azure.ResourceManager.Storage.Models.FileSharePropertiesFileSharePaidBursting FileSharePaidBursting { get { throw null; } set { } } + public int? IncludedBurstIops { get { throw null; } } public bool? IsDeleted { get { throw null; } } public System.DateTimeOffset? LastModifiedOn { get { throw null; } } public Azure.ResourceManager.Storage.Models.StorageLeaseDurationType? LeaseDuration { get { throw null; } } public Azure.ResourceManager.Storage.Models.StorageLeaseState? LeaseState { get { throw null; } } public Azure.ResourceManager.Storage.Models.StorageLeaseStatus? LeaseStatus { get { throw null; } } + public long? MaxBurstCreditsForIops { get { throw null; } } public System.Collections.Generic.IDictionary Metadata { get { throw null; } } + public System.DateTimeOffset? NextAllowedProvisionedBandwidthDowngradeOn { get { throw null; } } + public System.DateTimeOffset? NextAllowedProvisionedIopsDowngradeOn { get { throw null; } } + public System.DateTimeOffset? NextAllowedQuotaDowngradeOn { get { throw null; } } + public int? ProvisionedBandwidthMibps { get { throw null; } set { } } + public int? ProvisionedIops { get { throw null; } set { } } public int? RemainingRetentionDays { get { throw null; } } public Azure.ResourceManager.Storage.Models.RootSquashType? RootSquash { get { throw null; } set { } } public int? ShareQuota { get { throw null; } set { } } @@ -454,6 +489,7 @@ public partial class ObjectReplicationPolicyData : Azure.ResourceManager.Models. public ObjectReplicationPolicyData() { } public string DestinationAccount { get { throw null; } set { } } public System.DateTimeOffset? EnabledOn { get { throw null; } } + public bool? IsMetricsEnabled { get { throw null; } set { } } public string PolicyId { get { throw null; } } public System.Collections.Generic.IList Rules { get { throw null; } } public string SourceAccount { get { throw null; } set { } } @@ -836,6 +872,7 @@ public static partial class StorageExtensions public static Azure.AsyncPageable GetDeletedAccountsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Storage.EncryptionScopeResource GetEncryptionScopeResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Storage.FileServiceResource GetFileServiceResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } + public static Azure.ResourceManager.Storage.FileServiceUsageResource GetFileServiceUsageResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Storage.FileShareResource GetFileShareResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Storage.ImmutabilityPolicyResource GetImmutabilityPolicyResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Storage.NetworkSecurityPerimeterConfigurationResource GetNetworkSecurityPerimeterConfigurationResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } @@ -1099,6 +1136,7 @@ protected MockableStorageArmClient() { } public virtual Azure.ResourceManager.Storage.DeletedAccountResource GetDeletedAccountResource(Azure.Core.ResourceIdentifier id) { throw null; } public virtual Azure.ResourceManager.Storage.EncryptionScopeResource GetEncryptionScopeResource(Azure.Core.ResourceIdentifier id) { throw null; } public virtual Azure.ResourceManager.Storage.FileServiceResource GetFileServiceResource(Azure.Core.ResourceIdentifier id) { throw null; } + public virtual Azure.ResourceManager.Storage.FileServiceUsageResource GetFileServiceUsageResource(Azure.Core.ResourceIdentifier id) { throw null; } public virtual Azure.ResourceManager.Storage.FileShareResource GetFileShareResource(Azure.Core.ResourceIdentifier id) { throw null; } public virtual Azure.ResourceManager.Storage.ImmutabilityPolicyResource GetImmutabilityPolicyResource(Azure.Core.ResourceIdentifier id) { throw null; } public virtual Azure.ResourceManager.Storage.NetworkSecurityPerimeterConfigurationResource GetNetworkSecurityPerimeterConfigurationResource(Azure.Core.ResourceIdentifier id) { throw null; } @@ -1236,11 +1274,21 @@ public static partial class ArmStorageModelFactory public static Azure.ResourceManager.Storage.Models.BlobInventoryPolicySchema BlobInventoryPolicySchema(bool isEnabled = false, string destination = null, Azure.ResourceManager.Storage.Models.BlobInventoryRuleType ruleType = default(Azure.ResourceManager.Storage.Models.BlobInventoryRuleType), System.Collections.Generic.IEnumerable rules = null) { throw null; } public static Azure.ResourceManager.Storage.Models.BlobRestoreStatus BlobRestoreStatus(Azure.ResourceManager.Storage.Models.BlobRestoreProgressStatus? status = default(Azure.ResourceManager.Storage.Models.BlobRestoreProgressStatus?), string failureReason = null, string restoreId = null, Azure.ResourceManager.Storage.Models.BlobRestoreContent parameters = null) { throw null; } public static Azure.ResourceManager.Storage.BlobServiceData BlobServiceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Storage.Models.StorageSku sku = null, System.Collections.Generic.IEnumerable corsRules = null, string defaultServiceVersion = null, Azure.ResourceManager.Storage.Models.DeleteRetentionPolicy deleteRetentionPolicy = null, bool? isVersioningEnabled = default(bool?), bool? isAutomaticSnapshotPolicyEnabled = default(bool?), Azure.ResourceManager.Storage.Models.BlobServiceChangeFeed changeFeed = null, Azure.ResourceManager.Storage.Models.RestorePolicy restorePolicy = null, Azure.ResourceManager.Storage.Models.DeleteRetentionPolicy containerDeleteRetentionPolicy = null, Azure.ResourceManager.Storage.Models.LastAccessTimeTrackingPolicy lastAccessTimeTrackingPolicy = null) { throw null; } + public static Azure.ResourceManager.Storage.Models.BurstingConstants BurstingConstants(int? burstFloorIops = default(int?), double? burstIOScalar = default(double?), int? burstTimeframeSeconds = default(int?)) { throw null; } public static Azure.ResourceManager.Storage.DeletedAccountData DeletedAccountData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.Core.ResourceIdentifier storageAccountResourceId = null, Azure.Core.AzureLocation? location = default(Azure.Core.AzureLocation?), string restoreReference = null, System.DateTimeOffset? createdOn = default(System.DateTimeOffset?), System.DateTimeOffset? deletedOn = default(System.DateTimeOffset?)) { throw null; } public static Azure.ResourceManager.Storage.EncryptionScopeData EncryptionScopeData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Storage.Models.EncryptionScopeSource? source = default(Azure.ResourceManager.Storage.Models.EncryptionScopeSource?), Azure.ResourceManager.Storage.Models.EncryptionScopeState? state = default(Azure.ResourceManager.Storage.Models.EncryptionScopeState?), System.DateTimeOffset? createdOn = default(System.DateTimeOffset?), System.DateTimeOffset? lastModifiedOn = default(System.DateTimeOffset?), Azure.ResourceManager.Storage.Models.EncryptionScopeKeyVaultProperties keyVaultProperties = null, bool? requireInfrastructureEncryption = default(bool?)) { throw null; } public static Azure.ResourceManager.Storage.Models.EncryptionScopeKeyVaultProperties EncryptionScopeKeyVaultProperties(System.Uri keyUri = null, string currentVersionedKeyIdentifier = null, System.DateTimeOffset? lastKeyRotationTimestamp = default(System.DateTimeOffset?)) { throw null; } + public static Azure.ResourceManager.Storage.Models.FileServiceAccountLimits FileServiceAccountLimits(int? maxFileShares = default(int?), int? maxProvisionedStorageGiB = default(int?), int? maxProvisionedIops = default(int?), int? maxProvisionedBandwidthMiBPerSec = default(int?)) { throw null; } + public static Azure.ResourceManager.Storage.Models.FileServiceAccountUsage FileServiceAccountUsage(Azure.ResourceManager.Storage.Models.FileServiceAccountUsageElements liveShares = null, Azure.ResourceManager.Storage.Models.FileServiceAccountUsageElements softDeletedShares = null) { throw null; } + public static Azure.ResourceManager.Storage.Models.FileServiceAccountUsageElements FileServiceAccountUsageElements(int? fileShareCount = default(int?), int? provisionedStorageGiB = default(int?), int? provisionedIops = default(int?), int? provisionedBandwidthMiBPerSec = default(int?)) { throw null; } public static Azure.ResourceManager.Storage.FileServiceData FileServiceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Storage.Models.StorageSku sku = null, System.Collections.Generic.IEnumerable corsRules = null, Azure.ResourceManager.Storage.Models.DeleteRetentionPolicy shareDeleteRetentionPolicy = null, Azure.ResourceManager.Storage.Models.SmbSetting protocolSmbSetting = null) { throw null; } - public static Azure.ResourceManager.Storage.FileShareData FileShareData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, System.DateTimeOffset? lastModifiedOn = default(System.DateTimeOffset?), System.Collections.Generic.IDictionary metadata = null, int? shareQuota = default(int?), Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol? enabledProtocol = default(Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol?), Azure.ResourceManager.Storage.Models.RootSquashType? rootSquash = default(Azure.ResourceManager.Storage.Models.RootSquashType?), string version = null, bool? isDeleted = default(bool?), System.DateTimeOffset? deletedOn = default(System.DateTimeOffset?), int? remainingRetentionDays = default(int?), Azure.ResourceManager.Storage.Models.FileShareAccessTier? accessTier = default(Azure.ResourceManager.Storage.Models.FileShareAccessTier?), System.DateTimeOffset? accessTierChangeOn = default(System.DateTimeOffset?), string accessTierStatus = null, long? shareUsageBytes = default(long?), Azure.ResourceManager.Storage.Models.StorageLeaseStatus? leaseStatus = default(Azure.ResourceManager.Storage.Models.StorageLeaseStatus?), Azure.ResourceManager.Storage.Models.StorageLeaseState? leaseState = default(Azure.ResourceManager.Storage.Models.StorageLeaseState?), Azure.ResourceManager.Storage.Models.StorageLeaseDurationType? leaseDuration = default(Azure.ResourceManager.Storage.Models.StorageLeaseDurationType?), System.Collections.Generic.IEnumerable signedIdentifiers = null, System.DateTimeOffset? snapshotOn = default(System.DateTimeOffset?), Azure.ETag? etag = default(Azure.ETag?)) { throw null; } + public static Azure.ResourceManager.Storage.FileServiceUsageData FileServiceUsageData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Storage.Models.FileServiceUsageProperties properties = null) { throw null; } + public static Azure.ResourceManager.Storage.Models.FileServiceUsageProperties FileServiceUsageProperties(Azure.ResourceManager.Storage.Models.FileServiceAccountLimits storageAccountLimits = null, Azure.ResourceManager.Storage.Models.FileShareLimits fileShareLimits = null, Azure.ResourceManager.Storage.Models.FileShareRecommendations fileShareRecommendations = null, Azure.ResourceManager.Storage.Models.BurstingConstants burstingConstants = null, Azure.ResourceManager.Storage.Models.FileServiceAccountUsage storageAccountUsage = null) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public static Azure.ResourceManager.Storage.FileShareData FileShareData(Azure.Core.ResourceIdentifier id, string name, Azure.Core.ResourceType resourceType, Azure.ResourceManager.Models.SystemData systemData, System.DateTimeOffset? lastModifiedOn, System.Collections.Generic.IDictionary metadata, int? shareQuota, Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol? enabledProtocol, Azure.ResourceManager.Storage.Models.RootSquashType? rootSquash, string version, bool? isDeleted, System.DateTimeOffset? deletedOn, int? remainingRetentionDays, Azure.ResourceManager.Storage.Models.FileShareAccessTier? accessTier, System.DateTimeOffset? accessTierChangeOn, string accessTierStatus, long? shareUsageBytes, Azure.ResourceManager.Storage.Models.StorageLeaseStatus? leaseStatus, Azure.ResourceManager.Storage.Models.StorageLeaseState? leaseState, Azure.ResourceManager.Storage.Models.StorageLeaseDurationType? leaseDuration, System.Collections.Generic.IEnumerable signedIdentifiers, System.DateTimeOffset? snapshotOn, Azure.ETag? etag) { throw null; } + public static Azure.ResourceManager.Storage.FileShareData FileShareData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, System.DateTimeOffset? lastModifiedOn = default(System.DateTimeOffset?), System.Collections.Generic.IDictionary metadata = null, int? shareQuota = default(int?), int? provisionedIops = default(int?), int? provisionedBandwidthMibps = default(int?), int? includedBurstIops = default(int?), long? maxBurstCreditsForIops = default(long?), System.DateTimeOffset? nextAllowedQuotaDowngradeOn = default(System.DateTimeOffset?), System.DateTimeOffset? nextAllowedProvisionedIopsDowngradeOn = default(System.DateTimeOffset?), System.DateTimeOffset? nextAllowedProvisionedBandwidthDowngradeOn = default(System.DateTimeOffset?), Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol? enabledProtocol = default(Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol?), Azure.ResourceManager.Storage.Models.RootSquashType? rootSquash = default(Azure.ResourceManager.Storage.Models.RootSquashType?), string version = null, bool? isDeleted = default(bool?), System.DateTimeOffset? deletedOn = default(System.DateTimeOffset?), int? remainingRetentionDays = default(int?), Azure.ResourceManager.Storage.Models.FileShareAccessTier? accessTier = default(Azure.ResourceManager.Storage.Models.FileShareAccessTier?), System.DateTimeOffset? accessTierChangeOn = default(System.DateTimeOffset?), string accessTierStatus = null, long? shareUsageBytes = default(long?), Azure.ResourceManager.Storage.Models.StorageLeaseStatus? leaseStatus = default(Azure.ResourceManager.Storage.Models.StorageLeaseStatus?), Azure.ResourceManager.Storage.Models.StorageLeaseState? leaseState = default(Azure.ResourceManager.Storage.Models.StorageLeaseState?), Azure.ResourceManager.Storage.Models.StorageLeaseDurationType? leaseDuration = default(Azure.ResourceManager.Storage.Models.StorageLeaseDurationType?), System.Collections.Generic.IEnumerable signedIdentifiers = null, System.DateTimeOffset? snapshotOn = default(System.DateTimeOffset?), Azure.ResourceManager.Storage.Models.FileSharePropertiesFileSharePaidBursting fileSharePaidBursting = null, Azure.ETag? etag = default(Azure.ETag?)) { throw null; } + public static Azure.ResourceManager.Storage.Models.FileShareLimits FileShareLimits(int? minProvisionedStorageGiB = default(int?), int? maxProvisionedStorageGiB = default(int?), int? minProvisionedIops = default(int?), int? maxProvisionedIops = default(int?), int? minProvisionedBandwidthMiBPerSec = default(int?), int? maxProvisionedBandwidthMiBPerSec = default(int?)) { throw null; } + public static Azure.ResourceManager.Storage.Models.FileShareRecommendations FileShareRecommendations(int? baseIops = default(int?), double? ioScalar = default(double?), int? baseBandwidthMiBPerSec = default(int?), double? bandwidthScalar = default(double?)) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public static Azure.ResourceManager.Storage.Models.GeoReplicationStatistics GeoReplicationStatistics(Azure.ResourceManager.Storage.Models.GeoReplicationStatus? status, System.DateTimeOffset? lastSyncOn, bool? canFailover) { throw null; } public static Azure.ResourceManager.Storage.Models.GeoReplicationStatistics GeoReplicationStatistics(Azure.ResourceManager.Storage.Models.GeoReplicationStatus? status = default(Azure.ResourceManager.Storage.Models.GeoReplicationStatus?), System.DateTimeOffset? lastSyncOn = default(System.DateTimeOffset?), bool? canFailover = default(bool?), bool? canPlannedFailover = default(bool?), Azure.ResourceManager.Storage.Models.PostFailoverRedundancy? postFailoverRedundancy = default(Azure.ResourceManager.Storage.Models.PostFailoverRedundancy?), Azure.ResourceManager.Storage.Models.PostPlannedFailoverRedundancy? postPlannedFailoverRedundancy = default(Azure.ResourceManager.Storage.Models.PostPlannedFailoverRedundancy?)) { throw null; } @@ -1265,7 +1313,9 @@ public static partial class ArmStorageModelFactory public static Azure.ResourceManager.Storage.Models.NetworkSecurityPerimeterProvisioningIssueProperties NetworkSecurityPerimeterProvisioningIssueProperties(Azure.ResourceManager.Storage.Models.NetworkSecurityPerimeterProvisioningIssueType? issueType = default(Azure.ResourceManager.Storage.Models.NetworkSecurityPerimeterProvisioningIssueType?), Azure.ResourceManager.Storage.Models.NetworkSecurityPerimeterProvisioningIssueSeverity? severity = default(Azure.ResourceManager.Storage.Models.NetworkSecurityPerimeterProvisioningIssueSeverity?), string description = null) { throw null; } public static Azure.ResourceManager.Storage.Models.NspAccessRule NspAccessRule(string name = null, Azure.ResourceManager.Storage.Models.NspAccessRuleProperties properties = null) { throw null; } public static Azure.ResourceManager.Storage.Models.NspAccessRuleProperties NspAccessRuleProperties(Azure.ResourceManager.Storage.Models.NspAccessRuleDirection? direction = default(Azure.ResourceManager.Storage.Models.NspAccessRuleDirection?), System.Collections.Generic.IEnumerable addressPrefixes = null, System.Collections.Generic.IEnumerable subscriptions = null, System.Collections.Generic.IEnumerable networkSecurityPerimeters = null, System.Collections.Generic.IEnumerable fullyQualifiedDomainNames = null) { throw null; } - public static Azure.ResourceManager.Storage.ObjectReplicationPolicyData ObjectReplicationPolicyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, string policyId = null, System.DateTimeOffset? enabledOn = default(System.DateTimeOffset?), string sourceAccount = null, string destinationAccount = null, System.Collections.Generic.IEnumerable rules = null) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public static Azure.ResourceManager.Storage.ObjectReplicationPolicyData ObjectReplicationPolicyData(Azure.Core.ResourceIdentifier id, string name, Azure.Core.ResourceType resourceType, Azure.ResourceManager.Models.SystemData systemData, string policyId, System.DateTimeOffset? enabledOn, string sourceAccount, string destinationAccount, System.Collections.Generic.IEnumerable rules) { throw null; } + public static Azure.ResourceManager.Storage.ObjectReplicationPolicyData ObjectReplicationPolicyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, string policyId = null, System.DateTimeOffset? enabledOn = default(System.DateTimeOffset?), string sourceAccount = null, string destinationAccount = null, System.Collections.Generic.IEnumerable rules = null, bool? isMetricsEnabled = default(bool?)) { throw null; } public static Azure.ResourceManager.Storage.Models.ProtectedAppendWritesHistory ProtectedAppendWritesHistory(bool? allowProtectedAppendWritesAll = default(bool?), System.DateTimeOffset? timestamp = default(System.DateTimeOffset?)) { throw null; } public static Azure.ResourceManager.Storage.QueueServiceData QueueServiceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, System.Collections.Generic.IEnumerable corsRules = null) { throw null; } public static Azure.ResourceManager.Storage.Models.RestorePolicy RestorePolicy(bool isEnabled = false, int? days = default(int?), System.DateTimeOffset? lastEnabledOn = default(System.DateTimeOffset?), System.DateTimeOffset? minRestoreOn = default(System.DateTimeOffset?)) { throw null; } @@ -1559,6 +1609,19 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class BurstingConstants : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal BurstingConstants() { } + public int? BurstFloorIops { get { throw null; } } + public double? BurstIOScalar { get { throw null; } } + public int? BurstTimeframeSeconds { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.BurstingConstants System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.BurstingConstants System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct CorsRuleAllowedMethod : System.IEquatable { @@ -1850,6 +1913,61 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public static bool operator !=(Azure.ResourceManager.Storage.Models.ExpirationAction left, Azure.ResourceManager.Storage.Models.ExpirationAction right) { throw null; } public override string ToString() { throw null; } } + public partial class FileServiceAccountLimits : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal FileServiceAccountLimits() { } + public int? MaxFileShares { get { throw null; } } + public int? MaxProvisionedBandwidthMiBPerSec { get { throw null; } } + public int? MaxProvisionedIops { get { throw null; } } + public int? MaxProvisionedStorageGiB { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceAccountLimits System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceAccountLimits System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class FileServiceAccountUsage : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal FileServiceAccountUsage() { } + public Azure.ResourceManager.Storage.Models.FileServiceAccountUsageElements LiveShares { get { throw null; } } + public Azure.ResourceManager.Storage.Models.FileServiceAccountUsageElements SoftDeletedShares { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceAccountUsage System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceAccountUsage System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class FileServiceAccountUsageElements : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal FileServiceAccountUsageElements() { } + public int? FileShareCount { get { throw null; } } + public int? ProvisionedBandwidthMiBPerSec { get { throw null; } } + public int? ProvisionedIops { get { throw null; } } + public int? ProvisionedStorageGiB { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceAccountUsageElements System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceAccountUsageElements System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class FileServiceUsageProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal FileServiceUsageProperties() { } + public Azure.ResourceManager.Storage.Models.BurstingConstants BurstingConstants { get { throw null; } } + public Azure.ResourceManager.Storage.Models.FileShareLimits FileShareLimits { get { throw null; } } + public Azure.ResourceManager.Storage.Models.FileShareRecommendations FileShareRecommendations { get { throw null; } } + public Azure.ResourceManager.Storage.Models.FileServiceAccountLimits StorageAccountLimits { get { throw null; } } + public Azure.ResourceManager.Storage.Models.FileServiceAccountUsage StorageAccountUsage { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceUsageProperties System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileServiceUsageProperties System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct FileShareAccessTier : System.IEquatable { @@ -1888,6 +2006,49 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public static bool operator !=(Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol left, Azure.ResourceManager.Storage.Models.FileShareEnabledProtocol right) { throw null; } public override string ToString() { throw null; } } + public partial class FileShareLimits : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal FileShareLimits() { } + public int? MaxProvisionedBandwidthMiBPerSec { get { throw null; } } + public int? MaxProvisionedIops { get { throw null; } } + public int? MaxProvisionedStorageGiB { get { throw null; } } + public int? MinProvisionedBandwidthMiBPerSec { get { throw null; } } + public int? MinProvisionedIops { get { throw null; } } + public int? MinProvisionedStorageGiB { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileShareLimits System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileShareLimits System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class FileSharePropertiesFileSharePaidBursting : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public FileSharePropertiesFileSharePaidBursting() { } + public bool? PaidBurstingEnabled { get { throw null; } set { } } + public int? PaidBurstingMaxBandwidthMibps { get { throw null; } set { } } + public int? PaidBurstingMaxIops { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileSharePropertiesFileSharePaidBursting System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileSharePropertiesFileSharePaidBursting System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class FileShareRecommendations : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal FileShareRecommendations() { } + public double? BandwidthScalar { get { throw null; } } + public int? BaseBandwidthMiBPerSec { get { throw null; } } + public int? BaseIops { get { throw null; } } + public double? IoScalar { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileShareRecommendations System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Storage.Models.FileShareRecommendations System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class FilesIdentityBasedAuthentication : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public FilesIdentityBasedAuthentication(Azure.ResourceManager.Storage.Models.DirectoryServiceOption directoryServiceOptions) { } @@ -3783,12 +3944,18 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer private readonly int _dummyPrimitive; public StorageSkuName(string value) { throw null; } public static Azure.ResourceManager.Storage.Models.StorageSkuName PremiumLrs { get { throw null; } } + public static Azure.ResourceManager.Storage.Models.StorageSkuName PremiumV2Lrs { get { throw null; } } + public static Azure.ResourceManager.Storage.Models.StorageSkuName PremiumV2Zrs { get { throw null; } } public static Azure.ResourceManager.Storage.Models.StorageSkuName PremiumZrs { get { throw null; } } public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardGrs { get { throw null; } } public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardGzrs { get { throw null; } } public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardLrs { get { throw null; } } public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardRagrs { get { throw null; } } public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardRagzrs { get { throw null; } } + public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardV2Grs { get { throw null; } } + public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardV2Gzrs { get { throw null; } } + public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardV2Lrs { get { throw null; } } + public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardV2Zrs { get { throw null; } } public static Azure.ResourceManager.Storage.Models.StorageSkuName StandardZrs { get { throw null; } } public bool Equals(Azure.ResourceManager.Storage.Models.StorageSkuName other) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] diff --git a/sdk/storage/Azure.ResourceManager.Storage/assets.json b/sdk/storage/Azure.ResourceManager.Storage/assets.json index c7b72c01b151..4e1536944d1f 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/assets.json +++ b/sdk/storage/Azure.ResourceManager.Storage/assets.json @@ -2,5 +2,5 @@ "AssetsRepo": "Azure/azure-sdk-assets", "AssetsRepoPrefixPath": "net", "TagPrefix": "net/storage/Azure.ResourceManager.Storage", - "Tag": "net/storage/Azure.ResourceManager.Storage_7c9f69d940" + "Tag": "net/storage/Azure.ResourceManager.Storage_b706bb7184" } diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobContainerCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobContainerCollection.cs index 6eab63b608d5..3b2576978be9 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobContainerCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobContainerCollection.cs @@ -20,7 +20,7 @@ public partial class Sample_BlobContainerCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_PutContainerWithDefaultEncryptionScope() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersPutDefaultEncryptionScope.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersPutDefaultEncryptionScope.json // this example is just showing the usage of "BlobContainers_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -60,7 +60,7 @@ public async Task CreateOrUpdate_PutContainerWithDefaultEncryptionScope() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_PutContainerWithObjectLevelWorm() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersPutObjectLevelWorm.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersPutObjectLevelWorm.json // this example is just showing the usage of "BlobContainers_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -102,7 +102,7 @@ public async Task CreateOrUpdate_PutContainerWithObjectLevelWorm() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_PutContainers() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersPut.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersPut.json // this example is just showing the usage of "BlobContainers_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -138,7 +138,7 @@ public async Task CreateOrUpdate_PutContainers() [Ignore("Only validating compilation of examples")] public async Task Get_GetBlobContainersGetWithAllowProtectedAppendWritesAll() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersGetWithAllowProtectedAppendWritesAll.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersGetWithAllowProtectedAppendWritesAll.json // this example is just showing the usage of "BlobContainers_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -172,7 +172,7 @@ public async Task Get_GetBlobContainersGetWithAllowProtectedAppendWritesAll() [Ignore("Only validating compilation of examples")] public async Task Get_GetContainers() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersGet.json // this example is just showing the usage of "BlobContainers_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -206,7 +206,7 @@ public async Task Get_GetContainers() [Ignore("Only validating compilation of examples")] public async Task GetAll_ListContainers() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersList.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersList.json // this example is just showing the usage of "BlobContainers_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -242,7 +242,7 @@ public async Task GetAll_ListContainers() [Ignore("Only validating compilation of examples")] public async Task GetAll_ListDeletedContainers() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/DeletedBlobContainersList.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/DeletedBlobContainersList.json // this example is just showing the usage of "BlobContainers_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -279,7 +279,7 @@ public async Task GetAll_ListDeletedContainers() [Ignore("Only validating compilation of examples")] public async Task Exists_GetBlobContainersGetWithAllowProtectedAppendWritesAll() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersGetWithAllowProtectedAppendWritesAll.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersGetWithAllowProtectedAppendWritesAll.json // this example is just showing the usage of "BlobContainers_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -309,7 +309,7 @@ public async Task Exists_GetBlobContainersGetWithAllowProtectedAppendWritesAll() [Ignore("Only validating compilation of examples")] public async Task Exists_GetContainers() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersGet.json // this example is just showing the usage of "BlobContainers_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -339,7 +339,7 @@ public async Task Exists_GetContainers() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_GetBlobContainersGetWithAllowProtectedAppendWritesAll() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersGetWithAllowProtectedAppendWritesAll.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersGetWithAllowProtectedAppendWritesAll.json // this example is just showing the usage of "BlobContainers_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -381,7 +381,7 @@ public async Task GetIfExists_GetBlobContainersGetWithAllowProtectedAppendWrites [Ignore("Only validating compilation of examples")] public async Task GetIfExists_GetContainers() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersGet.json // this example is just showing the usage of "BlobContainers_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobContainerResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobContainerResource.cs index ae74e33dc669..42a45149f6b2 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobContainerResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobContainerResource.cs @@ -20,7 +20,7 @@ public partial class Sample_BlobContainerResource [Ignore("Only validating compilation of examples")] public async Task Get_GetBlobContainersGetWithAllowProtectedAppendWritesAll() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersGetWithAllowProtectedAppendWritesAll.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersGetWithAllowProtectedAppendWritesAll.json // this example is just showing the usage of "BlobContainers_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -51,7 +51,7 @@ public async Task Get_GetBlobContainersGetWithAllowProtectedAppendWritesAll() [Ignore("Only validating compilation of examples")] public async Task Get_GetContainers() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersGet.json // this example is just showing the usage of "BlobContainers_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -82,7 +82,7 @@ public async Task Get_GetContainers() [Ignore("Only validating compilation of examples")] public async Task Delete_DeleteContainers() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersDelete.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersDelete.json // this example is just showing the usage of "BlobContainers_Delete" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -109,7 +109,7 @@ public async Task Delete_DeleteContainers() [Ignore("Only validating compilation of examples")] public async Task Update_UpdateContainers() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersPatch.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersPatch.json // this example is just showing the usage of "BlobContainers_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -148,7 +148,7 @@ public async Task Update_UpdateContainers() [Ignore("Only validating compilation of examples")] public async Task SetLegalHold_SetLegalHoldContainers() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersSetLegalHold.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersSetLegalHold.json // this example is just showing the usage of "BlobContainers_SetLegalHold" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -176,7 +176,7 @@ public async Task SetLegalHold_SetLegalHoldContainers() [Ignore("Only validating compilation of examples")] public async Task SetLegalHold_SetLegalHoldContainersWithAllowProtectedAppendWritesAll() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersSetLegalHoldAllowProtectedAppendWritesAll.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersSetLegalHoldAllowProtectedAppendWritesAll.json // this example is just showing the usage of "BlobContainers_SetLegalHold" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -207,7 +207,7 @@ public async Task SetLegalHold_SetLegalHoldContainersWithAllowProtectedAppendWri [Ignore("Only validating compilation of examples")] public async Task ClearLegalHold_ClearLegalHoldContainers() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersClearLegalHold.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersClearLegalHold.json // this example is just showing the usage of "BlobContainers_ClearLegalHold" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -235,7 +235,7 @@ public async Task ClearLegalHold_ClearLegalHoldContainers() [Ignore("Only validating compilation of examples")] public async Task Lease_AcquireALeaseOnAContainer() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersLease_Acquire.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersLease_Acquire.json // this example is just showing the usage of "BlobContainers_Lease" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -269,7 +269,7 @@ public async Task Lease_AcquireALeaseOnAContainer() [Ignore("Only validating compilation of examples")] public async Task Lease_BreakALeaseOnAContainer() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersLease_Break.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersLease_Break.json // this example is just showing the usage of "BlobContainers_Lease" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -303,7 +303,7 @@ public async Task Lease_BreakALeaseOnAContainer() [Ignore("Only validating compilation of examples")] public async Task EnableVersionLevelImmutability_VersionLevelWormContainerMigration() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/ObjectLevelWormContainerMigration.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/ObjectLevelWormContainerMigration.json // this example is just showing the usage of "BlobContainers_ObjectLevelWorm" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobInventoryPolicyResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobInventoryPolicyResource.cs index c78acff1b735..078f6b14fa9f 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobInventoryPolicyResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobInventoryPolicyResource.cs @@ -20,7 +20,7 @@ public partial class Sample_BlobInventoryPolicyResource [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetBlobInventoryPolicy() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetBlobInventoryPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetBlobInventoryPolicy.json // this example is just showing the usage of "BlobInventoryPolicies_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -51,7 +51,7 @@ public async Task Get_StorageAccountGetBlobInventoryPolicy() [Ignore("Only validating compilation of examples")] public async Task Delete_StorageAccountDeleteBlobInventoryPolicy() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountDeleteBlobInventoryPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountDeleteBlobInventoryPolicy.json // this example is just showing the usage of "BlobInventoryPolicies_Delete" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -78,7 +78,7 @@ public async Task Delete_StorageAccountDeleteBlobInventoryPolicy() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountSetBlobInventoryPolicy() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountSetBlobInventoryPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountSetBlobInventoryPolicy.json // this example is just showing the usage of "BlobInventoryPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -128,7 +128,7 @@ public async Task CreateOrUpdate_StorageAccountSetBlobInventoryPolicy() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountSetBlobInventoryPolicyIncludeDeleteAndNewSchemaForHnsAccount() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountSetBlobInventoryPolicyIncludeDeleteAndNewSchemaForHnsAccount.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountSetBlobInventoryPolicyIncludeDeleteAndNewSchemaForHnsAccount.json // this example is just showing the usage of "BlobInventoryPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -179,7 +179,7 @@ public async Task CreateOrUpdate_StorageAccountSetBlobInventoryPolicyIncludeDele [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountSetBlobInventoryPolicyIncludeDeleteAndNewSchemaForNonHnsAccount() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountSetBlobInventoryPolicyIncludeDeleteAndNewSchemaForNonHnsAccount.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountSetBlobInventoryPolicyIncludeDeleteAndNewSchemaForNonHnsAccount.json // this example is just showing the usage of "BlobInventoryPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobServiceResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobServiceResource.cs index a7589de2b362..6b4705b8a7dd 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobServiceResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_BlobServiceResource.cs @@ -20,7 +20,7 @@ public partial class Sample_BlobServiceResource [Ignore("Only validating compilation of examples")] public async Task Get_GetBlobServices() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobServicesGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobServicesGet.json // this example is just showing the usage of "BlobServices_GetServiceProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -50,7 +50,7 @@ public async Task Get_GetBlobServices() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_BlobServicesPutAllowPermanentDelete() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobServicesPutAllowPermanentDelete.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobServicesPutAllowPermanentDelete.json // this example is just showing the usage of "BlobServices_SetServiceProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -91,7 +91,7 @@ public async Task CreateOrUpdate_BlobServicesPutAllowPermanentDelete() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_BlobServicesPutLastAccessTimeBasedTracking() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobServicesPutLastAccessTimeBasedTracking.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobServicesPutLastAccessTimeBasedTracking.json // this example is just showing the usage of "BlobServices_SetServiceProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -131,7 +131,7 @@ public async Task CreateOrUpdate_BlobServicesPutLastAccessTimeBasedTracking() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_PutBlobServices() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobServicesPut.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobServicesPut.json // this example is just showing the usage of "BlobServices_SetServiceProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_DeletedAccountCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_DeletedAccountCollection.cs index db31d61ee754..3a11216195ab 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_DeletedAccountCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_DeletedAccountCollection.cs @@ -20,7 +20,7 @@ public partial class Sample_DeletedAccountCollection [Ignore("Only validating compilation of examples")] public async Task Get_DeletedAccountGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/DeletedAccountGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/DeletedAccountGet.json // this example is just showing the usage of "DeletedAccounts_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -53,7 +53,7 @@ public async Task Get_DeletedAccountGet() [Ignore("Only validating compilation of examples")] public async Task Exists_DeletedAccountGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/DeletedAccountGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/DeletedAccountGet.json // this example is just showing the usage of "DeletedAccounts_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -82,7 +82,7 @@ public async Task Exists_DeletedAccountGet() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_DeletedAccountGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/DeletedAccountGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/DeletedAccountGet.json // this example is just showing the usage of "DeletedAccounts_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_DeletedAccountResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_DeletedAccountResource.cs index c67cc98156b5..203f52ded5e6 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_DeletedAccountResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_DeletedAccountResource.cs @@ -19,7 +19,7 @@ public partial class Sample_DeletedAccountResource [Ignore("Only validating compilation of examples")] public async Task Get_DeletedAccountGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/DeletedAccountGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/DeletedAccountGet.json // this example is just showing the usage of "DeletedAccounts_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_EncryptionScopeCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_EncryptionScopeCollection.cs index 087c86a5d309..1a6459c4bd9d 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_EncryptionScopeCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_EncryptionScopeCollection.cs @@ -19,7 +19,7 @@ public partial class Sample_EncryptionScopeCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountPutEncryptionScope() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountPutEncryptionScope.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountPutEncryptionScope.json // this example is just showing the usage of "EncryptionScopes_Put" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -55,7 +55,7 @@ public async Task CreateOrUpdate_StorageAccountPutEncryptionScope() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountPutEncryptionScopeWithInfrastructureEncryption() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountPutEncryptionScopeWithInfrastructureEncryption.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountPutEncryptionScopeWithInfrastructureEncryption.json // this example is just showing the usage of "EncryptionScopes_Put" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -94,7 +94,7 @@ public async Task CreateOrUpdate_StorageAccountPutEncryptionScopeWithInfrastruct [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetEncryptionScope() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetEncryptionScope.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetEncryptionScope.json // this example is just showing the usage of "EncryptionScopes_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -128,7 +128,7 @@ public async Task Get_StorageAccountGetEncryptionScope() [Ignore("Only validating compilation of examples")] public async Task GetAll_StorageAccountEncryptionScopeList() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountEncryptionScopeList.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountEncryptionScopeList.json // this example is just showing the usage of "EncryptionScopes_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -164,7 +164,7 @@ public async Task GetAll_StorageAccountEncryptionScopeList() [Ignore("Only validating compilation of examples")] public async Task Exists_StorageAccountGetEncryptionScope() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetEncryptionScope.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetEncryptionScope.json // this example is just showing the usage of "EncryptionScopes_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -194,7 +194,7 @@ public async Task Exists_StorageAccountGetEncryptionScope() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_StorageAccountGetEncryptionScope() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetEncryptionScope.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetEncryptionScope.json // this example is just showing the usage of "EncryptionScopes_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_EncryptionScopeResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_EncryptionScopeResource.cs index cb170cd91ae2..952319419ae5 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_EncryptionScopeResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_EncryptionScopeResource.cs @@ -20,7 +20,7 @@ public partial class Sample_EncryptionScopeResource [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetEncryptionScope() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetEncryptionScope.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetEncryptionScope.json // this example is just showing the usage of "EncryptionScopes_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -51,7 +51,7 @@ public async Task Get_StorageAccountGetEncryptionScope() [Ignore("Only validating compilation of examples")] public async Task Update_StorageAccountPatchEncryptionScope() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountPatchEncryptionScope.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountPatchEncryptionScope.json // this example is just showing the usage of "EncryptionScopes_Patch" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileServiceResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileServiceResource.cs index ea5ce7b38a6e..ee2026954e9f 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileServiceResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileServiceResource.cs @@ -20,7 +20,7 @@ public partial class Sample_FileServiceResource [Ignore("Only validating compilation of examples")] public async Task Get_GetFileServices() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileServicesGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileServicesGet.json // this example is just showing the usage of "FileServices_GetServiceProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -50,7 +50,7 @@ public async Task Get_GetFileServices() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_PutFileServices() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileServicesPut.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileServicesPut.json // this example is just showing the usage of "FileServices_SetServiceProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -85,7 +85,7 @@ public async Task CreateOrUpdate_PutFileServices() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_PutFileServicesEnableSMBMultichannel() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileServicesPut_EnableSMBMultichannel.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileServicesPut_EnableSMBMultichannel.json // this example is just showing the usage of "FileServices_SetServiceProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -123,7 +123,7 @@ public async Task CreateOrUpdate_PutFileServicesEnableSMBMultichannel() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_PutFileServicesEnableSecureSmbFeatures() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileServicesPut_EnableSecureSmbFeatures.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileServicesPut_EnableSecureSmbFeatures.json // this example is just showing the usage of "FileServices_SetServiceProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileServiceUsageResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileServiceUsageResource.cs new file mode 100644 index 000000000000..83a0ed2d121e --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileServiceUsageResource.cs @@ -0,0 +1,48 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Threading.Tasks; +using Azure.Core; +using Azure.Identity; +using NUnit.Framework; + +namespace Azure.ResourceManager.Storage.Samples +{ + public partial class Sample_FileServiceUsageResource + { + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Get_GetFileServiceUsage() + { + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileServicesGetUsage.json + // this example is just showing the usage of "FileServices_GetServiceUsage" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this FileServiceUsageResource created on azure + // for more information of creating FileServiceUsageResource, please refer to the document of FileServiceUsageResource + string subscriptionId = "00000000-1111-2222-3333-444444444444"; + string resourceGroupName = "res4410"; + string accountName = "sto8607"; + ResourceIdentifier fileServiceUsageResourceId = FileServiceUsageResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName); + FileServiceUsageResource fileServiceUsage = client.GetFileServiceUsageResource(fileServiceUsageResourceId); + + // invoke the operation + FileServiceUsageResource result = await fileServiceUsage.GetAsync(); + + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + FileServiceUsageData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileShareCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileShareCollection.cs index 9095648df030..a5c71f919578 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileShareCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileShareCollection.cs @@ -20,7 +20,7 @@ public partial class Sample_FileShareCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_CreateNFSShares() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesPut_NFS.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_NFS.json // this example is just showing the usage of "FileShares_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -59,7 +59,7 @@ public async Task CreateOrUpdate_CreateNFSShares() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_PutShares() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesPut.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut.json // this example is just showing the usage of "FileShares_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -95,7 +95,7 @@ public async Task CreateOrUpdate_PutShares() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_PutSharesWithAccessTier() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesPut_AccessTier.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_AccessTier.json // this example is just showing the usage of "FileShares_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -130,11 +130,164 @@ public async Task CreateOrUpdate_PutSharesWithAccessTier() Console.WriteLine($"Succeeded on id: {resourceData.Id}"); } + [Test] + [Ignore("Only validating compilation of examples")] + public async Task CreateOrUpdate_PutSharesWithPaidBursting() + { + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_PaidBursting.json + // this example is just showing the usage of "FileShares_Create" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this FileServiceResource created on azure + // for more information of creating FileServiceResource, please refer to the document of FileServiceResource + string subscriptionId = "{subscription-id}"; + string resourceGroupName = "res346"; + string accountName = "sto666"; + ResourceIdentifier fileServiceResourceId = FileServiceResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName); + FileServiceResource fileService = client.GetFileServiceResource(fileServiceResourceId); + + // get the collection of this FileShareResource + FileShareCollection collection = fileService.GetFileShares(); + + // invoke the operation + string shareName = "share1235"; + FileShareData data = new FileShareData + { + FileSharePaidBursting = new FileSharePropertiesFileSharePaidBursting + { + PaidBurstingEnabled = true, + PaidBurstingMaxIops = 102400, + PaidBurstingMaxBandwidthMibps = 10340, + }, + }; + ArmOperation lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, shareName, data); + FileShareResource result = lro.Value; + + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + FileShareData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task CreateOrUpdate_PutSharesProvisionedV2() + { + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_ProvisionedV2.json + // this example is just showing the usage of "FileShares_Create" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this FileServiceResource created on azure + // for more information of creating FileServiceResource, please refer to the document of FileServiceResource + string subscriptionId = "{subscription-id}"; + string resourceGroupName = "res346"; + string accountName = "sto666"; + ResourceIdentifier fileServiceResourceId = FileServiceResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName); + FileServiceResource fileService = client.GetFileServiceResource(fileServiceResourceId); + + // get the collection of this FileShareResource + FileShareCollection collection = fileService.GetFileShares(); + + // invoke the operation + string shareName = "share1235"; + FileShareData data = new FileShareData + { + ShareQuota = 100, + ProvisionedIops = 5000, + ProvisionedBandwidthMibps = 200, + }; + ArmOperation lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, shareName, data); + FileShareResource result = lro.Value; + + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + FileShareData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Get_GetSharePaidBursting() + { + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet_PaidBursting.json + // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this FileServiceResource created on azure + // for more information of creating FileServiceResource, please refer to the document of FileServiceResource + string subscriptionId = "{subscription-id}"; + string resourceGroupName = "res9871"; + string accountName = "sto6217"; + ResourceIdentifier fileServiceResourceId = FileServiceResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName); + FileServiceResource fileService = client.GetFileServiceResource(fileServiceResourceId); + + // get the collection of this FileShareResource + FileShareCollection collection = fileService.GetFileShares(); + + // invoke the operation + string shareName = "share1634"; + FileShareResource result = await collection.GetAsync(shareName); + + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + FileShareData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Get_GetShareProvisionedV2() + { + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet_ProvisionedV2.json + // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this FileServiceResource created on azure + // for more information of creating FileServiceResource, please refer to the document of FileServiceResource + string subscriptionId = "{subscription-id}"; + string resourceGroupName = "res9871"; + string accountName = "sto6217"; + ResourceIdentifier fileServiceResourceId = FileServiceResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName); + FileServiceResource fileService = client.GetFileServiceResource(fileServiceResourceId); + + // get the collection of this FileShareResource + FileShareCollection collection = fileService.GetFileShares(); + + // invoke the operation + string shareName = "share1634"; + FileShareResource result = await collection.GetAsync(shareName); + + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + FileShareData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + [Test] [Ignore("Only validating compilation of examples")] public async Task Get_GetShareStats() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesGet_Stats.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet_Stats.json // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -169,7 +322,7 @@ public async Task Get_GetShareStats() [Ignore("Only validating compilation of examples")] public async Task Get_GetShares() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet.json // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -203,7 +356,7 @@ public async Task Get_GetShares() [Ignore("Only validating compilation of examples")] public async Task GetAll_ListDeletedShares() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/DeletedFileSharesList.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/DeletedFileSharesList.json // this example is just showing the usage of "FileShares_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -240,7 +393,7 @@ public async Task GetAll_ListDeletedShares() [Ignore("Only validating compilation of examples")] public async Task GetAll_ListShareSnapshots() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileShareSnapshotsList.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileShareSnapshotsList.json // this example is just showing the usage of "FileShares_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -277,7 +430,43 @@ public async Task GetAll_ListShareSnapshots() [Ignore("Only validating compilation of examples")] public async Task GetAll_ListShares() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesList.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesList.json + // this example is just showing the usage of "FileShares_List" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this FileServiceResource created on azure + // for more information of creating FileServiceResource, please refer to the document of FileServiceResource + string subscriptionId = "{subscription-id}"; + string resourceGroupName = "res9290"; + string accountName = "sto1590"; + ResourceIdentifier fileServiceResourceId = FileServiceResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName); + FileServiceResource fileService = client.GetFileServiceResource(fileServiceResourceId); + + // get the collection of this FileShareResource + FileShareCollection collection = fileService.GetFileShares(); + + // invoke the operation and iterate over the result + await foreach (FileShareResource item in collection.GetAllAsync()) + { + // the variable item is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + FileShareData resourceData = item.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + + Console.WriteLine("Succeeded"); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task GetAll_ListSharesPaidBursting() + { + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesList_PaidBursting.json // this example is just showing the usage of "FileShares_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -309,11 +498,107 @@ public async Task GetAll_ListShares() Console.WriteLine("Succeeded"); } + [Test] + [Ignore("Only validating compilation of examples")] + public async Task GetAll_ListSharesProvisionedV2() + { + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesList_ProvisionedV2.json + // this example is just showing the usage of "FileShares_List" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this FileServiceResource created on azure + // for more information of creating FileServiceResource, please refer to the document of FileServiceResource + string subscriptionId = "{subscription-id}"; + string resourceGroupName = "res9290"; + string accountName = "sto1590"; + ResourceIdentifier fileServiceResourceId = FileServiceResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName); + FileServiceResource fileService = client.GetFileServiceResource(fileServiceResourceId); + + // get the collection of this FileShareResource + FileShareCollection collection = fileService.GetFileShares(); + + // invoke the operation and iterate over the result + await foreach (FileShareResource item in collection.GetAllAsync()) + { + // the variable item is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + FileShareData resourceData = item.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + + Console.WriteLine("Succeeded"); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Exists_GetSharePaidBursting() + { + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet_PaidBursting.json + // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this FileServiceResource created on azure + // for more information of creating FileServiceResource, please refer to the document of FileServiceResource + string subscriptionId = "{subscription-id}"; + string resourceGroupName = "res9871"; + string accountName = "sto6217"; + ResourceIdentifier fileServiceResourceId = FileServiceResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName); + FileServiceResource fileService = client.GetFileServiceResource(fileServiceResourceId); + + // get the collection of this FileShareResource + FileShareCollection collection = fileService.GetFileShares(); + + // invoke the operation + string shareName = "share1634"; + bool result = await collection.ExistsAsync(shareName); + + Console.WriteLine($"Succeeded: {result}"); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Exists_GetShareProvisionedV2() + { + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet_ProvisionedV2.json + // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this FileServiceResource created on azure + // for more information of creating FileServiceResource, please refer to the document of FileServiceResource + string subscriptionId = "{subscription-id}"; + string resourceGroupName = "res9871"; + string accountName = "sto6217"; + ResourceIdentifier fileServiceResourceId = FileServiceResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName); + FileServiceResource fileService = client.GetFileServiceResource(fileServiceResourceId); + + // get the collection of this FileShareResource + FileShareCollection collection = fileService.GetFileShares(); + + // invoke the operation + string shareName = "share1634"; + bool result = await collection.ExistsAsync(shareName); + + Console.WriteLine($"Succeeded: {result}"); + } + [Test] [Ignore("Only validating compilation of examples")] public async Task Exists_GetShareStats() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesGet_Stats.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet_Stats.json // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -344,7 +629,7 @@ public async Task Exists_GetShareStats() [Ignore("Only validating compilation of examples")] public async Task Exists_GetShares() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet.json // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -370,11 +655,95 @@ public async Task Exists_GetShares() Console.WriteLine($"Succeeded: {result}"); } + [Test] + [Ignore("Only validating compilation of examples")] + public async Task GetIfExists_GetSharePaidBursting() + { + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet_PaidBursting.json + // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this FileServiceResource created on azure + // for more information of creating FileServiceResource, please refer to the document of FileServiceResource + string subscriptionId = "{subscription-id}"; + string resourceGroupName = "res9871"; + string accountName = "sto6217"; + ResourceIdentifier fileServiceResourceId = FileServiceResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName); + FileServiceResource fileService = client.GetFileServiceResource(fileServiceResourceId); + + // get the collection of this FileShareResource + FileShareCollection collection = fileService.GetFileShares(); + + // invoke the operation + string shareName = "share1634"; + NullableResponse response = await collection.GetIfExistsAsync(shareName); + FileShareResource result = response.HasValue ? response.Value : null; + + if (result == null) + { + Console.WriteLine("Succeeded with null as result"); + } + else + { + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + FileShareData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task GetIfExists_GetShareProvisionedV2() + { + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet_ProvisionedV2.json + // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this FileServiceResource created on azure + // for more information of creating FileServiceResource, please refer to the document of FileServiceResource + string subscriptionId = "{subscription-id}"; + string resourceGroupName = "res9871"; + string accountName = "sto6217"; + ResourceIdentifier fileServiceResourceId = FileServiceResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName); + FileServiceResource fileService = client.GetFileServiceResource(fileServiceResourceId); + + // get the collection of this FileShareResource + FileShareCollection collection = fileService.GetFileShares(); + + // invoke the operation + string shareName = "share1634"; + NullableResponse response = await collection.GetIfExistsAsync(shareName); + FileShareResource result = response.HasValue ? response.Value : null; + + if (result == null) + { + Console.WriteLine("Succeeded with null as result"); + } + else + { + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + FileShareData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + } + [Test] [Ignore("Only validating compilation of examples")] public async Task GetIfExists_GetShareStats() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesGet_Stats.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet_Stats.json // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -417,7 +786,7 @@ public async Task GetIfExists_GetShareStats() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_GetShares() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet.json // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileShareResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileShareResource.cs index 3bdec6ad4912..c1baa0784c98 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileShareResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_FileShareResource.cs @@ -16,11 +16,73 @@ namespace Azure.ResourceManager.Storage.Samples { public partial class Sample_FileShareResource { + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Get_GetSharePaidBursting() + { + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet_PaidBursting.json + // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this FileShareResource created on azure + // for more information of creating FileShareResource, please refer to the document of FileShareResource + string subscriptionId = "{subscription-id}"; + string resourceGroupName = "res9871"; + string accountName = "sto6217"; + string shareName = "share1634"; + ResourceIdentifier fileShareResourceId = FileShareResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName, shareName); + FileShareResource fileShare = client.GetFileShareResource(fileShareResourceId); + + // invoke the operation + FileShareResource result = await fileShare.GetAsync(); + + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + FileShareData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Get_GetShareProvisionedV2() + { + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet_ProvisionedV2.json + // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this FileShareResource created on azure + // for more information of creating FileShareResource, please refer to the document of FileShareResource + string subscriptionId = "{subscription-id}"; + string resourceGroupName = "res9871"; + string accountName = "sto6217"; + string shareName = "share1634"; + ResourceIdentifier fileShareResourceId = FileShareResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName, shareName); + FileShareResource fileShare = client.GetFileShareResource(fileShareResourceId); + + // invoke the operation + FileShareResource result = await fileShare.GetAsync(); + + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + FileShareData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + [Test] [Ignore("Only validating compilation of examples")] public async Task Get_GetShareStats() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesGet_Stats.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet_Stats.json // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -52,7 +114,7 @@ public async Task Get_GetShareStats() [Ignore("Only validating compilation of examples")] public async Task Get_GetShares() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesGet.json // this example is just showing the usage of "FileShares_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -83,7 +145,7 @@ public async Task Get_GetShares() [Ignore("Only validating compilation of examples")] public async Task Delete_DeleteShares() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesDelete.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesDelete.json // this example is just showing the usage of "FileShares_Delete" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -110,7 +172,7 @@ public async Task Delete_DeleteShares() [Ignore("Only validating compilation of examples")] public async Task Update_UpdateShareAcls() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileShareAclsPatch.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileShareAclsPatch.json // this example is just showing the usage of "FileShares_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -150,11 +212,88 @@ public async Task Update_UpdateShareAcls() Console.WriteLine($"Succeeded on id: {resourceData.Id}"); } + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Update_UpdateSharePaidBursting() + { + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPatch_PaidBursting.json + // this example is just showing the usage of "FileShares_Update" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this FileShareResource created on azure + // for more information of creating FileShareResource, please refer to the document of FileShareResource + string subscriptionId = "{subscription-id}"; + string resourceGroupName = "res3376"; + string accountName = "sto328"; + string shareName = "share6185"; + ResourceIdentifier fileShareResourceId = FileShareResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName, shareName); + FileShareResource fileShare = client.GetFileShareResource(fileShareResourceId); + + // invoke the operation + FileShareData data = new FileShareData + { + FileSharePaidBursting = new FileSharePropertiesFileSharePaidBursting + { + PaidBurstingEnabled = true, + PaidBurstingMaxIops = 102400, + PaidBurstingMaxBandwidthMibps = 10340, + }, + }; + FileShareResource result = await fileShare.UpdateAsync(data); + + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + FileShareData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Update_UpdateShareProvisionedV2() + { + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPatch_ProvisionedV2.json + // this example is just showing the usage of "FileShares_Update" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this FileShareResource created on azure + // for more information of creating FileShareResource, please refer to the document of FileShareResource + string subscriptionId = "{subscription-id}"; + string resourceGroupName = "res3376"; + string accountName = "sto328"; + string shareName = "share6185"; + ResourceIdentifier fileShareResourceId = FileShareResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName, shareName); + FileShareResource fileShare = client.GetFileShareResource(fileShareResourceId); + + // invoke the operation + FileShareData data = new FileShareData + { + ShareQuota = 100, + ProvisionedIops = 5000, + ProvisionedBandwidthMibps = 200, + }; + FileShareResource result = await fileShare.UpdateAsync(data); + + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + FileShareData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + [Test] [Ignore("Only validating compilation of examples")] public async Task Update_UpdateShares() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesPatch.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPatch.json // this example is just showing the usage of "FileShares_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -192,7 +331,7 @@ public async Task Update_UpdateShares() [Ignore("Only validating compilation of examples")] public async Task Restore_RestoreShares() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesRestore.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesRestore.json // this example is just showing the usage of "FileShares_Restore" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -220,7 +359,7 @@ public async Task Restore_RestoreShares() [Ignore("Only validating compilation of examples")] public async Task Lease_AcquireALeaseOnAShare() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesLease_Acquire.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesLease_Acquire.json // this example is just showing the usage of "FileShares_Lease" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -254,7 +393,7 @@ public async Task Lease_AcquireALeaseOnAShare() [Ignore("Only validating compilation of examples")] public async Task Lease_BreakALeaseOnAShare() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/FileSharesLease_Break.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesLease_Break.json // this example is just showing the usage of "FileShares_Lease" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_ImmutabilityPolicyResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_ImmutabilityPolicyResource.cs index 78bcb3251c63..ebec0fca72c3 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_ImmutabilityPolicyResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_ImmutabilityPolicyResource.cs @@ -19,7 +19,7 @@ public partial class Sample_ImmutabilityPolicyResource [Ignore("Only validating compilation of examples")] public async Task Get_GetImmutabilityPolicy() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersGetImmutabilityPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersGetImmutabilityPolicy.json // this example is just showing the usage of "BlobContainers_GetImmutabilityPolicy" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -50,7 +50,7 @@ public async Task Get_GetImmutabilityPolicy() [Ignore("Only validating compilation of examples")] public async Task Delete_DeleteImmutabilityPolicy() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersDeleteImmutabilityPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersDeleteImmutabilityPolicy.json // this example is just showing the usage of "BlobContainers_DeleteImmutabilityPolicy" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -83,7 +83,7 @@ public async Task Delete_DeleteImmutabilityPolicy() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_CreateOrUpdateImmutabilityPolicy() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersPutImmutabilityPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersPutImmutabilityPolicy.json // this example is just showing the usage of "BlobContainers_CreateOrUpdateImmutabilityPolicy" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -120,7 +120,7 @@ public async Task CreateOrUpdate_CreateOrUpdateImmutabilityPolicy() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_CreateOrUpdateImmutabilityPolicyWithAllowProtectedAppendWritesAll() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersPutImmutabilityPolicyAllowProtectedAppendWritesAll.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersPutImmutabilityPolicyAllowProtectedAppendWritesAll.json // this example is just showing the usage of "BlobContainers_CreateOrUpdateImmutabilityPolicy" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -157,7 +157,7 @@ public async Task CreateOrUpdate_CreateOrUpdateImmutabilityPolicyWithAllowProtec [Ignore("Only validating compilation of examples")] public async Task LockImmutabilityPolicy_LockImmutabilityPolicy() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersLockImmutabilityPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersLockImmutabilityPolicy.json // this example is just showing the usage of "BlobContainers_LockImmutabilityPolicy" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -189,7 +189,7 @@ public async Task LockImmutabilityPolicy_LockImmutabilityPolicy() [Ignore("Only validating compilation of examples")] public async Task ExtendImmutabilityPolicy_ExtendImmutabilityPolicy() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobContainersExtendImmutabilityPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobContainersExtendImmutabilityPolicy.json // this example is just showing the usage of "BlobContainers_ExtendImmutabilityPolicy" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_NetworkSecurityPerimeterConfigurationCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_NetworkSecurityPerimeterConfigurationCollection.cs index 1decd2aede78..ae8dfd1d6723 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_NetworkSecurityPerimeterConfigurationCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_NetworkSecurityPerimeterConfigurationCollection.cs @@ -19,7 +19,7 @@ public partial class Sample_NetworkSecurityPerimeterConfigurationCollection [Ignore("Only validating compilation of examples")] public async Task Get_NetworkSecurityPerimeterConfigurationGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/NetworkSecurityPerimeterConfigurationGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/NetworkSecurityPerimeterConfigurationGet.json // this example is just showing the usage of "NetworkSecurityPerimeterConfigurations_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -53,7 +53,7 @@ public async Task Get_NetworkSecurityPerimeterConfigurationGet() [Ignore("Only validating compilation of examples")] public async Task GetAll_NetworkSecurityPerimeterConfigurationList() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/NetworkSecurityPerimeterConfigurationList.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/NetworkSecurityPerimeterConfigurationList.json // this example is just showing the usage of "NetworkSecurityPerimeterConfigurations_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -89,7 +89,7 @@ public async Task GetAll_NetworkSecurityPerimeterConfigurationList() [Ignore("Only validating compilation of examples")] public async Task Exists_NetworkSecurityPerimeterConfigurationGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/NetworkSecurityPerimeterConfigurationGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/NetworkSecurityPerimeterConfigurationGet.json // this example is just showing the usage of "NetworkSecurityPerimeterConfigurations_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -119,7 +119,7 @@ public async Task Exists_NetworkSecurityPerimeterConfigurationGet() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_NetworkSecurityPerimeterConfigurationGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/NetworkSecurityPerimeterConfigurationGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/NetworkSecurityPerimeterConfigurationGet.json // this example is just showing the usage of "NetworkSecurityPerimeterConfigurations_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_NetworkSecurityPerimeterConfigurationResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_NetworkSecurityPerimeterConfigurationResource.cs index 7b14285a7888..9738a7b4e555 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_NetworkSecurityPerimeterConfigurationResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_NetworkSecurityPerimeterConfigurationResource.cs @@ -19,7 +19,7 @@ public partial class Sample_NetworkSecurityPerimeterConfigurationResource [Ignore("Only validating compilation of examples")] public async Task Get_NetworkSecurityPerimeterConfigurationGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/NetworkSecurityPerimeterConfigurationGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/NetworkSecurityPerimeterConfigurationGet.json // this example is just showing the usage of "NetworkSecurityPerimeterConfigurations_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -50,7 +50,7 @@ public async Task Get_NetworkSecurityPerimeterConfigurationGet() [Ignore("Only validating compilation of examples")] public async Task Reconcile_NetworkSecurityPerimeterConfigurationReconcile() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/NetworkSecurityPerimeterConfigurationReconcile.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/NetworkSecurityPerimeterConfigurationReconcile.json // this example is just showing the usage of "NetworkSecurityPerimeterConfigurations_Reconcile" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_ObjectReplicationPolicyCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_ObjectReplicationPolicyCollection.cs index a77d9fb60e71..a6844e36ae72 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_ObjectReplicationPolicyCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_ObjectReplicationPolicyCollection.cs @@ -20,7 +20,7 @@ public partial class Sample_ObjectReplicationPolicyCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountCreateObjectReplicationPolicyOnDestination() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCreateObjectReplicationPolicyOnDestination.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCreateObjectReplicationPolicyOnDestination.json // this example is just showing the usage of "ObjectReplicationPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -52,6 +52,7 @@ public async Task CreateOrUpdate_StorageAccountCreateObjectReplicationPolicyOnDe PrefixMatch = {"blobA", "blobB"}, }, }}, + IsMetricsEnabled = true, }; ArmOperation lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, objectReplicationPolicyId, data); ObjectReplicationPolicyResource result = lro.Value; @@ -67,7 +68,7 @@ public async Task CreateOrUpdate_StorageAccountCreateObjectReplicationPolicyOnDe [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountCreateObjectReplicationPolicyOnSource() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCreateObjectReplicationPolicyOnSource.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCreateObjectReplicationPolicyOnSource.json // this example is just showing the usage of "ObjectReplicationPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -101,6 +102,7 @@ public async Task CreateOrUpdate_StorageAccountCreateObjectReplicationPolicyOnSo MinCreationTime = "2020-02-19T16:05:00Z", }, }}, + IsMetricsEnabled = true, }; ArmOperation lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, objectReplicationPolicyId, data); ObjectReplicationPolicyResource result = lro.Value; @@ -116,7 +118,7 @@ public async Task CreateOrUpdate_StorageAccountCreateObjectReplicationPolicyOnSo [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountUpdateObjectReplicationPolicyOnDestination() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountUpdateObjectReplicationPolicyOnDestination.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountUpdateObjectReplicationPolicyOnDestination.json // this example is just showing the usage of "ObjectReplicationPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -149,6 +151,7 @@ public async Task CreateOrUpdate_StorageAccountUpdateObjectReplicationPolicyOnDe PrefixMatch = {"blobA", "blobB"}, }, }, new ObjectReplicationPolicyRule("scont179", "dcont179")}, + IsMetricsEnabled = true, }; ArmOperation lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, objectReplicationPolicyId, data); ObjectReplicationPolicyResource result = lro.Value; @@ -164,7 +167,7 @@ public async Task CreateOrUpdate_StorageAccountUpdateObjectReplicationPolicyOnDe [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountUpdateObjectReplicationPolicyOnSource() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountUpdateObjectReplicationPolicyOnSource.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountUpdateObjectReplicationPolicyOnSource.json // this example is just showing the usage of "ObjectReplicationPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -200,6 +203,7 @@ public async Task CreateOrUpdate_StorageAccountUpdateObjectReplicationPolicyOnSo { RuleId = "cfbb4bc2-8b60-429f-b05a-d1e0942b33b2", }}, + IsMetricsEnabled = true, }; ArmOperation lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, objectReplicationPolicyId, data); ObjectReplicationPolicyResource result = lro.Value; @@ -215,7 +219,7 @@ public async Task CreateOrUpdate_StorageAccountUpdateObjectReplicationPolicyOnSo [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetObjectReplicationPolicies() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetObjectReplicationPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetObjectReplicationPolicy.json // this example is just showing the usage of "ObjectReplicationPolicies_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -249,7 +253,7 @@ public async Task Get_StorageAccountGetObjectReplicationPolicies() [Ignore("Only validating compilation of examples")] public async Task GetAll_StorageAccountListObjectReplicationPolicies() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountListObjectReplicationPolicies.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountListObjectReplicationPolicies.json // this example is just showing the usage of "ObjectReplicationPolicies_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -285,7 +289,7 @@ public async Task GetAll_StorageAccountListObjectReplicationPolicies() [Ignore("Only validating compilation of examples")] public async Task Exists_StorageAccountGetObjectReplicationPolicies() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetObjectReplicationPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetObjectReplicationPolicy.json // this example is just showing the usage of "ObjectReplicationPolicies_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -315,7 +319,7 @@ public async Task Exists_StorageAccountGetObjectReplicationPolicies() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_StorageAccountGetObjectReplicationPolicies() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetObjectReplicationPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetObjectReplicationPolicy.json // this example is just showing the usage of "ObjectReplicationPolicies_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_ObjectReplicationPolicyResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_ObjectReplicationPolicyResource.cs index 0a918528a430..fefc4fed5ca7 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_ObjectReplicationPolicyResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_ObjectReplicationPolicyResource.cs @@ -20,7 +20,7 @@ public partial class Sample_ObjectReplicationPolicyResource [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetObjectReplicationPolicies() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetObjectReplicationPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetObjectReplicationPolicy.json // this example is just showing the usage of "ObjectReplicationPolicies_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -51,7 +51,7 @@ public async Task Get_StorageAccountGetObjectReplicationPolicies() [Ignore("Only validating compilation of examples")] public async Task Delete_StorageAccountDeleteObjectReplicationPolicies() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountDeleteObjectReplicationPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountDeleteObjectReplicationPolicy.json // this example is just showing the usage of "ObjectReplicationPolicies_Delete" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -78,7 +78,7 @@ public async Task Delete_StorageAccountDeleteObjectReplicationPolicies() [Ignore("Only validating compilation of examples")] public async Task Update_StorageAccountCreateObjectReplicationPolicyOnDestination() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCreateObjectReplicationPolicyOnDestination.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCreateObjectReplicationPolicyOnDestination.json // this example is just showing the usage of "ObjectReplicationPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -107,6 +107,7 @@ public async Task Update_StorageAccountCreateObjectReplicationPolicyOnDestinatio PrefixMatch = {"blobA", "blobB"}, }, }}, + IsMetricsEnabled = true, }; ArmOperation lro = await objectReplicationPolicy.UpdateAsync(WaitUntil.Completed, data); ObjectReplicationPolicyResource result = lro.Value; @@ -122,7 +123,7 @@ public async Task Update_StorageAccountCreateObjectReplicationPolicyOnDestinatio [Ignore("Only validating compilation of examples")] public async Task Update_StorageAccountCreateObjectReplicationPolicyOnSource() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCreateObjectReplicationPolicyOnSource.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCreateObjectReplicationPolicyOnSource.json // this example is just showing the usage of "ObjectReplicationPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -153,6 +154,7 @@ public async Task Update_StorageAccountCreateObjectReplicationPolicyOnSource() MinCreationTime = "2020-02-19T16:05:00Z", }, }}, + IsMetricsEnabled = true, }; ArmOperation lro = await objectReplicationPolicy.UpdateAsync(WaitUntil.Completed, data); ObjectReplicationPolicyResource result = lro.Value; @@ -168,7 +170,7 @@ public async Task Update_StorageAccountCreateObjectReplicationPolicyOnSource() [Ignore("Only validating compilation of examples")] public async Task Update_StorageAccountUpdateObjectReplicationPolicyOnDestination() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountUpdateObjectReplicationPolicyOnDestination.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountUpdateObjectReplicationPolicyOnDestination.json // this example is just showing the usage of "ObjectReplicationPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -198,6 +200,7 @@ public async Task Update_StorageAccountUpdateObjectReplicationPolicyOnDestinatio PrefixMatch = {"blobA", "blobB"}, }, }, new ObjectReplicationPolicyRule("scont179", "dcont179")}, + IsMetricsEnabled = true, }; ArmOperation lro = await objectReplicationPolicy.UpdateAsync(WaitUntil.Completed, data); ObjectReplicationPolicyResource result = lro.Value; @@ -213,7 +216,7 @@ public async Task Update_StorageAccountUpdateObjectReplicationPolicyOnDestinatio [Ignore("Only validating compilation of examples")] public async Task Update_StorageAccountUpdateObjectReplicationPolicyOnSource() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountUpdateObjectReplicationPolicyOnSource.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountUpdateObjectReplicationPolicyOnSource.json // this example is just showing the usage of "ObjectReplicationPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -246,6 +249,7 @@ public async Task Update_StorageAccountUpdateObjectReplicationPolicyOnSource() { RuleId = "cfbb4bc2-8b60-429f-b05a-d1e0942b33b2", }}, + IsMetricsEnabled = true, }; ArmOperation lro = await objectReplicationPolicy.UpdateAsync(WaitUntil.Completed, data); ObjectReplicationPolicyResource result = lro.Value; diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_QueueServiceResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_QueueServiceResource.cs index 88b4468af096..b1cd8d31b809 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_QueueServiceResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_QueueServiceResource.cs @@ -20,7 +20,7 @@ public partial class Sample_QueueServiceResource [Ignore("Only validating compilation of examples")] public async Task Get_QueueServicesGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/QueueServicesGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/QueueServicesGet.json // this example is just showing the usage of "QueueServices_GetServiceProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -50,7 +50,7 @@ public async Task Get_QueueServicesGet() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_QueueServicesPut() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/QueueServicesPut.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/QueueServicesPut.json // this example is just showing the usage of "QueueServices_SetServiceProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountCollection.cs index 354428c98db6..ac69057508c5 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountCollection.cs @@ -23,7 +23,7 @@ public partial class Sample_StorageAccountCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_NfsV3AccountCreate() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/NfsV3AccountCreate.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/NfsV3AccountCreate.json // this example is just showing the usage of "StorageAccounts_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -70,7 +70,7 @@ public async Task CreateOrUpdate_NfsV3AccountCreate() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountCreate() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCreate.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCreate.json // this example is just showing the usage of "StorageAccounts_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -148,7 +148,7 @@ public async Task CreateOrUpdate_StorageAccountCreate() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountCreateAllowedCopyScopeToAAD() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCreateAllowedCopyScopeToAAD.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCreateAllowedCopyScopeToAAD.json // this example is just showing the usage of "StorageAccounts_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -221,7 +221,7 @@ public async Task CreateOrUpdate_StorageAccountCreateAllowedCopyScopeToAAD() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountCreateAllowedCopyScopeToPrivateLink() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCreateAllowedCopyScopeToPrivateLink.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCreateAllowedCopyScopeToPrivateLink.json // this example is just showing the usage of "StorageAccounts_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -294,7 +294,7 @@ public async Task CreateOrUpdate_StorageAccountCreateAllowedCopyScopeToPrivateLi [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountCreateDisallowPublicNetworkAccess() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCreateDisallowPublicNetworkAccess.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCreateDisallowPublicNetworkAccess.json // this example is just showing the usage of "StorageAccounts_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -371,7 +371,7 @@ public async Task CreateOrUpdate_StorageAccountCreateDisallowPublicNetworkAccess [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountCreateDnsEndpointTypeToAzureDnsZone() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCreateDnsEndpointTypeToAzureDnsZone.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCreateDnsEndpointTypeToAzureDnsZone.json // this example is just showing the usage of "StorageAccounts_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -450,7 +450,7 @@ public async Task CreateOrUpdate_StorageAccountCreateDnsEndpointTypeToAzureDnsZo [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountCreateDnsEndpointTypeToStandard() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCreateDnsEndpointTypeToStandard.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCreateDnsEndpointTypeToStandard.json // this example is just showing the usage of "StorageAccounts_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -529,7 +529,7 @@ public async Task CreateOrUpdate_StorageAccountCreateDnsEndpointTypeToStandard() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountCreateEnablePublicNetworkAccess() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCreateEnablePublicNetworkAccess.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCreateEnablePublicNetworkAccess.json // this example is just showing the usage of "StorageAccounts_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -606,7 +606,7 @@ public async Task CreateOrUpdate_StorageAccountCreateEnablePublicNetworkAccess() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountCreatePremiumBlockBlobStorage() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCreatePremiumBlockBlobStorage.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCreatePremiumBlockBlobStorage.json // this example is just showing the usage of "StorageAccounts_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -668,7 +668,7 @@ public async Task CreateOrUpdate_StorageAccountCreatePremiumBlockBlobStorage() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountCreateUserAssignedEncryptionIdentityWithCMK() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCreateUserAssignedEncryptionIdentityWithCMK.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCreateUserAssignedEncryptionIdentityWithCMK.json // this example is just showing the usage of "StorageAccounts_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -739,7 +739,7 @@ public async Task CreateOrUpdate_StorageAccountCreateUserAssignedEncryptionIdent [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountCreateUserAssignedIdentityWithFederatedIdentityClientId() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCreateUserAssignedIdentityWithFederatedIdentityClientId.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCreateUserAssignedIdentityWithFederatedIdentityClientId.json // this example is just showing the usage of "StorageAccounts_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -811,7 +811,7 @@ public async Task CreateOrUpdate_StorageAccountCreateUserAssignedIdentityWithFed [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountCreateWithImmutabilityPolicy() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCreateWithImmutabilityPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCreateWithImmutabilityPolicy.json // this example is just showing the usage of "StorageAccounts_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -862,7 +862,7 @@ public async Task CreateOrUpdate_StorageAccountCreateWithImmutabilityPolicy() [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetAsyncSkuConversionStatus() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetAsyncSkuConversionStatus.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetAsyncSkuConversionStatus.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -895,7 +895,7 @@ public async Task Get_StorageAccountGetAsyncSkuConversionStatus() [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetProperties() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetProperties.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetProperties.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -928,7 +928,7 @@ public async Task Get_StorageAccountGetProperties() [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetPropertiesCMKEnabled() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesCMKEnabled.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesCMKEnabled.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -961,7 +961,7 @@ public async Task Get_StorageAccountGetPropertiesCMKEnabled() [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetPropertiesCMKVersionExpirationTime() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesCMKVersionExpirationTime.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesCMKVersionExpirationTime.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -994,7 +994,7 @@ public async Task Get_StorageAccountGetPropertiesCMKVersionExpirationTime() [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetPropertiesGeoReplicationStatscanFailoverFalse() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverFalse.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverFalse.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1028,7 +1028,7 @@ public async Task Get_StorageAccountGetPropertiesGeoReplicationStatscanFailoverF [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetPropertiesGeoReplicationStatscanFailoverTrue() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverTrue.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverTrue.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1062,7 +1062,7 @@ public async Task Get_StorageAccountGetPropertiesGeoReplicationStatscanFailoverT [Ignore("Only validating compilation of examples")] public async Task GetAll_StorageAccountListByResourceGroup() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountListByResourceGroup.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountListByResourceGroup.json // this example is just showing the usage of "StorageAccounts_ListByResourceGroup" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1097,7 +1097,7 @@ public async Task GetAll_StorageAccountListByResourceGroup() [Ignore("Only validating compilation of examples")] public async Task Exists_StorageAccountGetAsyncSkuConversionStatus() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetAsyncSkuConversionStatus.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetAsyncSkuConversionStatus.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1126,7 +1126,7 @@ public async Task Exists_StorageAccountGetAsyncSkuConversionStatus() [Ignore("Only validating compilation of examples")] public async Task Exists_StorageAccountGetProperties() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetProperties.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetProperties.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1155,7 +1155,7 @@ public async Task Exists_StorageAccountGetProperties() [Ignore("Only validating compilation of examples")] public async Task Exists_StorageAccountGetPropertiesCMKEnabled() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesCMKEnabled.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesCMKEnabled.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1184,7 +1184,7 @@ public async Task Exists_StorageAccountGetPropertiesCMKEnabled() [Ignore("Only validating compilation of examples")] public async Task Exists_StorageAccountGetPropertiesCMKVersionExpirationTime() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesCMKVersionExpirationTime.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesCMKVersionExpirationTime.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1213,7 +1213,7 @@ public async Task Exists_StorageAccountGetPropertiesCMKVersionExpirationTime() [Ignore("Only validating compilation of examples")] public async Task Exists_StorageAccountGetPropertiesGeoReplicationStatscanFailoverFalse() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverFalse.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverFalse.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1243,7 +1243,7 @@ public async Task Exists_StorageAccountGetPropertiesGeoReplicationStatscanFailov [Ignore("Only validating compilation of examples")] public async Task Exists_StorageAccountGetPropertiesGeoReplicationStatscanFailoverTrue() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverTrue.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverTrue.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1273,7 +1273,7 @@ public async Task Exists_StorageAccountGetPropertiesGeoReplicationStatscanFailov [Ignore("Only validating compilation of examples")] public async Task GetIfExists_StorageAccountGetAsyncSkuConversionStatus() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetAsyncSkuConversionStatus.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetAsyncSkuConversionStatus.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1314,7 +1314,7 @@ public async Task GetIfExists_StorageAccountGetAsyncSkuConversionStatus() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_StorageAccountGetProperties() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetProperties.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetProperties.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1355,7 +1355,7 @@ public async Task GetIfExists_StorageAccountGetProperties() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_StorageAccountGetPropertiesCMKEnabled() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesCMKEnabled.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesCMKEnabled.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1396,7 +1396,7 @@ public async Task GetIfExists_StorageAccountGetPropertiesCMKEnabled() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_StorageAccountGetPropertiesCMKVersionExpirationTime() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesCMKVersionExpirationTime.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesCMKVersionExpirationTime.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1437,7 +1437,7 @@ public async Task GetIfExists_StorageAccountGetPropertiesCMKVersionExpirationTim [Ignore("Only validating compilation of examples")] public async Task GetIfExists_StorageAccountGetPropertiesGeoReplicationStatscanFailoverFalse() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverFalse.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverFalse.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1479,7 +1479,7 @@ public async Task GetIfExists_StorageAccountGetPropertiesGeoReplicationStatscanF [Ignore("Only validating compilation of examples")] public async Task GetIfExists_StorageAccountGetPropertiesGeoReplicationStatscanFailoverTrue() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverTrue.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverTrue.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountLocalUserCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountLocalUserCollection.cs index 9eecc797578d..8acf78961fdc 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountLocalUserCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountLocalUserCollection.cs @@ -20,7 +20,7 @@ public partial class Sample_StorageAccountLocalUserCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_CreateLocalUser() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/LocalUserCreate.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/LocalUserCreate.json // this example is just showing the usage of "LocalUsers_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -68,7 +68,7 @@ public async Task CreateOrUpdate_CreateLocalUser() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_CreateNFSv3EnabledLocalUser() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/LocalUserCreateNFSv3Enabled.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/LocalUserCreateNFSv3Enabled.json // this example is just showing the usage of "LocalUsers_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -108,7 +108,7 @@ public async Task CreateOrUpdate_CreateNFSv3EnabledLocalUser() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_UpdateLocalUser() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/LocalUserUpdate.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/LocalUserUpdate.json // this example is just showing the usage of "LocalUsers_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -154,7 +154,7 @@ public async Task CreateOrUpdate_UpdateLocalUser() [Ignore("Only validating compilation of examples")] public async Task Get_GetLocalUser() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/LocalUserGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/LocalUserGet.json // this example is just showing the usage of "LocalUsers_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -188,7 +188,7 @@ public async Task Get_GetLocalUser() [Ignore("Only validating compilation of examples")] public async Task GetAll_ListLocalUsers() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/LocalUsersList.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/LocalUsersList.json // this example is just showing the usage of "LocalUsers_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -224,7 +224,7 @@ public async Task GetAll_ListLocalUsers() [Ignore("Only validating compilation of examples")] public async Task GetAll_ListNFSv3EnabledLocalUsers() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/LocalUsersListNFSv3Enabled.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/LocalUsersListNFSv3Enabled.json // this example is just showing the usage of "LocalUsers_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -261,7 +261,7 @@ public async Task GetAll_ListNFSv3EnabledLocalUsers() [Ignore("Only validating compilation of examples")] public async Task Exists_GetLocalUser() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/LocalUserGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/LocalUserGet.json // this example is just showing the usage of "LocalUsers_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -291,7 +291,7 @@ public async Task Exists_GetLocalUser() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_GetLocalUser() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/LocalUserGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/LocalUserGet.json // this example is just showing the usage of "LocalUsers_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountLocalUserResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountLocalUserResource.cs index cc9a25a9052e..277bde868067 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountLocalUserResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountLocalUserResource.cs @@ -20,7 +20,7 @@ public partial class Sample_StorageAccountLocalUserResource [Ignore("Only validating compilation of examples")] public async Task Get_GetLocalUser() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/LocalUserGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/LocalUserGet.json // this example is just showing the usage of "LocalUsers_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -51,7 +51,7 @@ public async Task Get_GetLocalUser() [Ignore("Only validating compilation of examples")] public async Task Delete_DeleteLocalUser() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/LocalUserDelete.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/LocalUserDelete.json // this example is just showing the usage of "LocalUsers_Delete" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -78,7 +78,7 @@ public async Task Delete_DeleteLocalUser() [Ignore("Only validating compilation of examples")] public async Task Update_CreateLocalUser() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/LocalUserCreate.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/LocalUserCreate.json // this example is just showing the usage of "LocalUsers_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -123,7 +123,7 @@ public async Task Update_CreateLocalUser() [Ignore("Only validating compilation of examples")] public async Task Update_CreateNFSv3EnabledLocalUser() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/LocalUserCreateNFSv3Enabled.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/LocalUserCreateNFSv3Enabled.json // this example is just showing the usage of "LocalUsers_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -160,7 +160,7 @@ public async Task Update_CreateNFSv3EnabledLocalUser() [Ignore("Only validating compilation of examples")] public async Task Update_UpdateLocalUser() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/LocalUserUpdate.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/LocalUserUpdate.json // this example is just showing the usage of "LocalUsers_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -203,7 +203,7 @@ public async Task Update_UpdateLocalUser() [Ignore("Only validating compilation of examples")] public async Task GetKeys_ListLocalUserKeys() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/LocalUserListKeys.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/LocalUserListKeys.json // this example is just showing the usage of "LocalUsers_ListKeys" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -230,7 +230,7 @@ public async Task GetKeys_ListLocalUserKeys() [Ignore("Only validating compilation of examples")] public async Task RegeneratePassword_RegenerateLocalUserPassword() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/LocalUserRegeneratePassword.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/LocalUserRegeneratePassword.json // this example is just showing the usage of "LocalUsers_RegeneratePassword" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountManagementPolicyResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountManagementPolicyResource.cs index 9e3aa4f52bbb..3b196259fefd 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountManagementPolicyResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountManagementPolicyResource.cs @@ -20,7 +20,7 @@ public partial class Sample_StorageAccountManagementPolicyResource [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetManagementPolicies() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetManagementPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetManagementPolicy.json // this example is just showing the usage of "ManagementPolicies_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -51,7 +51,7 @@ public async Task Get_StorageAccountGetManagementPolicies() [Ignore("Only validating compilation of examples")] public async Task Delete_StorageAccountDeleteManagementPolicies() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountDeleteManagementPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountDeleteManagementPolicy.json // this example is just showing the usage of "ManagementPolicies_Delete" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -78,7 +78,7 @@ public async Task Delete_StorageAccountDeleteManagementPolicies() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountSetManagementPolicies() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountSetManagementPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountSetManagementPolicy.json // this example is just showing the usage of "ManagementPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -171,7 +171,7 @@ public async Task CreateOrUpdate_StorageAccountSetManagementPolicies() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountSetManagementPolicyColdTierActions() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountSetManagementPolicyColdTierActions.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountSetManagementPolicyColdTierActions.json // this example is just showing the usage of "ManagementPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -247,7 +247,7 @@ public async Task CreateOrUpdate_StorageAccountSetManagementPolicyColdTierAction [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountSetManagementPolicyForBlockAndAppendBlobs() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountSetManagementPolicyForBlockAndAppendBlobs.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountSetManagementPolicyForBlockAndAppendBlobs.json // this example is just showing the usage of "ManagementPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -309,7 +309,7 @@ public async Task CreateOrUpdate_StorageAccountSetManagementPolicyForBlockAndApp [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountSetManagementPolicyHotTierActions() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountSetManagementPolicyHotTierActions.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountSetManagementPolicyHotTierActions.json // this example is just showing the usage of "ManagementPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -371,7 +371,7 @@ public async Task CreateOrUpdate_StorageAccountSetManagementPolicyHotTierActions [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountSetManagementPolicyWithSnapshotAndVersion() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountSetManagementPolicyWithSnapshotAndVersion.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountSetManagementPolicyWithSnapshotAndVersion.json // this example is just showing the usage of "ManagementPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -445,7 +445,7 @@ public async Task CreateOrUpdate_StorageAccountSetManagementPolicyWithSnapshotAn [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountSetManagementPolicyBaseBlobDaysAfterCreationActions() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountSetManagementPolicy_BaseBlobDaysAfterCreationActions.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountSetManagementPolicy_BaseBlobDaysAfterCreationActions.json // this example is just showing the usage of "ManagementPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -507,7 +507,7 @@ public async Task CreateOrUpdate_StorageAccountSetManagementPolicyBaseBlobDaysAf [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountSetManagementPolicyLastAccessTimeBasedBlobActions() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountSetManagementPolicy_LastAccessTimeBasedBlobActions.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountSetManagementPolicy_LastAccessTimeBasedBlobActions.json // this example is just showing the usage of "ManagementPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -574,7 +574,7 @@ public async Task CreateOrUpdate_StorageAccountSetManagementPolicyLastAccessTime [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountSetManagementPolicyLastTierChangeTimeActions() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountSetManagementPolicy_LastTierChangeTimeActions.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountSetManagementPolicy_LastTierChangeTimeActions.json // this example is just showing the usage of "ManagementPolicies_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountMigrationCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountMigrationCollection.cs index 838e79eabab2..8be6170e8a7f 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountMigrationCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountMigrationCollection.cs @@ -20,7 +20,7 @@ public partial class Sample_StorageAccountMigrationCollection [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetMigrationFailed() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetMigrationFailed.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetMigrationFailed.json // this example is just showing the usage of "StorageAccounts_GetCustomerInitiatedMigration" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -54,7 +54,7 @@ public async Task Get_StorageAccountGetMigrationFailed() [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetMigrationInProgress() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetMigrationInProgress.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetMigrationInProgress.json // this example is just showing the usage of "StorageAccounts_GetCustomerInitiatedMigration" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -88,7 +88,7 @@ public async Task Get_StorageAccountGetMigrationInProgress() [Ignore("Only validating compilation of examples")] public async Task Exists_StorageAccountGetMigrationFailed() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetMigrationFailed.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetMigrationFailed.json // this example is just showing the usage of "StorageAccounts_GetCustomerInitiatedMigration" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -118,7 +118,7 @@ public async Task Exists_StorageAccountGetMigrationFailed() [Ignore("Only validating compilation of examples")] public async Task Exists_StorageAccountGetMigrationInProgress() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetMigrationInProgress.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetMigrationInProgress.json // this example is just showing the usage of "StorageAccounts_GetCustomerInitiatedMigration" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -148,7 +148,7 @@ public async Task Exists_StorageAccountGetMigrationInProgress() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_StorageAccountGetMigrationFailed() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetMigrationFailed.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetMigrationFailed.json // this example is just showing the usage of "StorageAccounts_GetCustomerInitiatedMigration" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -190,7 +190,7 @@ public async Task GetIfExists_StorageAccountGetMigrationFailed() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_StorageAccountGetMigrationInProgress() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetMigrationInProgress.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetMigrationInProgress.json // this example is just showing the usage of "StorageAccounts_GetCustomerInitiatedMigration" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountMigrationResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountMigrationResource.cs index c4ac629f4849..354e423f660c 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountMigrationResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountMigrationResource.cs @@ -20,7 +20,7 @@ public partial class Sample_StorageAccountMigrationResource [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetMigrationFailed() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetMigrationFailed.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetMigrationFailed.json // this example is just showing the usage of "StorageAccounts_GetCustomerInitiatedMigration" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -51,7 +51,7 @@ public async Task Get_StorageAccountGetMigrationFailed() [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetMigrationInProgress() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetMigrationInProgress.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetMigrationInProgress.json // this example is just showing the usage of "StorageAccounts_GetCustomerInitiatedMigration" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountResource.cs index ff4b8d1f5398..ff8ef6f7d42f 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageAccountResource.cs @@ -21,7 +21,7 @@ public partial class Sample_StorageAccountResource [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetAsyncSkuConversionStatus() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetAsyncSkuConversionStatus.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetAsyncSkuConversionStatus.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -51,7 +51,7 @@ public async Task Get_StorageAccountGetAsyncSkuConversionStatus() [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetProperties() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetProperties.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetProperties.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -81,7 +81,7 @@ public async Task Get_StorageAccountGetProperties() [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetPropertiesCMKEnabled() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesCMKEnabled.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesCMKEnabled.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -111,7 +111,7 @@ public async Task Get_StorageAccountGetPropertiesCMKEnabled() [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetPropertiesCMKVersionExpirationTime() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesCMKVersionExpirationTime.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesCMKVersionExpirationTime.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -141,7 +141,7 @@ public async Task Get_StorageAccountGetPropertiesCMKVersionExpirationTime() [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetPropertiesGeoReplicationStatscanFailoverFalse() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverFalse.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverFalse.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -172,7 +172,7 @@ public async Task Get_StorageAccountGetPropertiesGeoReplicationStatscanFailoverF [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetPropertiesGeoReplicationStatscanFailoverTrue() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverTrue.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPropertiesGeoReplicationStatscanFailoverTrue.json // this example is just showing the usage of "StorageAccounts_GetProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -203,7 +203,7 @@ public async Task Get_StorageAccountGetPropertiesGeoReplicationStatscanFailoverT [Ignore("Only validating compilation of examples")] public async Task Delete_StorageAccountDelete() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountDelete.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountDelete.json // this example is just showing the usage of "StorageAccounts_Delete" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -229,7 +229,7 @@ public async Task Delete_StorageAccountDelete() [Ignore("Only validating compilation of examples")] public async Task Update_StorageAccountEnableAD() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountEnableAD.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountEnableAD.json // this example is just showing the usage of "StorageAccounts_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -274,7 +274,7 @@ public async Task Update_StorageAccountEnableAD() [Ignore("Only validating compilation of examples")] public async Task Update_StorageAccountEnableCMK() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountEnableCMK.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountEnableCMK.json // this example is just showing the usage of "StorageAccounts_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -330,7 +330,7 @@ public async Task Update_StorageAccountEnableCMK() [Ignore("Only validating compilation of examples")] public async Task Update_StorageAccountUpdate() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountUpdate.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountUpdate.json // this example is just showing the usage of "StorageAccounts_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -403,7 +403,7 @@ public async Task Update_StorageAccountUpdate() [Ignore("Only validating compilation of examples")] public async Task Update_StorageAccountUpdateAllowedCopyScopeToAAD() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountUpdateAllowedCopyScopeToAAD.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountUpdateAllowedCopyScopeToAAD.json // this example is just showing the usage of "StorageAccounts_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -473,7 +473,7 @@ public async Task Update_StorageAccountUpdateAllowedCopyScopeToAAD() [Ignore("Only validating compilation of examples")] public async Task Update_StorageAccountUpdateDisablePublicNetworkAccess() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountUpdateDisablePublicNetworkAccess.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountUpdateDisablePublicNetworkAccess.json // this example is just showing the usage of "StorageAccounts_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -543,7 +543,7 @@ public async Task Update_StorageAccountUpdateDisablePublicNetworkAccess() [Ignore("Only validating compilation of examples")] public async Task Update_StorageAccountUpdateUserAssignedEncryptionIdentityWithCMK() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountUpdateUserAssignedEncryptionIdentityWithCMK.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountUpdateUserAssignedEncryptionIdentityWithCMK.json // this example is just showing the usage of "StorageAccounts_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -612,7 +612,7 @@ public async Task Update_StorageAccountUpdateUserAssignedEncryptionIdentityWithC [Ignore("Only validating compilation of examples")] public async Task Update_StorageAccountUpdateUserAssignedIdentityWithFederatedIdentityClientId() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountUpdateUserAssignedIdentityWithFederatedIdentityClientId.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountUpdateUserAssignedIdentityWithFederatedIdentityClientId.json // this example is just showing the usage of "StorageAccounts_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -682,7 +682,7 @@ public async Task Update_StorageAccountUpdateUserAssignedIdentityWithFederatedId [Ignore("Only validating compilation of examples")] public async Task Update_StorageAccountUpdateWithImmutabilityPolicy() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountUpdateWithImmutabilityPolicy.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountUpdateWithImmutabilityPolicy.json // this example is just showing the usage of "StorageAccounts_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -725,7 +725,7 @@ public async Task Update_StorageAccountUpdateWithImmutabilityPolicy() [Ignore("Only validating compilation of examples")] public async Task GetKeys_StorageAccountListKeys() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountListKeys.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountListKeys.json // this example is just showing the usage of "StorageAccounts_ListKeys" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -754,7 +754,7 @@ public async Task GetKeys_StorageAccountListKeys() [Ignore("Only validating compilation of examples")] public async Task RegenerateKey_StorageAccountRegenerateKerbKey() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountRegenerateKerbKey.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountRegenerateKerbKey.json // this example is just showing the usage of "StorageAccounts_RegenerateKey" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -784,7 +784,7 @@ public async Task RegenerateKey_StorageAccountRegenerateKerbKey() [Ignore("Only validating compilation of examples")] public async Task RegenerateKey_StorageAccountRegenerateKey() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountRegenerateKey.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountRegenerateKey.json // this example is just showing the usage of "StorageAccounts_RegenerateKey" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -814,7 +814,7 @@ public async Task RegenerateKey_StorageAccountRegenerateKey() [Ignore("Only validating compilation of examples")] public async Task GetAccountSas_StorageAccountListAccountSAS() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountListAccountSAS.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountListAccountSAS.json // this example is just showing the usage of "StorageAccounts_ListAccountSas" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -846,7 +846,7 @@ public async Task GetAccountSas_StorageAccountListAccountSAS() [Ignore("Only validating compilation of examples")] public async Task GetServiceSas_StorageAccountListServiceSAS() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountListServiceSAS.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountListServiceSAS.json // this example is just showing the usage of "StorageAccounts_ListServiceSas" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -878,7 +878,7 @@ public async Task GetServiceSas_StorageAccountListServiceSAS() [Ignore("Only validating compilation of examples")] public async Task Failover_StorageAccountFailover() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountFailover.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountFailover.json // this example is just showing the usage of "StorageAccounts_Failover" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -904,7 +904,7 @@ public async Task Failover_StorageAccountFailover() [Ignore("Only validating compilation of examples")] public async Task Failover_StorageAccountFailoverPlanned() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountFailoverPlanned.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountFailoverPlanned.json // this example is just showing the usage of "StorageAccounts_Failover" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -931,7 +931,7 @@ public async Task Failover_StorageAccountFailoverPlanned() [Ignore("Only validating compilation of examples")] public async Task EnableHierarchicalNamespace_StorageAccountHierarchicalNamespaceMigration() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountHierarchicalNamespaceMigration.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountHierarchicalNamespaceMigration.json // this example is just showing the usage of "StorageAccounts_HierarchicalNamespaceMigration" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -958,7 +958,7 @@ public async Task EnableHierarchicalNamespace_StorageAccountHierarchicalNamespac [Ignore("Only validating compilation of examples")] public async Task AbortHierarchicalNamespaceMigration_StorageAccountAbortHierarchicalNamespaceMigration() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountAbortHierarchicalNamespaceMigration.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountAbortHierarchicalNamespaceMigration.json // this example is just showing the usage of "StorageAccounts_AbortHierarchicalNamespaceMigration" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -984,7 +984,7 @@ public async Task AbortHierarchicalNamespaceMigration_StorageAccountAbortHierarc [Ignore("Only validating compilation of examples")] public async Task CustomerInitiatedMigration_StorageAccountPostMigration() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountPostMigration.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountPostMigration.json // this example is just showing the usage of "StorageAccounts_CustomerInitiatedMigration" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1011,7 +1011,7 @@ public async Task CustomerInitiatedMigration_StorageAccountPostMigration() [Ignore("Only validating compilation of examples")] public async Task RestoreBlobRanges_BlobRangesRestore() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/BlobRangesRestore.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/BlobRangesRestore.json // this example is just showing the usage of "StorageAccounts_RestoreBlobRanges" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1043,7 +1043,7 @@ public async Task RestoreBlobRanges_BlobRangesRestore() [Ignore("Only validating compilation of examples")] public async Task RevokeUserDelegationKeys_StorageAccountRevokeUserDelegationKeys() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountRevokeUserDelegationKeys.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountRevokeUserDelegationKeys.json // this example is just showing the usage of "StorageAccounts_RevokeUserDelegationKeys" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1069,7 +1069,7 @@ public async Task RevokeUserDelegationKeys_StorageAccountRevokeUserDelegationKey [Ignore("Only validating compilation of examples")] public async Task GetPrivateLinkResources_StorageAccountListPrivateLinkResources() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountListPrivateLinkResources.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountListPrivateLinkResources.json // this example is just showing the usage of "PrivateLinkResources_ListByStorageAccount" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -1098,7 +1098,7 @@ public async Task GetPrivateLinkResources_StorageAccountListPrivateLinkResources [Ignore("Only validating compilation of examples")] public async Task GetStorageTaskAssignmentsInstancesReports_ListStorageTaskAssignmentsInstancesReportSummary() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/storageTaskAssignmentsList/ListStorageTaskAssignmentsInstancesReportSummary.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/storageTaskAssignmentsList/ListStorageTaskAssignmentsInstancesReportSummary.json // this example is just showing the usage of "StorageTaskAssignmentsInstancesReport_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StoragePrivateEndpointConnectionCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StoragePrivateEndpointConnectionCollection.cs index 46cb9cb65056..bf4bb090ee30 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StoragePrivateEndpointConnectionCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StoragePrivateEndpointConnectionCollection.cs @@ -20,7 +20,7 @@ public partial class Sample_StoragePrivateEndpointConnectionCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_StorageAccountPutPrivateEndpointConnection() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountPutPrivateEndpointConnection.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountPutPrivateEndpointConnection.json // this example is just showing the usage of "PrivateEndpointConnections_Put" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -63,7 +63,7 @@ public async Task CreateOrUpdate_StorageAccountPutPrivateEndpointConnection() [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetPrivateEndpointConnection() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPrivateEndpointConnection.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPrivateEndpointConnection.json // this example is just showing the usage of "PrivateEndpointConnections_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -97,7 +97,7 @@ public async Task Get_StorageAccountGetPrivateEndpointConnection() [Ignore("Only validating compilation of examples")] public async Task GetAll_StorageAccountListPrivateEndpointConnections() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountListPrivateEndpointConnections.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountListPrivateEndpointConnections.json // this example is just showing the usage of "PrivateEndpointConnections_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -133,7 +133,7 @@ public async Task GetAll_StorageAccountListPrivateEndpointConnections() [Ignore("Only validating compilation of examples")] public async Task Exists_StorageAccountGetPrivateEndpointConnection() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPrivateEndpointConnection.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPrivateEndpointConnection.json // this example is just showing the usage of "PrivateEndpointConnections_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -163,7 +163,7 @@ public async Task Exists_StorageAccountGetPrivateEndpointConnection() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_StorageAccountGetPrivateEndpointConnection() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPrivateEndpointConnection.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPrivateEndpointConnection.json // this example is just showing the usage of "PrivateEndpointConnections_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StoragePrivateEndpointConnectionResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StoragePrivateEndpointConnectionResource.cs index 2f3f8fe1d741..bc5b65de4398 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StoragePrivateEndpointConnectionResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StoragePrivateEndpointConnectionResource.cs @@ -20,7 +20,7 @@ public partial class Sample_StoragePrivateEndpointConnectionResource [Ignore("Only validating compilation of examples")] public async Task Get_StorageAccountGetPrivateEndpointConnection() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountGetPrivateEndpointConnection.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountGetPrivateEndpointConnection.json // this example is just showing the usage of "PrivateEndpointConnections_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -51,7 +51,7 @@ public async Task Get_StorageAccountGetPrivateEndpointConnection() [Ignore("Only validating compilation of examples")] public async Task Delete_StorageAccountDeletePrivateEndpointConnection() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountDeletePrivateEndpointConnection.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountDeletePrivateEndpointConnection.json // this example is just showing the usage of "PrivateEndpointConnections_Delete" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -78,7 +78,7 @@ public async Task Delete_StorageAccountDeletePrivateEndpointConnection() [Ignore("Only validating compilation of examples")] public async Task Update_StorageAccountPutPrivateEndpointConnection() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountPutPrivateEndpointConnection.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountPutPrivateEndpointConnection.json // this example is just showing the usage of "PrivateEndpointConnections_Put" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageQueueCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageQueueCollection.cs index 8ad7a0c4c25f..5700f3c9f394 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageQueueCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageQueueCollection.cs @@ -19,7 +19,7 @@ public partial class Sample_StorageQueueCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_QueueOperationPut() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/QueueOperationPut.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/QueueOperationPut.json // this example is just showing the usage of "Queue_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -55,7 +55,7 @@ public async Task CreateOrUpdate_QueueOperationPut() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_QueueOperationPutWithMetadata() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/QueueOperationPutWithMetadata.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/QueueOperationPutWithMetadata.json // this example is just showing the usage of "Queue_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -98,7 +98,7 @@ public async Task CreateOrUpdate_QueueOperationPutWithMetadata() [Ignore("Only validating compilation of examples")] public async Task Get_QueueOperationGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/QueueOperationGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/QueueOperationGet.json // this example is just showing the usage of "Queue_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -132,7 +132,7 @@ public async Task Get_QueueOperationGet() [Ignore("Only validating compilation of examples")] public async Task GetAll_QueueOperationList() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/QueueOperationList.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/QueueOperationList.json // this example is just showing the usage of "Queue_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -168,7 +168,7 @@ public async Task GetAll_QueueOperationList() [Ignore("Only validating compilation of examples")] public async Task Exists_QueueOperationGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/QueueOperationGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/QueueOperationGet.json // this example is just showing the usage of "Queue_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -198,7 +198,7 @@ public async Task Exists_QueueOperationGet() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_QueueOperationGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/QueueOperationGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/QueueOperationGet.json // this example is just showing the usage of "Queue_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageQueueResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageQueueResource.cs index ba6e3a4e4d6e..8d73e2d027f6 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageQueueResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageQueueResource.cs @@ -19,7 +19,7 @@ public partial class Sample_StorageQueueResource [Ignore("Only validating compilation of examples")] public async Task Get_QueueOperationGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/QueueOperationGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/QueueOperationGet.json // this example is just showing the usage of "Queue_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -50,7 +50,7 @@ public async Task Get_QueueOperationGet() [Ignore("Only validating compilation of examples")] public async Task Delete_QueueOperationDelete() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/QueueOperationDelete.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/QueueOperationDelete.json // this example is just showing the usage of "Queue_Delete" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -77,7 +77,7 @@ public async Task Delete_QueueOperationDelete() [Ignore("Only validating compilation of examples")] public async Task Update_QueueOperationPatch() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/QueueOperationPatch.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/QueueOperationPatch.json // this example is just showing the usage of "Queue_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageTaskAssignmentCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageTaskAssignmentCollection.cs index 8e63ae6b7749..44daf8208a75 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageTaskAssignmentCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageTaskAssignmentCollection.cs @@ -20,7 +20,7 @@ public partial class Sample_StorageTaskAssignmentCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_PutStorageTaskAssignment() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/storageTaskAssignmentsCrud/PutStorageTaskAssignment.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/storageTaskAssignmentsCrud/PutStorageTaskAssignment.json // this example is just showing the usage of "StorageTaskAssignments_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -66,7 +66,7 @@ public async Task CreateOrUpdate_PutStorageTaskAssignment() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_PutStorageTaskAssignmentRequiredProperties() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/storageTaskAssignmentsCrud/PutStorageTaskAssignmentRequiredProperties.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/storageTaskAssignmentsCrud/PutStorageTaskAssignmentRequiredProperties.json // this example is just showing the usage of "StorageTaskAssignments_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -105,7 +105,7 @@ public async Task CreateOrUpdate_PutStorageTaskAssignmentRequiredProperties() [Ignore("Only validating compilation of examples")] public async Task Get_GetStorageTaskAssignment() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/storageTaskAssignmentsCrud/GetStorageTaskAssignment.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/storageTaskAssignmentsCrud/GetStorageTaskAssignment.json // this example is just showing the usage of "StorageTaskAssignments_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -139,7 +139,7 @@ public async Task Get_GetStorageTaskAssignment() [Ignore("Only validating compilation of examples")] public async Task GetAll_ListStorageTaskAssignmentsForAccount() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/storageTaskAssignmentsList/ListStorageTaskAssignmentsForAccount.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/storageTaskAssignmentsList/ListStorageTaskAssignmentsForAccount.json // this example is just showing the usage of "StorageTaskAssignments_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -175,7 +175,7 @@ public async Task GetAll_ListStorageTaskAssignmentsForAccount() [Ignore("Only validating compilation of examples")] public async Task Exists_GetStorageTaskAssignment() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/storageTaskAssignmentsCrud/GetStorageTaskAssignment.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/storageTaskAssignmentsCrud/GetStorageTaskAssignment.json // this example is just showing the usage of "StorageTaskAssignments_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -205,7 +205,7 @@ public async Task Exists_GetStorageTaskAssignment() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_GetStorageTaskAssignment() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/storageTaskAssignmentsCrud/GetStorageTaskAssignment.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/storageTaskAssignmentsCrud/GetStorageTaskAssignment.json // this example is just showing the usage of "StorageTaskAssignments_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageTaskAssignmentResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageTaskAssignmentResource.cs index b9bb8bba4789..d04a326dc47b 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageTaskAssignmentResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_StorageTaskAssignmentResource.cs @@ -20,7 +20,7 @@ public partial class Sample_StorageTaskAssignmentResource [Ignore("Only validating compilation of examples")] public async Task Get_GetStorageTaskAssignment() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/storageTaskAssignmentsCrud/GetStorageTaskAssignment.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/storageTaskAssignmentsCrud/GetStorageTaskAssignment.json // this example is just showing the usage of "StorageTaskAssignments_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -51,7 +51,7 @@ public async Task Get_GetStorageTaskAssignment() [Ignore("Only validating compilation of examples")] public async Task Delete_DeleteStorageTaskAssignment() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/storageTaskAssignmentsCrud/DeleteStorageTaskAssignment.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/storageTaskAssignmentsCrud/DeleteStorageTaskAssignment.json // this example is just showing the usage of "StorageTaskAssignments_Delete" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -78,7 +78,7 @@ public async Task Delete_DeleteStorageTaskAssignment() [Ignore("Only validating compilation of examples")] public async Task Update_PatchStorageTaskAssignment() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/storageTaskAssignmentsCrud/PatchStorageTaskAssignment.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/storageTaskAssignmentsCrud/PatchStorageTaskAssignment.json // this example is just showing the usage of "StorageTaskAssignments_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -135,7 +135,7 @@ public async Task Update_PatchStorageTaskAssignment() [Ignore("Only validating compilation of examples")] public async Task GetStorageTaskAssignmentInstancesReports_ListStorageTaskAssignmentInstancesReportSummary() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/storageTaskAssignmentsList/ListStorageTaskAssignmentInstancesReportSummary.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/storageTaskAssignmentsList/ListStorageTaskAssignmentInstancesReportSummary.json // this example is just showing the usage of "StorageTaskAssignmentInstancesReport_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_SubscriptionResourceExtensions.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_SubscriptionResourceExtensions.cs index de2d05ec52e6..88e3828aa0b7 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_SubscriptionResourceExtensions.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_SubscriptionResourceExtensions.cs @@ -21,7 +21,7 @@ public partial class Sample_SubscriptionResourceExtensions [Ignore("Only validating compilation of examples")] public async Task GetSkus_SkuList() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/SKUList.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/SKUList.json // this example is just showing the usage of "Skus_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -48,7 +48,7 @@ public async Task GetSkus_SkuList() [Ignore("Only validating compilation of examples")] public async Task CheckStorageAccountNameAvailability_StorageAccountCheckNameAvailability() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountCheckNameAvailability.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountCheckNameAvailability.json // this example is just showing the usage of "StorageAccounts_CheckNameAvailability" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -73,7 +73,7 @@ public async Task CheckStorageAccountNameAvailability_StorageAccountCheckNameAva [Ignore("Only validating compilation of examples")] public async Task GetStorageAccounts_StorageAccountList() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountList.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountList.json // this example is just showing the usage of "StorageAccounts_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -104,7 +104,7 @@ public async Task GetStorageAccounts_StorageAccountList() [Ignore("Only validating compilation of examples")] public async Task GetDeletedAccounts_DeletedAccountList() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/DeletedAccountList.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/DeletedAccountList.json // this example is just showing the usage of "DeletedAccounts_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -135,7 +135,7 @@ public async Task GetDeletedAccounts_DeletedAccountList() [Ignore("Only validating compilation of examples")] public async Task GetUsagesByLocation_UsageList() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/StorageAccountListLocationUsage.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/StorageAccountListLocationUsage.json // this example is just showing the usage of "Usages_ListByLocation" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_TableCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_TableCollection.cs index c003bbc3e118..82fdfdb8ffb4 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_TableCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_TableCollection.cs @@ -20,7 +20,7 @@ public partial class Sample_TableCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_TableOperationPut() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/TableOperationPut.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/TableOperationPut.json // this example is just showing the usage of "Table_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -56,7 +56,7 @@ public async Task CreateOrUpdate_TableOperationPut() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_TableOperationPutOrPatchAcls() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/TableOperationPutOrPatchAcls.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/TableOperationPutOrPatchAcls.json // this example is just showing the usage of "Table_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -109,7 +109,7 @@ public async Task CreateOrUpdate_TableOperationPutOrPatchAcls() [Ignore("Only validating compilation of examples")] public async Task Get_TableOperationGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/TableOperationGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/TableOperationGet.json // this example is just showing the usage of "Table_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -143,7 +143,7 @@ public async Task Get_TableOperationGet() [Ignore("Only validating compilation of examples")] public async Task GetAll_TableOperationList() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/TableOperationList.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/TableOperationList.json // this example is just showing the usage of "Table_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -179,7 +179,7 @@ public async Task GetAll_TableOperationList() [Ignore("Only validating compilation of examples")] public async Task Exists_TableOperationGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/TableOperationGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/TableOperationGet.json // this example is just showing the usage of "Table_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -209,7 +209,7 @@ public async Task Exists_TableOperationGet() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_TableOperationGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/TableOperationGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/TableOperationGet.json // this example is just showing the usage of "Table_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_TableResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_TableResource.cs index fbf130b01b1d..d24b5ebcf6d9 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_TableResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_TableResource.cs @@ -20,7 +20,7 @@ public partial class Sample_TableResource [Ignore("Only validating compilation of examples")] public async Task Get_TableOperationGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/TableOperationGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/TableOperationGet.json // this example is just showing the usage of "Table_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -51,7 +51,7 @@ public async Task Get_TableOperationGet() [Ignore("Only validating compilation of examples")] public async Task Delete_TableOperationDelete() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/TableOperationDelete.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/TableOperationDelete.json // this example is just showing the usage of "Table_Delete" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -78,7 +78,7 @@ public async Task Delete_TableOperationDelete() [Ignore("Only validating compilation of examples")] public async Task Update_TableOperationPatch() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/TableOperationPatch.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/TableOperationPatch.json // this example is just showing the usage of "Table_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -110,7 +110,7 @@ public async Task Update_TableOperationPatch() [Ignore("Only validating compilation of examples")] public async Task Update_TableOperationPutOrPatchAcls() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/TableOperationPutOrPatchAcls.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/TableOperationPutOrPatchAcls.json // this example is just showing the usage of "Table_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_TableServiceResource.cs b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_TableServiceResource.cs index 8b13fb4fb499..6c68d402f368 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_TableServiceResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/samples/Generated/Samples/Sample_TableServiceResource.cs @@ -20,7 +20,7 @@ public partial class Sample_TableServiceResource [Ignore("Only validating compilation of examples")] public async Task Get_TableServicesGet() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/TableServicesGet.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/TableServicesGet.json // this example is just showing the usage of "TableServices_GetServiceProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -50,7 +50,7 @@ public async Task Get_TableServicesGet() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_TableServicesPut() { - // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2023-05-01/examples/TableServicesPut.json + // Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/TableServicesPut.json // this example is just showing the usage of "TableServices_SetServiceProperties" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Azure.ResourceManager.Storage.csproj b/sdk/storage/Azure.ResourceManager.Storage/src/Azure.ResourceManager.Storage.csproj index 5d6431564248..32a030d225e4 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Azure.ResourceManager.Storage.csproj +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Azure.ResourceManager.Storage.csproj @@ -1,6 +1,6 @@ - 1.4.0-beta.1 + 1.4.0 1.3.0 Azure.ResourceManager.Storage diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ArmStorageModelFactory.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ArmStorageModelFactory.cs index 9ea39c7cb3c8..df655d55ca6f 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ArmStorageModelFactory.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ArmStorageModelFactory.cs @@ -320,6 +320,114 @@ public static FileServiceData FileServiceData(ResourceIdentifier id = null, stri serializedAdditionalRawData: null); } + /// Initializes a new instance of . + /// The id. + /// The name. + /// The resourceType. + /// The systemData. + /// File service usage in storage account including account limits, file share limits and constants used in recommendations and bursting formula. + /// A new instance for mocking. + public static FileServiceUsageData FileServiceUsageData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, FileServiceUsageProperties properties = null) + { + return new FileServiceUsageData( + id, + name, + resourceType, + systemData, + properties, + serializedAdditionalRawData: null); + } + + /// Initializes a new instance of . + /// Maximum provisioned storage, IOPS, bandwidth and number of file shares limits for the storage account. + /// Minimum and maximum provisioned storage, IOPS and bandwidth limits for a file share in the storage account. + /// Constants used for calculating recommended provisioned IOPS and bandwidth for a file share in the storage account. + /// Constants used for calculating included burst IOPS and maximum burst credits for IOPS for a file share in the storage account. + /// Usage of provisioned storage, IOPS, bandwidth and number of file shares across all live shares and soft-deleted shares in the account. + /// A new instance for mocking. + public static FileServiceUsageProperties FileServiceUsageProperties(FileServiceAccountLimits storageAccountLimits = null, FileShareLimits fileShareLimits = null, FileShareRecommendations fileShareRecommendations = null, BurstingConstants burstingConstants = null, FileServiceAccountUsage storageAccountUsage = null) + { + return new FileServiceUsageProperties( + storageAccountLimits, + fileShareLimits, + fileShareRecommendations, + burstingConstants, + storageAccountUsage, + serializedAdditionalRawData: null); + } + + /// Initializes a new instance of . + /// The maximum number of file shares limit for the storage account. + /// The maximum provisioned storage quota limit in gibibytes for the storage account. + /// The maximum provisioned IOPS limit for the storage account. + /// The maximum provisioned bandwidth limit in mebibytes per second for the storage account. + /// A new instance for mocking. + public static FileServiceAccountLimits FileServiceAccountLimits(int? maxFileShares = null, int? maxProvisionedStorageGiB = null, int? maxProvisionedIops = null, int? maxProvisionedBandwidthMiBPerSec = null) + { + return new FileServiceAccountLimits(maxFileShares, maxProvisionedStorageGiB, maxProvisionedIops, maxProvisionedBandwidthMiBPerSec, serializedAdditionalRawData: null); + } + + /// Initializes a new instance of . + /// The minimum provisioned storage quota limit in gibibytes for a file share in the storage account. + /// The maximum provisioned storage quota limit in gibibytes for a file share in the storage account. + /// The minimum provisioned IOPS limit for a file share in the storage account. + /// The maximum provisioned IOPS limit for a file share in the storage account. + /// The minimum provisioned bandwidth limit in mebibytes per second for a file share in the storage account. + /// The maximum provisioned bandwidth limit in mebibytes per second for a file share in the storage account. + /// A new instance for mocking. + public static FileShareLimits FileShareLimits(int? minProvisionedStorageGiB = null, int? maxProvisionedStorageGiB = null, int? minProvisionedIops = null, int? maxProvisionedIops = null, int? minProvisionedBandwidthMiBPerSec = null, int? maxProvisionedBandwidthMiBPerSec = null) + { + return new FileShareLimits( + minProvisionedStorageGiB, + maxProvisionedStorageGiB, + minProvisionedIops, + maxProvisionedIops, + minProvisionedBandwidthMiBPerSec, + maxProvisionedBandwidthMiBPerSec, + serializedAdditionalRawData: null); + } + + /// Initializes a new instance of . + /// The base IOPS in the file share provisioned IOPS recommendation formula. + /// The scalar for IO in the file share provisioned IOPS recommendation formula. + /// The base bandwidth in the file share provisioned bandwidth recommendation formula. + /// The scalar for bandwidth in the file share provisioned bandwidth recommendation formula. + /// A new instance for mocking. + public static FileShareRecommendations FileShareRecommendations(int? baseIops = null, double? ioScalar = null, int? baseBandwidthMiBPerSec = null, double? bandwidthScalar = null) + { + return new FileShareRecommendations(baseIops, ioScalar, baseBandwidthMiBPerSec, bandwidthScalar, serializedAdditionalRawData: null); + } + + /// Initializes a new instance of . + /// The guaranteed floor of burst IOPS for small file shares. + /// The scalar against provisioned IOPS in the file share included burst IOPS formula. + /// The time frame for bursting in seconds in the file share maximum burst credits for IOPS formula. + /// A new instance for mocking. + public static BurstingConstants BurstingConstants(int? burstFloorIops = null, double? burstIOScalar = null, int? burstTimeframeSeconds = null) + { + return new BurstingConstants(burstFloorIops, burstIOScalar, burstTimeframeSeconds, serializedAdditionalRawData: null); + } + + /// Initializes a new instance of . + /// Usage of provisioned storage, IOPS, bandwidth and number of file shares across all live shares or soft-deleted shares in the account. + /// Usage of provisioned storage, IOPS, bandwidth and number of file shares across all live shares or soft-deleted shares in the account. + /// A new instance for mocking. + public static FileServiceAccountUsage FileServiceAccountUsage(FileServiceAccountUsageElements liveShares = null, FileServiceAccountUsageElements softDeletedShares = null) + { + return new FileServiceAccountUsage(liveShares, softDeletedShares, serializedAdditionalRawData: null); + } + + /// Initializes a new instance of . + /// The total number of file shares. + /// The total provisioned storage quota in gibibytes. + /// The total provisioned IOPS. + /// The total provisioned bandwidth in mebibytes per second. + /// A new instance for mocking. + public static FileServiceAccountUsageElements FileServiceAccountUsageElements(int? fileShareCount = null, int? provisionedStorageGiB = null, int? provisionedIops = null, int? provisionedBandwidthMiBPerSec = null) + { + return new FileServiceAccountUsageElements(fileShareCount, provisionedStorageGiB, provisionedIops, provisionedBandwidthMiBPerSec, serializedAdditionalRawData: null); + } + /// Initializes a new instance of . /// The id. /// The name. @@ -327,7 +435,14 @@ public static FileServiceData FileServiceData(ResourceIdentifier id = null, stri /// The systemData. /// Returns the date and time the share was last modified. /// A name-value pair to associate with the share as metadata. - /// The maximum size of the share, in gigabytes. Must be greater than 0, and less than or equal to 5TB (5120). For Large File Shares, the maximum size is 102400. + /// The provisioned size of the share, in gibibytes. Must be greater than 0, and less than or equal to 5TB (5120). For Large File Shares, the maximum size is 102400. For file shares created under Files Provisioned v2 account type, please refer to the GetFileServiceUsage API response for the minimum and maximum allowed provisioned storage size. + /// The provisioned IOPS of the share. This property is only for file shares created under Files Provisioned v2 account type. Please refer to the GetFileServiceUsage API response for the minimum and maximum allowed value for provisioned IOPS. + /// The provisioned bandwidth of the share, in mebibytes per second. This property is only for file shares created under Files Provisioned v2 account type. Please refer to the GetFileServiceUsage API response for the minimum and maximum allowed value for provisioned bandwidth. + /// The calculated burst IOPS of the share. This property is only for file shares created under Files Provisioned v2 account type. + /// The calculated maximum burst credits for the share. This property is only for file shares created under Files Provisioned v2 account type. + /// Returns the next allowed provisioned storage size downgrade time for the share. This property is only for file shares created under Files Provisioned v1 SSD and Files Provisioned v2 account type. + /// Returns the next allowed provisioned IOPS downgrade time for the share. This property is only for file shares created under Files Provisioned v2 account type. + /// Returns the next allowed provisioned bandwidth downgrade time for the share. This property is only for file shares created under Files Provisioned v2 account type. /// The authentication protocol that is used for the file share. Can only be specified when creating a share. /// The property is for NFS share only. The default is NoRootSquash. /// The version of the share. @@ -343,9 +458,10 @@ public static FileServiceData FileServiceData(ResourceIdentifier id = null, stri /// Specifies whether the lease on a share is of infinite or fixed duration, only when the share is leased. /// List of stored access policies specified on the share. /// Creation time of share snapshot returned in the response of list shares with expand param "snapshots". + /// File Share Paid Bursting properties. /// Resource Etag. /// A new instance for mocking. - public static FileShareData FileShareData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, DateTimeOffset? lastModifiedOn = null, IDictionary metadata = null, int? shareQuota = null, FileShareEnabledProtocol? enabledProtocol = null, RootSquashType? rootSquash = null, string version = null, bool? isDeleted = null, DateTimeOffset? deletedOn = null, int? remainingRetentionDays = null, FileShareAccessTier? accessTier = null, DateTimeOffset? accessTierChangeOn = null, string accessTierStatus = null, long? shareUsageBytes = null, StorageLeaseStatus? leaseStatus = null, StorageLeaseState? leaseState = null, StorageLeaseDurationType? leaseDuration = null, IEnumerable signedIdentifiers = null, DateTimeOffset? snapshotOn = null, ETag? etag = null) + public static FileShareData FileShareData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, DateTimeOffset? lastModifiedOn = null, IDictionary metadata = null, int? shareQuota = null, int? provisionedIops = null, int? provisionedBandwidthMibps = null, int? includedBurstIops = null, long? maxBurstCreditsForIops = null, DateTimeOffset? nextAllowedQuotaDowngradeOn = null, DateTimeOffset? nextAllowedProvisionedIopsDowngradeOn = null, DateTimeOffset? nextAllowedProvisionedBandwidthDowngradeOn = null, FileShareEnabledProtocol? enabledProtocol = null, RootSquashType? rootSquash = null, string version = null, bool? isDeleted = null, DateTimeOffset? deletedOn = null, int? remainingRetentionDays = null, FileShareAccessTier? accessTier = null, DateTimeOffset? accessTierChangeOn = null, string accessTierStatus = null, long? shareUsageBytes = null, StorageLeaseStatus? leaseStatus = null, StorageLeaseState? leaseState = null, StorageLeaseDurationType? leaseDuration = null, IEnumerable signedIdentifiers = null, DateTimeOffset? snapshotOn = null, FileSharePropertiesFileSharePaidBursting fileSharePaidBursting = null, ETag? etag = null) { metadata ??= new Dictionary(); signedIdentifiers ??= new List(); @@ -358,6 +474,13 @@ public static FileShareData FileShareData(ResourceIdentifier id = null, string n lastModifiedOn, metadata, shareQuota, + provisionedIops, + provisionedBandwidthMibps, + includedBurstIops, + maxBurstCreditsForIops, + nextAllowedQuotaDowngradeOn, + nextAllowedProvisionedIopsDowngradeOn, + nextAllowedProvisionedBandwidthDowngradeOn, enabledProtocol, rootSquash, version, @@ -373,6 +496,7 @@ public static FileShareData FileShareData(ResourceIdentifier id = null, string n leaseDuration, signedIdentifiers?.ToList(), snapshotOn, + fileSharePaidBursting, etag, serializedAdditionalRawData: null); } @@ -1106,8 +1230,9 @@ public static StoragePrivateLinkResourceData StoragePrivateLinkResourceData(Reso /// Required. Source account name. It should be full resource id if allowCrossTenantReplication set to false. /// Required. Destination account name. It should be full resource id if allowCrossTenantReplication set to false. /// The storage account object replication rules. + /// Optional. The object replication policy metrics feature options. /// A new instance for mocking. - public static ObjectReplicationPolicyData ObjectReplicationPolicyData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, string policyId = null, DateTimeOffset? enabledOn = null, string sourceAccount = null, string destinationAccount = null, IEnumerable rules = null) + public static ObjectReplicationPolicyData ObjectReplicationPolicyData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, string policyId = null, DateTimeOffset? enabledOn = null, string sourceAccount = null, string destinationAccount = null, IEnumerable rules = null, bool? isMetricsEnabled = null) { rules ??= new List(); @@ -1121,6 +1246,7 @@ public static ObjectReplicationPolicyData ObjectReplicationPolicyData(ResourceId sourceAccount, destinationAccount, rules?.ToList(), + isMetricsEnabled != null ? new ObjectReplicationPolicyPropertiesMetrics(isMetricsEnabled, serializedAdditionalRawData: null) : null, serializedAdditionalRawData: null); } @@ -1502,6 +1628,54 @@ public static StorageTaskReportInstance StorageTaskReportInstance(ResourceIdenti serializedAdditionalRawData: null); } + /// Initializes a new instance of . + /// The id. + /// The name. + /// The resourceType. + /// The systemData. + /// Returns the date and time the share was last modified. + /// A name-value pair to associate with the share as metadata. + /// The maximum size of the share, in gigabytes. Must be greater than 0, and less than or equal to 5TB (5120). For Large File Shares, the maximum size is 102400. + /// The authentication protocol that is used for the file share. Can only be specified when creating a share. + /// The property is for NFS share only. The default is NoRootSquash. + /// The version of the share. + /// Indicates whether the share was deleted. + /// The deleted time if the share was deleted. + /// Remaining retention days for share that was soft deleted. + /// Access tier for specific share. GpV2 account can choose between TransactionOptimized (default), Hot, and Cool. FileStorage account can choose Premium. + /// Indicates the last modification time for share access tier. + /// Indicates if there is a pending transition for access tier. + /// The approximate size of the data stored on the share. Note that this value may not include all recently created or recently resized files. + /// The lease status of the share. + /// Lease state of the share. + /// Specifies whether the lease on a share is of infinite or fixed duration, only when the share is leased. + /// List of stored access policies specified on the share. + /// Creation time of share snapshot returned in the response of list shares with expand param "snapshots". + /// Resource Etag. + /// A new instance for mocking. + [EditorBrowsable(EditorBrowsableState.Never)] + public static FileShareData FileShareData(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, DateTimeOffset? lastModifiedOn, IDictionary metadata, int? shareQuota, FileShareEnabledProtocol? enabledProtocol, RootSquashType? rootSquash, string version, bool? isDeleted, DateTimeOffset? deletedOn, int? remainingRetentionDays, FileShareAccessTier? accessTier, DateTimeOffset? accessTierChangeOn, string accessTierStatus, long? shareUsageBytes, StorageLeaseStatus? leaseStatus, StorageLeaseState? leaseState, StorageLeaseDurationType? leaseDuration, IEnumerable signedIdentifiers, DateTimeOffset? snapshotOn, ETag? etag) + { + return FileShareData(id: id, name: name, resourceType: resourceType, systemData: systemData, lastModifiedOn: lastModifiedOn, metadata: metadata, shareQuota: shareQuota, provisionedIops: default, provisionedBandwidthMibps: default, includedBurstIops: default, maxBurstCreditsForIops: default, nextAllowedQuotaDowngradeOn: default, nextAllowedProvisionedIopsDowngradeOn: default, nextAllowedProvisionedBandwidthDowngradeOn: default, enabledProtocol: enabledProtocol, rootSquash: rootSquash, version: version, isDeleted: isDeleted, deletedOn: deletedOn, remainingRetentionDays: remainingRetentionDays, accessTier: accessTier, accessTierChangeOn: accessTierChangeOn, accessTierStatus: accessTierStatus, shareUsageBytes: shareUsageBytes, leaseStatus: leaseStatus, leaseState: leaseState, leaseDuration: leaseDuration, signedIdentifiers: signedIdentifiers, snapshotOn: snapshotOn, fileSharePaidBursting: default, etag: etag); + } + + /// Initializes a new instance of . + /// The id. + /// The name. + /// The resourceType. + /// The systemData. + /// A unique id for object replication policy. + /// Indicates when the policy is enabled on the source account. + /// Required. Source account name. It should be full resource id if allowCrossTenantReplication set to false. + /// Required. Destination account name. It should be full resource id if allowCrossTenantReplication set to false. + /// The storage account object replication rules. + /// A new instance for mocking. + [EditorBrowsable(EditorBrowsableState.Never)] + public static ObjectReplicationPolicyData ObjectReplicationPolicyData(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, string policyId, DateTimeOffset? enabledOn, string sourceAccount, string destinationAccount, IEnumerable rules) + { + return ObjectReplicationPolicyData(id: id, name: name, resourceType: resourceType, systemData: systemData, policyId: policyId, enabledOn: enabledOn, sourceAccount: sourceAccount, destinationAccount: destinationAccount, rules: rules, isMetricsEnabled: default); + } + /// Initializes a new instance of . /// Required. Gets or sets the SKU name. /// Required. Indicates the type of storage account. diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobContainerCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobContainerCollection.cs index d1635f041efb..0daa85d0f55e 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobContainerCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobContainerCollection.cs @@ -65,7 +65,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -116,7 +116,7 @@ public virtual async Task> CreateOrUpdateAsy /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -167,7 +167,7 @@ public virtual ArmOperation CreateOrUpdate(WaitUntil wait /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -212,7 +212,7 @@ public virtual async Task> GetAsync(string conta /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -257,7 +257,7 @@ public virtual Response Get(string containerName, Cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -290,7 +290,7 @@ public virtual AsyncPageable GetAllAsync(int? maxpagesize /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -323,7 +323,7 @@ public virtual Pageable GetAll(int? maxpagesize = null, s /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -366,7 +366,7 @@ public virtual async Task> ExistsAsync(string containerName, Canc /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -409,7 +409,7 @@ public virtual Response Exists(string containerName, CancellationToken can /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -454,7 +454,7 @@ public virtual async Task> GetIfExistsAs /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobContainerResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobContainerResource.cs index 1b2217cbeea5..ed62058a35a5 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobContainerResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobContainerResource.cs @@ -109,7 +109,7 @@ public virtual ImmutabilityPolicyResource GetImmutabilityPolicy() /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -149,7 +149,7 @@ public virtual async Task> GetAsync(Cancellation /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -189,7 +189,7 @@ public virtual Response Get(CancellationToken cancellatio /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -233,7 +233,7 @@ public virtual async Task DeleteAsync(WaitUntil waitUntil, Cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -277,7 +277,7 @@ public virtual ArmOperation Delete(WaitUntil waitUntil, CancellationToken cancel /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -319,7 +319,7 @@ public virtual async Task> UpdateAsync(BlobConta /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -361,7 +361,7 @@ public virtual Response Update(BlobContainerData data, Ca /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -403,7 +403,7 @@ public virtual async Task> SetLegalHoldAsync(LegalHold legal /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -445,7 +445,7 @@ public virtual Response SetLegalHold(LegalHold legalHold, Cancellatio /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -487,7 +487,7 @@ public virtual async Task> ClearLegalHoldAsync(LegalHold leg /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -529,7 +529,7 @@ public virtual Response ClearLegalHold(LegalHold legalHold, Cancellat /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -568,7 +568,7 @@ public virtual async Task> LeaseAsync(LeaseCont /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -607,7 +607,7 @@ public virtual Response Lease(LeaseContainerContent cont /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -649,7 +649,7 @@ public virtual async Task EnableVersionLevelImmutabilityAsync(Wait /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobInventoryPolicyResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobInventoryPolicyResource.cs index ae31dc2b28e9..5aa0773d0ed5 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobInventoryPolicyResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobInventoryPolicyResource.cs @@ -102,7 +102,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -142,7 +142,7 @@ public virtual async Task> GetAsync(Cancel /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -182,7 +182,7 @@ public virtual Response Get(CancellationToken cance /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -226,7 +226,7 @@ public virtual async Task DeleteAsync(WaitUntil waitUntil, Cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -270,7 +270,7 @@ public virtual ArmOperation Delete(WaitUntil waitUntil, CancellationToken cancel /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -318,7 +318,7 @@ public virtual async Task> CreateOrUpd /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobServiceResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobServiceResource.cs index fdc1078dc09a..2706edc9f1a4 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobServiceResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/BlobServiceResource.cs @@ -107,7 +107,7 @@ public virtual BlobContainerCollection GetBlobContainers() /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -138,7 +138,7 @@ public virtual async Task> GetBlobContainerAsync /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -169,7 +169,7 @@ public virtual Response GetBlobContainer(string container /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -209,7 +209,7 @@ public virtual async Task> GetAsync(CancellationTo /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -249,7 +249,7 @@ public virtual Response Get(CancellationToken cancellationT /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -297,7 +297,7 @@ public virtual async Task> CreateOrUpdateAsync /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/DeletedAccountCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/DeletedAccountCollection.cs index 2b4d1593d913..41a085b8a0f9 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/DeletedAccountCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/DeletedAccountCollection.cs @@ -62,7 +62,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -108,7 +108,7 @@ public virtual async Task> GetAsync(AzureLocati /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -154,7 +154,7 @@ public virtual Response Get(AzureLocation location, stri /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -198,7 +198,7 @@ public virtual async Task> ExistsAsync(AzureLocation location, st /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -242,7 +242,7 @@ public virtual Response Exists(AzureLocation location, string deletedAccou /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -288,7 +288,7 @@ public virtual async Task> GetIfExistsA /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/DeletedAccountResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/DeletedAccountResource.cs index 501a22d998f2..58ced42a8b80 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/DeletedAccountResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/DeletedAccountResource.cs @@ -101,7 +101,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -141,7 +141,7 @@ public virtual async Task> GetAsync(Cancellatio /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/EncryptionScopeCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/EncryptionScopeCollection.cs index 2fb470a3e7ba..19a58fc924cc 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/EncryptionScopeCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/EncryptionScopeCollection.cs @@ -65,7 +65,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -116,7 +116,7 @@ public virtual async Task> CreateOrUpdateA /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -167,7 +167,7 @@ public virtual ArmOperation CreateOrUpdate(WaitUntil wa /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -212,7 +212,7 @@ public virtual async Task> GetAsync(string enc /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -257,7 +257,7 @@ public virtual Response Get(string encryptionScopeName, /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -290,7 +290,7 @@ public virtual AsyncPageable GetAllAsync(int? maxpagesi /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -323,7 +323,7 @@ public virtual Pageable GetAll(int? maxpagesize = null, /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -366,7 +366,7 @@ public virtual async Task> ExistsAsync(string encryptionScopeName /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -409,7 +409,7 @@ public virtual Response Exists(string encryptionScopeName, CancellationTok /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -454,7 +454,7 @@ public virtual async Task> GetIfExists /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/EncryptionScopeResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/EncryptionScopeResource.cs index 41a678eda7f6..2b3ddb3eeea2 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/EncryptionScopeResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/EncryptionScopeResource.cs @@ -101,7 +101,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -141,7 +141,7 @@ public virtual async Task> GetAsync(Cancellati /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -181,7 +181,7 @@ public virtual Response Get(CancellationToken cancellat /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -223,7 +223,7 @@ public virtual async Task> UpdateAsync(Encrypt /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/MockableStorageArmClient.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/MockableStorageArmClient.cs index 439f0d117118..f9821e3eba1e 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/MockableStorageArmClient.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/MockableStorageArmClient.cs @@ -82,6 +82,18 @@ public virtual FileServiceResource GetFileServiceResource(ResourceIdentifier id) return new FileServiceResource(Client, id); } + /// + /// Gets an object representing a along with the instance operations that can be performed on it but with no data. + /// You can use to create a from its components. + /// + /// The resource ID of the resource to get. + /// Returns a object. + public virtual FileServiceUsageResource GetFileServiceUsageResource(ResourceIdentifier id) + { + FileServiceUsageResource.ValidateResourceId(id); + return new FileServiceUsageResource(Client, id); + } + /// /// Gets an object representing a along with the instance operations that can be performed on it but with no data. /// You can use to create a from its components. diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/MockableStorageResourceGroupResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/MockableStorageResourceGroupResource.cs index 991f32b18eab..b0602d581914 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/MockableStorageResourceGroupResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/MockableStorageResourceGroupResource.cs @@ -54,7 +54,7 @@ public virtual StorageAccountCollection GetStorageAccounts() /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -86,7 +86,7 @@ public virtual async Task> GetStorageAccountAsy /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/MockableStorageSubscriptionResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/MockableStorageSubscriptionResource.cs index fe0b95cca66e..004c408fb928 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/MockableStorageSubscriptionResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/MockableStorageSubscriptionResource.cs @@ -74,7 +74,7 @@ public virtual DeletedAccountCollection GetDeletedAccounts() /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -106,7 +106,7 @@ public virtual async Task> GetDeletedAccountAsy /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -138,7 +138,7 @@ public virtual Response GetDeletedAccount(AzureLocation /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// @@ -163,7 +163,7 @@ public virtual AsyncPageable GetSkusAsync(CancellationTok /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// @@ -188,7 +188,7 @@ public virtual Pageable GetSkus(CancellationToken cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -230,7 +230,7 @@ public virtual async Task> CheckS /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -272,7 +272,7 @@ public virtual Response CheckStorageAccoun /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -302,7 +302,7 @@ public virtual AsyncPageable GetStorageAccountsAsync(Can /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -332,7 +332,7 @@ public virtual Pageable GetStorageAccounts(CancellationT /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -362,7 +362,7 @@ public virtual AsyncPageable GetDeletedAccountsAsync(Can /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -392,7 +392,7 @@ public virtual Pageable GetDeletedAccounts(CancellationT /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// @@ -418,7 +418,7 @@ public virtual AsyncPageable GetUsagesByLocationAsync(AzureLocatio /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/StorageExtensions.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/StorageExtensions.cs index 4cd5742394ee..727fdd14ef86 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/StorageExtensions.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Extensions/StorageExtensions.cs @@ -109,6 +109,25 @@ public static FileServiceResource GetFileServiceResource(this ArmClient client, return GetMockableStorageArmClient(client).GetFileServiceResource(id); } + /// + /// Gets an object representing a along with the instance operations that can be performed on it but with no data. + /// You can use to create a from its components. + /// + /// Mocking + /// To mock this method, please mock instead. + /// + /// + /// The instance the method will execute against. + /// The resource ID of the resource to get. + /// is null. + /// Returns a object. + public static FileServiceUsageResource GetFileServiceUsageResource(this ArmClient client, ResourceIdentifier id) + { + Argument.AssertNotNull(client, nameof(client)); + + return GetMockableStorageArmClient(client).GetFileServiceUsageResource(id); + } + /// /// Gets an object representing a along with the instance operations that can be performed on it but with no data. /// You can use to create a from its components. @@ -443,7 +462,7 @@ public static StorageAccountCollection GetStorageAccounts(this ResourceGroupReso /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -482,7 +501,7 @@ public static async Task> GetStorageAccountAsyn /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -538,7 +557,7 @@ public static DeletedAccountCollection GetDeletedAccounts(this SubscriptionResou /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -577,7 +596,7 @@ public static async Task> GetDeletedAccountAsyn /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -616,7 +635,7 @@ public static Response GetDeletedAccount(this Subscripti /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// @@ -648,7 +667,7 @@ public static AsyncPageable GetSkusAsync(this Subscriptio /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// @@ -680,7 +699,7 @@ public static Pageable GetSkus(this SubscriptionResource /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -716,7 +735,7 @@ public static async Task> CheckSt /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -752,7 +771,7 @@ public static Response CheckStorageAccount /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -788,7 +807,7 @@ public static AsyncPageable GetStorageAccountsAsync(this /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -824,7 +843,7 @@ public static Pageable GetStorageAccounts(this Subscript /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -860,7 +879,7 @@ public static AsyncPageable GetDeletedAccountsAsync(this /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -896,7 +915,7 @@ public static Pageable GetDeletedAccounts(this Subscript /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// @@ -929,7 +948,7 @@ public static AsyncPageable GetUsagesByLocationAsync(this Subscrip /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceResource.cs index 13534e450324..cea0ab9154dd 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceResource.cs @@ -87,6 +87,13 @@ internal static void ValidateResourceId(ResourceIdentifier id) throw new ArgumentException(string.Format(CultureInfo.CurrentCulture, "Invalid resource type {0} expected {1}", id.ResourceType, ResourceType), nameof(id)); } + /// Gets an object representing a FileServiceUsageResource along with the instance operations that can be performed on it in the FileService. + /// Returns a object. + public virtual FileServiceUsageResource GetFileServiceUsage() + { + return new FileServiceUsageResource(Client, Id.AppendChildResource("usages", "default")); + } + /// Gets a collection of FileShareResources in the FileService. /// An object representing collection of FileShareResources and their operations over a FileShareResource. public virtual FileShareCollection GetFileShares() @@ -107,7 +114,7 @@ public virtual FileShareCollection GetFileShares() /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -140,7 +147,7 @@ public virtual async Task> GetFileShareAsync(string /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -173,7 +180,7 @@ public virtual Response GetFileShare(string shareName, string /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -213,7 +220,7 @@ public virtual async Task> GetAsync(CancellationTo /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -253,7 +260,7 @@ public virtual Response Get(CancellationToken cancellationT /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -301,7 +308,7 @@ public virtual async Task> CreateOrUpdateAsync /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageData.Serialization.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageData.Serialization.cs new file mode 100644 index 000000000000..6115f28b7d70 --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageData.Serialization.cs @@ -0,0 +1,241 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text; +using System.Text.Json; +using Azure.Core; +using Azure.ResourceManager.Models; +using Azure.ResourceManager.Storage.Models; + +namespace Azure.ResourceManager.Storage +{ + public partial class FileServiceUsageData : IUtf8JsonSerializable, IJsonModel + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileServiceUsageData)} does not support writing '{format}' format."); + } + + base.JsonModelWriteCore(writer, options); + if (options.Format != "W" && Optional.IsDefined(Properties)) + { + writer.WritePropertyName("properties"u8); + writer.WriteObjectValue(Properties, options); + } + } + + FileServiceUsageData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileServiceUsageData)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeFileServiceUsageData(document.RootElement, options); + } + + internal static FileServiceUsageData DeserializeFileServiceUsageData(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + FileServiceUsageProperties properties = default; + ResourceIdentifier id = default; + string name = default; + ResourceType type = default; + SystemData systemData = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("properties"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + properties = FileServiceUsageProperties.DeserializeFileServiceUsageProperties(property.Value, options); + continue; + } + if (property.NameEquals("id"u8)) + { + id = new ResourceIdentifier(property.Value.GetString()); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("type"u8)) + { + type = new ResourceType(property.Value.GetString()); + continue; + } + if (property.NameEquals("systemData"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + systemData = JsonSerializer.Deserialize(property.Value.GetRawText()); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new FileServiceUsageData( + id, + name, + type, + systemData, + properties, + serializedAdditionalRawData); + } + + private BinaryData SerializeBicep(ModelReaderWriterOptions options) + { + StringBuilder builder = new StringBuilder(); + BicepModelReaderWriterOptions bicepOptions = options as BicepModelReaderWriterOptions; + IDictionary propertyOverrides = null; + bool hasObjectOverride = bicepOptions != null && bicepOptions.PropertyOverrides.TryGetValue(this, out propertyOverrides); + bool hasPropertyOverride = false; + string propertyOverride = null; + + builder.AppendLine("{"); + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(Name), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" name: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(Name)) + { + builder.Append(" name: "); + if (Name.Contains(Environment.NewLine)) + { + builder.AppendLine("'''"); + builder.AppendLine($"{Name}'''"); + } + else + { + builder.AppendLine($"'{Name}'"); + } + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(Properties), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" properties: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(Properties)) + { + builder.Append(" properties: "); + BicepSerializationHelpers.AppendChildObject(builder, Properties, options, 2, false, " properties: "); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(Id), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" id: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(Id)) + { + builder.Append(" id: "); + builder.AppendLine($"'{Id.ToString()}'"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(SystemData), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" systemData: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(SystemData)) + { + builder.Append(" systemData: "); + builder.AppendLine($"'{SystemData.ToString()}'"); + } + } + + builder.AppendLine("}"); + return BinaryData.FromString(builder.ToString()); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options); + case "bicep": + return SerializeBicep(options); + default: + throw new FormatException($"The model {nameof(FileServiceUsageData)} does not support writing '{options.Format}' format."); + } + } + + FileServiceUsageData IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data); + return DeserializeFileServiceUsageData(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(FileServiceUsageData)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageData.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageData.cs new file mode 100644 index 000000000000..a13f839e2572 --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageData.cs @@ -0,0 +1,76 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; +using Azure.ResourceManager.Models; +using Azure.ResourceManager.Storage.Models; + +namespace Azure.ResourceManager.Storage +{ + /// + /// A class representing the FileServiceUsage data model. + /// The usage of file service in storage account. + /// + public partial class FileServiceUsageData : ResourceData + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + public FileServiceUsageData() + { + } + + /// Initializes a new instance of . + /// The id. + /// The name. + /// The resourceType. + /// The systemData. + /// File service usage in storage account including account limits, file share limits and constants used in recommendations and bursting formula. + /// Keeps track of any properties unknown to the library. + internal FileServiceUsageData(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, FileServiceUsageProperties properties, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData) + { + Properties = properties; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// File service usage in storage account including account limits, file share limits and constants used in recommendations and bursting formula. + [WirePath("properties")] + public FileServiceUsageProperties Properties { get; } + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageResource.Serialization.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageResource.Serialization.cs new file mode 100644 index 000000000000..ef54133854ce --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageResource.Serialization.cs @@ -0,0 +1,26 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Text.Json; + +namespace Azure.ResourceManager.Storage +{ + public partial class FileServiceUsageResource : IJsonModel + { + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) => ((IJsonModel)Data).Write(writer, options); + + FileServiceUsageData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) => ((IJsonModel)Data).Create(ref reader, options); + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) => ModelReaderWriter.Write(Data, options); + + FileServiceUsageData IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) => ModelReaderWriter.Read(data, options); + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => ((IPersistableModel)Data).GetFormatFromOptions(options); + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageResource.cs new file mode 100644 index 000000000000..3165cede6372 --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileServiceUsageResource.cs @@ -0,0 +1,170 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Globalization; +using System.Threading; +using System.Threading.Tasks; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.ResourceManager.Storage +{ + /// + /// A Class representing a FileServiceUsage along with the instance operations that can be performed on it. + /// If you have a you can construct a + /// from an instance of using the GetFileServiceUsageResource method. + /// Otherwise you can get one from its parent resource using the GetFileServiceUsage method. + /// + public partial class FileServiceUsageResource : ArmResource + { + /// Generate the resource identifier of a instance. + /// The subscriptionId. + /// The resourceGroupName. + /// The accountName. + public static ResourceIdentifier CreateResourceIdentifier(string subscriptionId, string resourceGroupName, string accountName) + { + var resourceId = $"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/fileServices/default/usages/default"; + return new ResourceIdentifier(resourceId); + } + + private readonly ClientDiagnostics _fileServiceUsageFileServicesClientDiagnostics; + private readonly FileServicesRestOperations _fileServiceUsageFileServicesRestClient; + private readonly FileServiceUsageData _data; + + /// Gets the resource type for the operations. + public static readonly ResourceType ResourceType = "Microsoft.Storage/storageAccounts/fileServices/usages"; + + /// Initializes a new instance of the class for mocking. + protected FileServiceUsageResource() + { + } + + /// Initializes a new instance of the class. + /// The client parameters to use in these operations. + /// The resource that is the target of operations. + internal FileServiceUsageResource(ArmClient client, FileServiceUsageData data) : this(client, data.Id) + { + HasData = true; + _data = data; + } + + /// Initializes a new instance of the class. + /// The client parameters to use in these operations. + /// The identifier of the resource that is the target of operations. + internal FileServiceUsageResource(ArmClient client, ResourceIdentifier id) : base(client, id) + { + _fileServiceUsageFileServicesClientDiagnostics = new ClientDiagnostics("Azure.ResourceManager.Storage", ResourceType.Namespace, Diagnostics); + TryGetApiVersion(ResourceType, out string fileServiceUsageFileServicesApiVersion); + _fileServiceUsageFileServicesRestClient = new FileServicesRestOperations(Pipeline, Diagnostics.ApplicationId, Endpoint, fileServiceUsageFileServicesApiVersion); +#if DEBUG + ValidateResourceId(Id); +#endif + } + + /// Gets whether or not the current instance has data. + public virtual bool HasData { get; } + + /// Gets the data representing this Feature. + /// Throws if there is no data loaded in the current instance. + public virtual FileServiceUsageData Data + { + get + { + if (!HasData) + throw new InvalidOperationException("The current instance does not have data, you must call Get first."); + return _data; + } + } + + internal static void ValidateResourceId(ResourceIdentifier id) + { + if (id.ResourceType != ResourceType) + throw new ArgumentException(string.Format(CultureInfo.CurrentCulture, "Invalid resource type {0} expected {1}", id.ResourceType, ResourceType), nameof(id)); + } + + /// + /// Gets the usage of file service in storage account including account limits, file share limits and constants used in recommendations and bursting formula. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/fileServices/{FileServicesName}/usages/{fileServiceUsagesName} + /// + /// + /// Operation Id + /// FileServices_GetServiceUsage + /// + /// + /// Default Api Version + /// 2024-01-01 + /// + /// + /// Resource + /// + /// + /// + /// + /// The cancellation token to use. + public virtual async Task> GetAsync(CancellationToken cancellationToken = default) + { + using var scope = _fileServiceUsageFileServicesClientDiagnostics.CreateScope("FileServiceUsageResource.Get"); + scope.Start(); + try + { + var response = await _fileServiceUsageFileServicesRestClient.GetServiceUsageAsync(Id.SubscriptionId, Id.ResourceGroupName, Id.Parent.Parent.Name, cancellationToken).ConfigureAwait(false); + if (response.Value == null) + throw new RequestFailedException(response.GetRawResponse()); + return Response.FromValue(new FileServiceUsageResource(Client, response.Value), response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Gets the usage of file service in storage account including account limits, file share limits and constants used in recommendations and bursting formula. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/fileServices/{FileServicesName}/usages/{fileServiceUsagesName} + /// + /// + /// Operation Id + /// FileServices_GetServiceUsage + /// + /// + /// Default Api Version + /// 2024-01-01 + /// + /// + /// Resource + /// + /// + /// + /// + /// The cancellation token to use. + public virtual Response Get(CancellationToken cancellationToken = default) + { + using var scope = _fileServiceUsageFileServicesClientDiagnostics.CreateScope("FileServiceUsageResource.Get"); + scope.Start(); + try + { + var response = _fileServiceUsageFileServicesRestClient.GetServiceUsage(Id.SubscriptionId, Id.ResourceGroupName, Id.Parent.Parent.Name, cancellationToken); + if (response.Value == null) + throw new RequestFailedException(response.GetRawResponse()); + return Response.FromValue(new FileServiceUsageResource(Client, response.Value), response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareCollection.cs index 2370ae6d36cd..658c83228e7a 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareCollection.cs @@ -64,7 +64,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -116,7 +116,7 @@ public virtual async Task> CreateOrUpdateAsync(W /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -168,7 +168,7 @@ public virtual ArmOperation CreateOrUpdate(WaitUntil waitUnti /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -215,7 +215,7 @@ public virtual async Task> GetAsync(string shareName /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -262,7 +262,7 @@ public virtual Response Get(string shareName, string expand = /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -295,7 +295,7 @@ public virtual AsyncPageable GetAllAsync(int? maxpagesize = n /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -328,7 +328,7 @@ public virtual Pageable GetAll(int? maxpagesize = null, strin /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -373,7 +373,7 @@ public virtual async Task> ExistsAsync(string shareName, string e /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -418,7 +418,7 @@ public virtual Response Exists(string shareName, string expand = null, str /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -465,7 +465,7 @@ public virtual async Task> GetIfExistsAsync( /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareData.Serialization.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareData.Serialization.cs index e29e61a2e7d0..076462754242 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareData.Serialization.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareData.Serialization.cs @@ -67,6 +67,41 @@ protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWri writer.WritePropertyName("shareQuota"u8); writer.WriteNumberValue(ShareQuota.Value); } + if (Optional.IsDefined(ProvisionedIops)) + { + writer.WritePropertyName("provisionedIops"u8); + writer.WriteNumberValue(ProvisionedIops.Value); + } + if (Optional.IsDefined(ProvisionedBandwidthMibps)) + { + writer.WritePropertyName("provisionedBandwidthMibps"u8); + writer.WriteNumberValue(ProvisionedBandwidthMibps.Value); + } + if (options.Format != "W" && Optional.IsDefined(IncludedBurstIops)) + { + writer.WritePropertyName("includedBurstIops"u8); + writer.WriteNumberValue(IncludedBurstIops.Value); + } + if (options.Format != "W" && Optional.IsDefined(MaxBurstCreditsForIops)) + { + writer.WritePropertyName("maxBurstCreditsForIops"u8); + writer.WriteNumberValue(MaxBurstCreditsForIops.Value); + } + if (options.Format != "W" && Optional.IsDefined(NextAllowedQuotaDowngradeOn)) + { + writer.WritePropertyName("nextAllowedQuotaDowngradeTime"u8); + writer.WriteStringValue(NextAllowedQuotaDowngradeOn.Value, "O"); + } + if (options.Format != "W" && Optional.IsDefined(NextAllowedProvisionedIopsDowngradeOn)) + { + writer.WritePropertyName("nextAllowedProvisionedIopsDowngradeTime"u8); + writer.WriteStringValue(NextAllowedProvisionedIopsDowngradeOn.Value, "O"); + } + if (options.Format != "W" && Optional.IsDefined(NextAllowedProvisionedBandwidthDowngradeOn)) + { + writer.WritePropertyName("nextAllowedProvisionedBandwidthDowngradeTime"u8); + writer.WriteStringValue(NextAllowedProvisionedBandwidthDowngradeOn.Value, "O"); + } if (Optional.IsDefined(EnabledProtocol)) { writer.WritePropertyName("enabledProtocols"u8); @@ -147,6 +182,11 @@ protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWri writer.WritePropertyName("snapshotTime"u8); writer.WriteStringValue(SnapshotOn.Value, "O"); } + if (Optional.IsDefined(FileSharePaidBursting)) + { + writer.WritePropertyName("fileSharePaidBursting"u8); + writer.WriteObjectValue(FileSharePaidBursting, options); + } writer.WriteEndObject(); } @@ -178,6 +218,13 @@ internal static FileShareData DeserializeFileShareData(JsonElement element, Mode DateTimeOffset? lastModifiedTime = default; IDictionary metadata = default; int? shareQuota = default; + int? provisionedIops = default; + int? provisionedBandwidthMibps = default; + int? includedBurstIops = default; + long? maxBurstCreditsForIops = default; + DateTimeOffset? nextAllowedQuotaDowngradeTime = default; + DateTimeOffset? nextAllowedProvisionedIopsDowngradeTime = default; + DateTimeOffset? nextAllowedProvisionedBandwidthDowngradeTime = default; FileShareEnabledProtocol? enabledProtocols = default; RootSquashType? rootSquash = default; string version = default; @@ -193,6 +240,7 @@ internal static FileShareData DeserializeFileShareData(JsonElement element, Mode StorageLeaseDurationType? leaseDuration = default; IList signedIdentifiers = default; DateTimeOffset? snapshotTime = default; + FileSharePropertiesFileSharePaidBursting fileSharePaidBursting = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) @@ -271,6 +319,69 @@ internal static FileShareData DeserializeFileShareData(JsonElement element, Mode shareQuota = property0.Value.GetInt32(); continue; } + if (property0.NameEquals("provisionedIops"u8)) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + provisionedIops = property0.Value.GetInt32(); + continue; + } + if (property0.NameEquals("provisionedBandwidthMibps"u8)) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + provisionedBandwidthMibps = property0.Value.GetInt32(); + continue; + } + if (property0.NameEquals("includedBurstIops"u8)) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + includedBurstIops = property0.Value.GetInt32(); + continue; + } + if (property0.NameEquals("maxBurstCreditsForIops"u8)) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + maxBurstCreditsForIops = property0.Value.GetInt64(); + continue; + } + if (property0.NameEquals("nextAllowedQuotaDowngradeTime"u8)) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + nextAllowedQuotaDowngradeTime = property0.Value.GetDateTimeOffset("O"); + continue; + } + if (property0.NameEquals("nextAllowedProvisionedIopsDowngradeTime"u8)) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + nextAllowedProvisionedIopsDowngradeTime = property0.Value.GetDateTimeOffset("O"); + continue; + } + if (property0.NameEquals("nextAllowedProvisionedBandwidthDowngradeTime"u8)) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + nextAllowedProvisionedBandwidthDowngradeTime = property0.Value.GetDateTimeOffset("O"); + continue; + } if (property0.NameEquals("enabledProtocols"u8)) { if (property0.Value.ValueKind == JsonValueKind.Null) @@ -403,6 +514,15 @@ internal static FileShareData DeserializeFileShareData(JsonElement element, Mode snapshotTime = property0.Value.GetDateTimeOffset("O"); continue; } + if (property0.NameEquals("fileSharePaidBursting"u8)) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + fileSharePaidBursting = FileSharePropertiesFileSharePaidBursting.DeserializeFileSharePropertiesFileSharePaidBursting(property0.Value, options); + continue; + } } continue; } @@ -420,6 +540,13 @@ internal static FileShareData DeserializeFileShareData(JsonElement element, Mode lastModifiedTime, metadata ?? new ChangeTrackingDictionary(), shareQuota, + provisionedIops, + provisionedBandwidthMibps, + includedBurstIops, + maxBurstCreditsForIops, + nextAllowedQuotaDowngradeTime, + nextAllowedProvisionedIopsDowngradeTime, + nextAllowedProvisionedBandwidthDowngradeTime, enabledProtocols, rootSquash, version, @@ -435,6 +562,7 @@ internal static FileShareData DeserializeFileShareData(JsonElement element, Mode leaseDuration, signedIdentifiers ?? new ChangeTrackingList(), snapshotTime, + fileSharePaidBursting, etag, serializedAdditionalRawData); } @@ -588,6 +716,114 @@ private BinaryData SerializeBicep(ModelReaderWriterOptions options) } } + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(ProvisionedIops), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" provisionedIops: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(ProvisionedIops)) + { + builder.Append(" provisionedIops: "); + builder.AppendLine($"{ProvisionedIops.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(ProvisionedBandwidthMibps), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" provisionedBandwidthMibps: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(ProvisionedBandwidthMibps)) + { + builder.Append(" provisionedBandwidthMibps: "); + builder.AppendLine($"{ProvisionedBandwidthMibps.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(IncludedBurstIops), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" includedBurstIops: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(IncludedBurstIops)) + { + builder.Append(" includedBurstIops: "); + builder.AppendLine($"{IncludedBurstIops.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(MaxBurstCreditsForIops), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" maxBurstCreditsForIops: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(MaxBurstCreditsForIops)) + { + builder.Append(" maxBurstCreditsForIops: "); + builder.AppendLine($"'{MaxBurstCreditsForIops.Value.ToString()}'"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(NextAllowedQuotaDowngradeOn), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" nextAllowedQuotaDowngradeTime: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(NextAllowedQuotaDowngradeOn)) + { + builder.Append(" nextAllowedQuotaDowngradeTime: "); + var formattedDateTimeString = TypeFormatters.ToString(NextAllowedQuotaDowngradeOn.Value, "o"); + builder.AppendLine($"'{formattedDateTimeString}'"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(NextAllowedProvisionedIopsDowngradeOn), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" nextAllowedProvisionedIopsDowngradeTime: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(NextAllowedProvisionedIopsDowngradeOn)) + { + builder.Append(" nextAllowedProvisionedIopsDowngradeTime: "); + var formattedDateTimeString = TypeFormatters.ToString(NextAllowedProvisionedIopsDowngradeOn.Value, "o"); + builder.AppendLine($"'{formattedDateTimeString}'"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(NextAllowedProvisionedBandwidthDowngradeOn), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" nextAllowedProvisionedBandwidthDowngradeTime: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(NextAllowedProvisionedBandwidthDowngradeOn)) + { + builder.Append(" nextAllowedProvisionedBandwidthDowngradeTime: "); + var formattedDateTimeString = TypeFormatters.ToString(NextAllowedProvisionedBandwidthDowngradeOn.Value, "o"); + builder.AppendLine($"'{formattedDateTimeString}'"); + } + } + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(EnabledProtocol), out propertyOverride); if (hasPropertyOverride) { @@ -841,6 +1077,21 @@ private BinaryData SerializeBicep(ModelReaderWriterOptions options) } } + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(FileSharePaidBursting), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" fileSharePaidBursting: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(FileSharePaidBursting)) + { + builder.Append(" fileSharePaidBursting: "); + BicepSerializationHelpers.AppendChildObject(builder, FileSharePaidBursting, options, 4, false, " fileSharePaidBursting: "); + } + } + builder.AppendLine(" }"); builder.AppendLine("}"); return BinaryData.FromString(builder.ToString()); diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareData.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareData.cs index 4d991075b9ae..a3499e7c57f7 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareData.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareData.cs @@ -65,7 +65,14 @@ public FileShareData() /// The systemData. /// Returns the date and time the share was last modified. /// A name-value pair to associate with the share as metadata. - /// The maximum size of the share, in gigabytes. Must be greater than 0, and less than or equal to 5TB (5120). For Large File Shares, the maximum size is 102400. + /// The provisioned size of the share, in gibibytes. Must be greater than 0, and less than or equal to 5TB (5120). For Large File Shares, the maximum size is 102400. For file shares created under Files Provisioned v2 account type, please refer to the GetFileServiceUsage API response for the minimum and maximum allowed provisioned storage size. + /// The provisioned IOPS of the share. This property is only for file shares created under Files Provisioned v2 account type. Please refer to the GetFileServiceUsage API response for the minimum and maximum allowed value for provisioned IOPS. + /// The provisioned bandwidth of the share, in mebibytes per second. This property is only for file shares created under Files Provisioned v2 account type. Please refer to the GetFileServiceUsage API response for the minimum and maximum allowed value for provisioned bandwidth. + /// The calculated burst IOPS of the share. This property is only for file shares created under Files Provisioned v2 account type. + /// The calculated maximum burst credits for the share. This property is only for file shares created under Files Provisioned v2 account type. + /// Returns the next allowed provisioned storage size downgrade time for the share. This property is only for file shares created under Files Provisioned v1 SSD and Files Provisioned v2 account type. + /// Returns the next allowed provisioned IOPS downgrade time for the share. This property is only for file shares created under Files Provisioned v2 account type. + /// Returns the next allowed provisioned bandwidth downgrade time for the share. This property is only for file shares created under Files Provisioned v2 account type. /// The authentication protocol that is used for the file share. Can only be specified when creating a share. /// The property is for NFS share only. The default is NoRootSquash. /// The version of the share. @@ -81,13 +88,21 @@ public FileShareData() /// Specifies whether the lease on a share is of infinite or fixed duration, only when the share is leased. /// List of stored access policies specified on the share. /// Creation time of share snapshot returned in the response of list shares with expand param "snapshots". + /// File Share Paid Bursting properties. /// Resource Etag. /// Keeps track of any properties unknown to the library. - internal FileShareData(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, DateTimeOffset? lastModifiedOn, IDictionary metadata, int? shareQuota, FileShareEnabledProtocol? enabledProtocol, RootSquashType? rootSquash, string version, bool? isDeleted, DateTimeOffset? deletedOn, int? remainingRetentionDays, FileShareAccessTier? accessTier, DateTimeOffset? accessTierChangeOn, string accessTierStatus, long? shareUsageBytes, StorageLeaseStatus? leaseStatus, StorageLeaseState? leaseState, StorageLeaseDurationType? leaseDuration, IList signedIdentifiers, DateTimeOffset? snapshotOn, ETag? etag, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData) + internal FileShareData(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, DateTimeOffset? lastModifiedOn, IDictionary metadata, int? shareQuota, int? provisionedIops, int? provisionedBandwidthMibps, int? includedBurstIops, long? maxBurstCreditsForIops, DateTimeOffset? nextAllowedQuotaDowngradeOn, DateTimeOffset? nextAllowedProvisionedIopsDowngradeOn, DateTimeOffset? nextAllowedProvisionedBandwidthDowngradeOn, FileShareEnabledProtocol? enabledProtocol, RootSquashType? rootSquash, string version, bool? isDeleted, DateTimeOffset? deletedOn, int? remainingRetentionDays, FileShareAccessTier? accessTier, DateTimeOffset? accessTierChangeOn, string accessTierStatus, long? shareUsageBytes, StorageLeaseStatus? leaseStatus, StorageLeaseState? leaseState, StorageLeaseDurationType? leaseDuration, IList signedIdentifiers, DateTimeOffset? snapshotOn, FileSharePropertiesFileSharePaidBursting fileSharePaidBursting, ETag? etag, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData) { LastModifiedOn = lastModifiedOn; Metadata = metadata; ShareQuota = shareQuota; + ProvisionedIops = provisionedIops; + ProvisionedBandwidthMibps = provisionedBandwidthMibps; + IncludedBurstIops = includedBurstIops; + MaxBurstCreditsForIops = maxBurstCreditsForIops; + NextAllowedQuotaDowngradeOn = nextAllowedQuotaDowngradeOn; + NextAllowedProvisionedIopsDowngradeOn = nextAllowedProvisionedIopsDowngradeOn; + NextAllowedProvisionedBandwidthDowngradeOn = nextAllowedProvisionedBandwidthDowngradeOn; EnabledProtocol = enabledProtocol; RootSquash = rootSquash; Version = version; @@ -103,6 +118,7 @@ internal FileShareData(ResourceIdentifier id, string name, ResourceType resource LeaseDuration = leaseDuration; SignedIdentifiers = signedIdentifiers; SnapshotOn = snapshotOn; + FileSharePaidBursting = fileSharePaidBursting; ETag = etag; _serializedAdditionalRawData = serializedAdditionalRawData; } @@ -113,9 +129,30 @@ internal FileShareData(ResourceIdentifier id, string name, ResourceType resource /// A name-value pair to associate with the share as metadata. [WirePath("properties.metadata")] public IDictionary Metadata { get; } - /// The maximum size of the share, in gigabytes. Must be greater than 0, and less than or equal to 5TB (5120). For Large File Shares, the maximum size is 102400. + /// The provisioned size of the share, in gibibytes. Must be greater than 0, and less than or equal to 5TB (5120). For Large File Shares, the maximum size is 102400. For file shares created under Files Provisioned v2 account type, please refer to the GetFileServiceUsage API response for the minimum and maximum allowed provisioned storage size. [WirePath("properties.shareQuota")] public int? ShareQuota { get; set; } + /// The provisioned IOPS of the share. This property is only for file shares created under Files Provisioned v2 account type. Please refer to the GetFileServiceUsage API response for the minimum and maximum allowed value for provisioned IOPS. + [WirePath("properties.provisionedIops")] + public int? ProvisionedIops { get; set; } + /// The provisioned bandwidth of the share, in mebibytes per second. This property is only for file shares created under Files Provisioned v2 account type. Please refer to the GetFileServiceUsage API response for the minimum and maximum allowed value for provisioned bandwidth. + [WirePath("properties.provisionedBandwidthMibps")] + public int? ProvisionedBandwidthMibps { get; set; } + /// The calculated burst IOPS of the share. This property is only for file shares created under Files Provisioned v2 account type. + [WirePath("properties.includedBurstIops")] + public int? IncludedBurstIops { get; } + /// The calculated maximum burst credits for the share. This property is only for file shares created under Files Provisioned v2 account type. + [WirePath("properties.maxBurstCreditsForIops")] + public long? MaxBurstCreditsForIops { get; } + /// Returns the next allowed provisioned storage size downgrade time for the share. This property is only for file shares created under Files Provisioned v1 SSD and Files Provisioned v2 account type. + [WirePath("properties.nextAllowedQuotaDowngradeTime")] + public DateTimeOffset? NextAllowedQuotaDowngradeOn { get; } + /// Returns the next allowed provisioned IOPS downgrade time for the share. This property is only for file shares created under Files Provisioned v2 account type. + [WirePath("properties.nextAllowedProvisionedIopsDowngradeTime")] + public DateTimeOffset? NextAllowedProvisionedIopsDowngradeOn { get; } + /// Returns the next allowed provisioned bandwidth downgrade time for the share. This property is only for file shares created under Files Provisioned v2 account type. + [WirePath("properties.nextAllowedProvisionedBandwidthDowngradeTime")] + public DateTimeOffset? NextAllowedProvisionedBandwidthDowngradeOn { get; } /// The authentication protocol that is used for the file share. Can only be specified when creating a share. [WirePath("properties.enabledProtocols")] public FileShareEnabledProtocol? EnabledProtocol { get; set; } @@ -161,6 +198,9 @@ internal FileShareData(ResourceIdentifier id, string name, ResourceType resource /// Creation time of share snapshot returned in the response of list shares with expand param "snapshots". [WirePath("properties.snapshotTime")] public DateTimeOffset? SnapshotOn { get; } + /// File Share Paid Bursting properties. + [WirePath("properties.fileSharePaidBursting")] + public FileSharePropertiesFileSharePaidBursting FileSharePaidBursting { get; set; } /// Resource Etag. [WirePath("etag")] public ETag? ETag { get; } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareResource.cs index 1ad3a8b04629..3eaf12462702 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/FileShareResource.cs @@ -102,7 +102,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -144,7 +144,7 @@ public virtual async Task> GetAsync(string expand = /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -186,7 +186,7 @@ public virtual Response Get(string expand = null, string xMsS /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -232,7 +232,7 @@ public virtual async Task DeleteAsync(WaitUntil waitUntil, string /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -278,7 +278,7 @@ public virtual ArmOperation Delete(WaitUntil waitUntil, string xMsSnapshot = nul /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -320,7 +320,7 @@ public virtual async Task> UpdateAsync(FileShareData /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -362,7 +362,7 @@ public virtual Response Update(FileShareData data, Cancellati /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -404,7 +404,7 @@ public virtual async Task RestoreAsync(DeletedShare deletedShare, Canc /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -446,7 +446,7 @@ public virtual Response Restore(DeletedShare deletedShare, CancellationToken can /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -486,7 +486,7 @@ public virtual async Task> LeaseAsync(LeaseShareCon /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ImmutabilityPolicyResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ImmutabilityPolicyResource.cs index acf1f62a2300..94f3060e29e0 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ImmutabilityPolicyResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ImmutabilityPolicyResource.cs @@ -101,7 +101,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -109,7 +109,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. public virtual async Task> GetAsync(ETag? ifMatch = null, CancellationToken cancellationToken = default) { @@ -142,7 +142,7 @@ public virtual async Task> GetAsync(ETag? i /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -150,7 +150,7 @@ public virtual async Task> GetAsync(ETag? i /// /// /// - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. public virtual Response Get(ETag? ifMatch = null, CancellationToken cancellationToken = default) { @@ -183,7 +183,7 @@ public virtual Response Get(ETag? ifMatch = null, Ca /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -192,7 +192,7 @@ public virtual Response Get(ETag? ifMatch = null, Ca /// /// /// if the method should wait to return until the long-running operation has completed on the service; if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples. - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. public virtual async Task> DeleteAsync(WaitUntil waitUntil, ETag ifMatch, CancellationToken cancellationToken = default) { @@ -228,7 +228,7 @@ public virtual async Task> DeleteAsync( /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -237,7 +237,7 @@ public virtual async Task> DeleteAsync( /// /// /// if the method should wait to return until the long-running operation has completed on the service; if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples. - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. public virtual ArmOperation Delete(WaitUntil waitUntil, ETag ifMatch, CancellationToken cancellationToken = default) { @@ -273,7 +273,7 @@ public virtual ArmOperation Delete(WaitUntil waitUnt /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -283,7 +283,7 @@ public virtual ArmOperation Delete(WaitUntil waitUnt /// /// if the method should wait to return until the long-running operation has completed on the service; if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples. /// The ImmutabilityPolicy Properties that will be created or updated to a blob container. - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. /// is null. public virtual async Task> CreateOrUpdateAsync(WaitUntil waitUntil, ImmutabilityPolicyData data, ETag? ifMatch = null, CancellationToken cancellationToken = default) @@ -322,7 +322,7 @@ public virtual async Task> CreateOrUpda /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -332,7 +332,7 @@ public virtual async Task> CreateOrUpda /// /// if the method should wait to return until the long-running operation has completed on the service; if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples. /// The ImmutabilityPolicy Properties that will be created or updated to a blob container. - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. /// is null. public virtual ArmOperation CreateOrUpdate(WaitUntil waitUntil, ImmutabilityPolicyData data, ETag? ifMatch = null, CancellationToken cancellationToken = default) @@ -371,7 +371,7 @@ public virtual ArmOperation CreateOrUpdate(WaitUntil /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -379,7 +379,7 @@ public virtual ArmOperation CreateOrUpdate(WaitUntil /// /// /// - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. public virtual async Task> LockImmutabilityPolicyAsync(ETag ifMatch, CancellationToken cancellationToken = default) { @@ -410,7 +410,7 @@ public virtual async Task> LockImmutability /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -418,7 +418,7 @@ public virtual async Task> LockImmutability /// /// /// - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. public virtual Response LockImmutabilityPolicy(ETag ifMatch, CancellationToken cancellationToken = default) { @@ -449,7 +449,7 @@ public virtual Response LockImmutabilityPolicy(ETag /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -457,7 +457,7 @@ public virtual Response LockImmutabilityPolicy(ETag /// /// /// - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The ImmutabilityPolicy Properties that will be extended for a blob container. /// The cancellation token to use. public virtual async Task> ExtendImmutabilityPolicyAsync(ETag ifMatch, ImmutabilityPolicyData data = null, CancellationToken cancellationToken = default) @@ -489,7 +489,7 @@ public virtual async Task> ExtendImmutabili /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -497,7 +497,7 @@ public virtual async Task> ExtendImmutabili /// /// /// - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The ImmutabilityPolicy Properties that will be extended for a blob container. /// The cancellation token to use. public virtual Response ExtendImmutabilityPolicy(ETag ifMatch, ImmutabilityPolicyData data = null, CancellationToken cancellationToken = default) diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/BurstingConstants.Serialization.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/BurstingConstants.Serialization.cs new file mode 100644 index 000000000000..3672d3dc2151 --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/BurstingConstants.Serialization.cs @@ -0,0 +1,226 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Storage.Models +{ + public partial class BurstingConstants : IUtf8JsonSerializable, IJsonModel + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(BurstingConstants)} does not support writing '{format}' format."); + } + + if (options.Format != "W" && Optional.IsDefined(BurstFloorIops)) + { + writer.WritePropertyName("burstFloorIOPS"u8); + writer.WriteNumberValue(BurstFloorIops.Value); + } + if (options.Format != "W" && Optional.IsDefined(BurstIOScalar)) + { + writer.WritePropertyName("burstIOScalar"u8); + writer.WriteNumberValue(BurstIOScalar.Value); + } + if (options.Format != "W" && Optional.IsDefined(BurstTimeframeSeconds)) + { + writer.WritePropertyName("burstTimeframeSeconds"u8); + writer.WriteNumberValue(BurstTimeframeSeconds.Value); + } + if (options.Format != "W" && _serializedAdditionalRawData != null) + { + foreach (var item in _serializedAdditionalRawData) + { + writer.WritePropertyName(item.Key); +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + BurstingConstants IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(BurstingConstants)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeBurstingConstants(document.RootElement, options); + } + + internal static BurstingConstants DeserializeBurstingConstants(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + int? burstFloorIOPS = default; + double? burstIOScalar = default; + int? burstTimeframeSeconds = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("burstFloorIOPS"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + burstFloorIOPS = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("burstIOScalar"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + burstIOScalar = property.Value.GetDouble(); + continue; + } + if (property.NameEquals("burstTimeframeSeconds"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + burstTimeframeSeconds = property.Value.GetInt32(); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new BurstingConstants(burstFloorIOPS, burstIOScalar, burstTimeframeSeconds, serializedAdditionalRawData); + } + + private BinaryData SerializeBicep(ModelReaderWriterOptions options) + { + StringBuilder builder = new StringBuilder(); + BicepModelReaderWriterOptions bicepOptions = options as BicepModelReaderWriterOptions; + IDictionary propertyOverrides = null; + bool hasObjectOverride = bicepOptions != null && bicepOptions.PropertyOverrides.TryGetValue(this, out propertyOverrides); + bool hasPropertyOverride = false; + string propertyOverride = null; + + builder.AppendLine("{"); + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(BurstFloorIops), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" burstFloorIOPS: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(BurstFloorIops)) + { + builder.Append(" burstFloorIOPS: "); + builder.AppendLine($"{BurstFloorIops.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(BurstIOScalar), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" burstIOScalar: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(BurstIOScalar)) + { + builder.Append(" burstIOScalar: "); + builder.AppendLine($"'{BurstIOScalar.Value.ToString()}'"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(BurstTimeframeSeconds), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" burstTimeframeSeconds: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(BurstTimeframeSeconds)) + { + builder.Append(" burstTimeframeSeconds: "); + builder.AppendLine($"{BurstTimeframeSeconds.Value}"); + } + } + + builder.AppendLine("}"); + return BinaryData.FromString(builder.ToString()); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options); + case "bicep": + return SerializeBicep(options); + default: + throw new FormatException($"The model {nameof(BurstingConstants)} does not support writing '{options.Format}' format."); + } + } + + BurstingConstants IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data); + return DeserializeBurstingConstants(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(BurstingConstants)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/BurstingConstants.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/BurstingConstants.cs new file mode 100644 index 000000000000..411d74bd9fac --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/BurstingConstants.cs @@ -0,0 +1,76 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Storage.Models +{ + /// Constants used for calculating included burst IOPS and maximum burst credits for IOPS for a file share in the storage account. + public partial class BurstingConstants + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + internal BurstingConstants() + { + } + + /// Initializes a new instance of . + /// The guaranteed floor of burst IOPS for small file shares. + /// The scalar against provisioned IOPS in the file share included burst IOPS formula. + /// The time frame for bursting in seconds in the file share maximum burst credits for IOPS formula. + /// Keeps track of any properties unknown to the library. + internal BurstingConstants(int? burstFloorIops, double? burstIOScalar, int? burstTimeframeSeconds, IDictionary serializedAdditionalRawData) + { + BurstFloorIops = burstFloorIops; + BurstIOScalar = burstIOScalar; + BurstTimeframeSeconds = burstTimeframeSeconds; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// The guaranteed floor of burst IOPS for small file shares. + [WirePath("burstFloorIOPS")] + public int? BurstFloorIops { get; } + /// The scalar against provisioned IOPS in the file share included burst IOPS formula. + [WirePath("burstIOScalar")] + public double? BurstIOScalar { get; } + /// The time frame for bursting in seconds in the file share maximum burst credits for IOPS formula. + [WirePath("burstTimeframeSeconds")] + public int? BurstTimeframeSeconds { get; } + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountLimits.Serialization.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountLimits.Serialization.cs new file mode 100644 index 000000000000..c6a3d683cafc --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountLimits.Serialization.cs @@ -0,0 +1,256 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Storage.Models +{ + public partial class FileServiceAccountLimits : IUtf8JsonSerializable, IJsonModel + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileServiceAccountLimits)} does not support writing '{format}' format."); + } + + if (options.Format != "W" && Optional.IsDefined(MaxFileShares)) + { + writer.WritePropertyName("maxFileShares"u8); + writer.WriteNumberValue(MaxFileShares.Value); + } + if (options.Format != "W" && Optional.IsDefined(MaxProvisionedStorageGiB)) + { + writer.WritePropertyName("maxProvisionedStorageGiB"u8); + writer.WriteNumberValue(MaxProvisionedStorageGiB.Value); + } + if (options.Format != "W" && Optional.IsDefined(MaxProvisionedIops)) + { + writer.WritePropertyName("maxProvisionedIOPS"u8); + writer.WriteNumberValue(MaxProvisionedIops.Value); + } + if (options.Format != "W" && Optional.IsDefined(MaxProvisionedBandwidthMiBPerSec)) + { + writer.WritePropertyName("maxProvisionedBandwidthMiBPerSec"u8); + writer.WriteNumberValue(MaxProvisionedBandwidthMiBPerSec.Value); + } + if (options.Format != "W" && _serializedAdditionalRawData != null) + { + foreach (var item in _serializedAdditionalRawData) + { + writer.WritePropertyName(item.Key); +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + FileServiceAccountLimits IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileServiceAccountLimits)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeFileServiceAccountLimits(document.RootElement, options); + } + + internal static FileServiceAccountLimits DeserializeFileServiceAccountLimits(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + int? maxFileShares = default; + int? maxProvisionedStorageGiB = default; + int? maxProvisionedIOPS = default; + int? maxProvisionedBandwidthMiBPerSec = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("maxFileShares"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + maxFileShares = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("maxProvisionedStorageGiB"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + maxProvisionedStorageGiB = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("maxProvisionedIOPS"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + maxProvisionedIOPS = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("maxProvisionedBandwidthMiBPerSec"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + maxProvisionedBandwidthMiBPerSec = property.Value.GetInt32(); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new FileServiceAccountLimits(maxFileShares, maxProvisionedStorageGiB, maxProvisionedIOPS, maxProvisionedBandwidthMiBPerSec, serializedAdditionalRawData); + } + + private BinaryData SerializeBicep(ModelReaderWriterOptions options) + { + StringBuilder builder = new StringBuilder(); + BicepModelReaderWriterOptions bicepOptions = options as BicepModelReaderWriterOptions; + IDictionary propertyOverrides = null; + bool hasObjectOverride = bicepOptions != null && bicepOptions.PropertyOverrides.TryGetValue(this, out propertyOverrides); + bool hasPropertyOverride = false; + string propertyOverride = null; + + builder.AppendLine("{"); + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(MaxFileShares), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" maxFileShares: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(MaxFileShares)) + { + builder.Append(" maxFileShares: "); + builder.AppendLine($"{MaxFileShares.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(MaxProvisionedStorageGiB), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" maxProvisionedStorageGiB: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(MaxProvisionedStorageGiB)) + { + builder.Append(" maxProvisionedStorageGiB: "); + builder.AppendLine($"{MaxProvisionedStorageGiB.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(MaxProvisionedIops), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" maxProvisionedIOPS: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(MaxProvisionedIops)) + { + builder.Append(" maxProvisionedIOPS: "); + builder.AppendLine($"{MaxProvisionedIops.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(MaxProvisionedBandwidthMiBPerSec), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" maxProvisionedBandwidthMiBPerSec: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(MaxProvisionedBandwidthMiBPerSec)) + { + builder.Append(" maxProvisionedBandwidthMiBPerSec: "); + builder.AppendLine($"{MaxProvisionedBandwidthMiBPerSec.Value}"); + } + } + + builder.AppendLine("}"); + return BinaryData.FromString(builder.ToString()); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options); + case "bicep": + return SerializeBicep(options); + default: + throw new FormatException($"The model {nameof(FileServiceAccountLimits)} does not support writing '{options.Format}' format."); + } + } + + FileServiceAccountLimits IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data); + return DeserializeFileServiceAccountLimits(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(FileServiceAccountLimits)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountLimits.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountLimits.cs new file mode 100644 index 000000000000..9b96e1ff90ed --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountLimits.cs @@ -0,0 +1,81 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Storage.Models +{ + /// Maximum provisioned storage, IOPS, bandwidth and number of file shares limits for the storage account. + public partial class FileServiceAccountLimits + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + internal FileServiceAccountLimits() + { + } + + /// Initializes a new instance of . + /// The maximum number of file shares limit for the storage account. + /// The maximum provisioned storage quota limit in gibibytes for the storage account. + /// The maximum provisioned IOPS limit for the storage account. + /// The maximum provisioned bandwidth limit in mebibytes per second for the storage account. + /// Keeps track of any properties unknown to the library. + internal FileServiceAccountLimits(int? maxFileShares, int? maxProvisionedStorageGiB, int? maxProvisionedIops, int? maxProvisionedBandwidthMiBPerSec, IDictionary serializedAdditionalRawData) + { + MaxFileShares = maxFileShares; + MaxProvisionedStorageGiB = maxProvisionedStorageGiB; + MaxProvisionedIops = maxProvisionedIops; + MaxProvisionedBandwidthMiBPerSec = maxProvisionedBandwidthMiBPerSec; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// The maximum number of file shares limit for the storage account. + [WirePath("maxFileShares")] + public int? MaxFileShares { get; } + /// The maximum provisioned storage quota limit in gibibytes for the storage account. + [WirePath("maxProvisionedStorageGiB")] + public int? MaxProvisionedStorageGiB { get; } + /// The maximum provisioned IOPS limit for the storage account. + [WirePath("maxProvisionedIOPS")] + public int? MaxProvisionedIops { get; } + /// The maximum provisioned bandwidth limit in mebibytes per second for the storage account. + [WirePath("maxProvisionedBandwidthMiBPerSec")] + public int? MaxProvisionedBandwidthMiBPerSec { get; } + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsage.Serialization.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsage.Serialization.cs new file mode 100644 index 000000000000..c4ee86be3b52 --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsage.Serialization.cs @@ -0,0 +1,196 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Storage.Models +{ + public partial class FileServiceAccountUsage : IUtf8JsonSerializable, IJsonModel + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileServiceAccountUsage)} does not support writing '{format}' format."); + } + + if (options.Format != "W" && Optional.IsDefined(LiveShares)) + { + writer.WritePropertyName("liveShares"u8); + writer.WriteObjectValue(LiveShares, options); + } + if (options.Format != "W" && Optional.IsDefined(SoftDeletedShares)) + { + writer.WritePropertyName("softDeletedShares"u8); + writer.WriteObjectValue(SoftDeletedShares, options); + } + if (options.Format != "W" && _serializedAdditionalRawData != null) + { + foreach (var item in _serializedAdditionalRawData) + { + writer.WritePropertyName(item.Key); +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + FileServiceAccountUsage IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileServiceAccountUsage)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeFileServiceAccountUsage(document.RootElement, options); + } + + internal static FileServiceAccountUsage DeserializeFileServiceAccountUsage(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + FileServiceAccountUsageElements liveShares = default; + FileServiceAccountUsageElements softDeletedShares = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("liveShares"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + liveShares = FileServiceAccountUsageElements.DeserializeFileServiceAccountUsageElements(property.Value, options); + continue; + } + if (property.NameEquals("softDeletedShares"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + softDeletedShares = FileServiceAccountUsageElements.DeserializeFileServiceAccountUsageElements(property.Value, options); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new FileServiceAccountUsage(liveShares, softDeletedShares, serializedAdditionalRawData); + } + + private BinaryData SerializeBicep(ModelReaderWriterOptions options) + { + StringBuilder builder = new StringBuilder(); + BicepModelReaderWriterOptions bicepOptions = options as BicepModelReaderWriterOptions; + IDictionary propertyOverrides = null; + bool hasObjectOverride = bicepOptions != null && bicepOptions.PropertyOverrides.TryGetValue(this, out propertyOverrides); + bool hasPropertyOverride = false; + string propertyOverride = null; + + builder.AppendLine("{"); + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(LiveShares), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" liveShares: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(LiveShares)) + { + builder.Append(" liveShares: "); + BicepSerializationHelpers.AppendChildObject(builder, LiveShares, options, 2, false, " liveShares: "); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(SoftDeletedShares), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" softDeletedShares: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(SoftDeletedShares)) + { + builder.Append(" softDeletedShares: "); + BicepSerializationHelpers.AppendChildObject(builder, SoftDeletedShares, options, 2, false, " softDeletedShares: "); + } + } + + builder.AppendLine("}"); + return BinaryData.FromString(builder.ToString()); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options); + case "bicep": + return SerializeBicep(options); + default: + throw new FormatException($"The model {nameof(FileServiceAccountUsage)} does not support writing '{options.Format}' format."); + } + } + + FileServiceAccountUsage IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data); + return DeserializeFileServiceAccountUsage(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(FileServiceAccountUsage)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsage.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsage.cs new file mode 100644 index 000000000000..adbacb68fcdd --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsage.cs @@ -0,0 +1,71 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Storage.Models +{ + /// Usage of provisioned storage, IOPS, bandwidth and number of file shares across all live shares and soft-deleted shares in the account. + public partial class FileServiceAccountUsage + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + internal FileServiceAccountUsage() + { + } + + /// Initializes a new instance of . + /// Usage of provisioned storage, IOPS, bandwidth and number of file shares across all live shares or soft-deleted shares in the account. + /// Usage of provisioned storage, IOPS, bandwidth and number of file shares across all live shares or soft-deleted shares in the account. + /// Keeps track of any properties unknown to the library. + internal FileServiceAccountUsage(FileServiceAccountUsageElements liveShares, FileServiceAccountUsageElements softDeletedShares, IDictionary serializedAdditionalRawData) + { + LiveShares = liveShares; + SoftDeletedShares = softDeletedShares; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// Usage of provisioned storage, IOPS, bandwidth and number of file shares across all live shares or soft-deleted shares in the account. + [WirePath("liveShares")] + public FileServiceAccountUsageElements LiveShares { get; } + /// Usage of provisioned storage, IOPS, bandwidth and number of file shares across all live shares or soft-deleted shares in the account. + [WirePath("softDeletedShares")] + public FileServiceAccountUsageElements SoftDeletedShares { get; } + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsageElements.Serialization.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsageElements.Serialization.cs new file mode 100644 index 000000000000..6c38ccf8bd9c --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsageElements.Serialization.cs @@ -0,0 +1,256 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Storage.Models +{ + public partial class FileServiceAccountUsageElements : IUtf8JsonSerializable, IJsonModel + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileServiceAccountUsageElements)} does not support writing '{format}' format."); + } + + if (options.Format != "W" && Optional.IsDefined(FileShareCount)) + { + writer.WritePropertyName("fileShareCount"u8); + writer.WriteNumberValue(FileShareCount.Value); + } + if (options.Format != "W" && Optional.IsDefined(ProvisionedStorageGiB)) + { + writer.WritePropertyName("provisionedStorageGiB"u8); + writer.WriteNumberValue(ProvisionedStorageGiB.Value); + } + if (options.Format != "W" && Optional.IsDefined(ProvisionedIops)) + { + writer.WritePropertyName("provisionedIOPS"u8); + writer.WriteNumberValue(ProvisionedIops.Value); + } + if (options.Format != "W" && Optional.IsDefined(ProvisionedBandwidthMiBPerSec)) + { + writer.WritePropertyName("provisionedBandwidthMiBPerSec"u8); + writer.WriteNumberValue(ProvisionedBandwidthMiBPerSec.Value); + } + if (options.Format != "W" && _serializedAdditionalRawData != null) + { + foreach (var item in _serializedAdditionalRawData) + { + writer.WritePropertyName(item.Key); +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + FileServiceAccountUsageElements IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileServiceAccountUsageElements)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeFileServiceAccountUsageElements(document.RootElement, options); + } + + internal static FileServiceAccountUsageElements DeserializeFileServiceAccountUsageElements(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + int? fileShareCount = default; + int? provisionedStorageGiB = default; + int? provisionedIOPS = default; + int? provisionedBandwidthMiBPerSec = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("fileShareCount"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + fileShareCount = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("provisionedStorageGiB"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + provisionedStorageGiB = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("provisionedIOPS"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + provisionedIOPS = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("provisionedBandwidthMiBPerSec"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + provisionedBandwidthMiBPerSec = property.Value.GetInt32(); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new FileServiceAccountUsageElements(fileShareCount, provisionedStorageGiB, provisionedIOPS, provisionedBandwidthMiBPerSec, serializedAdditionalRawData); + } + + private BinaryData SerializeBicep(ModelReaderWriterOptions options) + { + StringBuilder builder = new StringBuilder(); + BicepModelReaderWriterOptions bicepOptions = options as BicepModelReaderWriterOptions; + IDictionary propertyOverrides = null; + bool hasObjectOverride = bicepOptions != null && bicepOptions.PropertyOverrides.TryGetValue(this, out propertyOverrides); + bool hasPropertyOverride = false; + string propertyOverride = null; + + builder.AppendLine("{"); + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(FileShareCount), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" fileShareCount: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(FileShareCount)) + { + builder.Append(" fileShareCount: "); + builder.AppendLine($"{FileShareCount.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(ProvisionedStorageGiB), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" provisionedStorageGiB: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(ProvisionedStorageGiB)) + { + builder.Append(" provisionedStorageGiB: "); + builder.AppendLine($"{ProvisionedStorageGiB.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(ProvisionedIops), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" provisionedIOPS: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(ProvisionedIops)) + { + builder.Append(" provisionedIOPS: "); + builder.AppendLine($"{ProvisionedIops.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(ProvisionedBandwidthMiBPerSec), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" provisionedBandwidthMiBPerSec: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(ProvisionedBandwidthMiBPerSec)) + { + builder.Append(" provisionedBandwidthMiBPerSec: "); + builder.AppendLine($"{ProvisionedBandwidthMiBPerSec.Value}"); + } + } + + builder.AppendLine("}"); + return BinaryData.FromString(builder.ToString()); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options); + case "bicep": + return SerializeBicep(options); + default: + throw new FormatException($"The model {nameof(FileServiceAccountUsageElements)} does not support writing '{options.Format}' format."); + } + } + + FileServiceAccountUsageElements IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data); + return DeserializeFileServiceAccountUsageElements(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(FileServiceAccountUsageElements)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsageElements.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsageElements.cs new file mode 100644 index 000000000000..be59be1b9349 --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceAccountUsageElements.cs @@ -0,0 +1,81 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Storage.Models +{ + /// Usage of provisioned storage, IOPS, bandwidth and number of file shares across all live shares or soft-deleted shares in the account. + public partial class FileServiceAccountUsageElements + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + internal FileServiceAccountUsageElements() + { + } + + /// Initializes a new instance of . + /// The total number of file shares. + /// The total provisioned storage quota in gibibytes. + /// The total provisioned IOPS. + /// The total provisioned bandwidth in mebibytes per second. + /// Keeps track of any properties unknown to the library. + internal FileServiceAccountUsageElements(int? fileShareCount, int? provisionedStorageGiB, int? provisionedIops, int? provisionedBandwidthMiBPerSec, IDictionary serializedAdditionalRawData) + { + FileShareCount = fileShareCount; + ProvisionedStorageGiB = provisionedStorageGiB; + ProvisionedIops = provisionedIops; + ProvisionedBandwidthMiBPerSec = provisionedBandwidthMiBPerSec; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// The total number of file shares. + [WirePath("fileShareCount")] + public int? FileShareCount { get; } + /// The total provisioned storage quota in gibibytes. + [WirePath("provisionedStorageGiB")] + public int? ProvisionedStorageGiB { get; } + /// The total provisioned IOPS. + [WirePath("provisionedIOPS")] + public int? ProvisionedIops { get; } + /// The total provisioned bandwidth in mebibytes per second. + [WirePath("provisionedBandwidthMiBPerSec")] + public int? ProvisionedBandwidthMiBPerSec { get; } + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsageProperties.Serialization.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsageProperties.Serialization.cs new file mode 100644 index 000000000000..3000b455a0e1 --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsageProperties.Serialization.cs @@ -0,0 +1,292 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Storage.Models +{ + public partial class FileServiceUsageProperties : IUtf8JsonSerializable, IJsonModel + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileServiceUsageProperties)} does not support writing '{format}' format."); + } + + if (options.Format != "W" && Optional.IsDefined(StorageAccountLimits)) + { + writer.WritePropertyName("storageAccountLimits"u8); + writer.WriteObjectValue(StorageAccountLimits, options); + } + if (options.Format != "W" && Optional.IsDefined(FileShareLimits)) + { + writer.WritePropertyName("fileShareLimits"u8); + writer.WriteObjectValue(FileShareLimits, options); + } + if (options.Format != "W" && Optional.IsDefined(FileShareRecommendations)) + { + writer.WritePropertyName("fileShareRecommendations"u8); + writer.WriteObjectValue(FileShareRecommendations, options); + } + if (options.Format != "W" && Optional.IsDefined(BurstingConstants)) + { + writer.WritePropertyName("burstingConstants"u8); + writer.WriteObjectValue(BurstingConstants, options); + } + if (options.Format != "W" && Optional.IsDefined(StorageAccountUsage)) + { + writer.WritePropertyName("storageAccountUsage"u8); + writer.WriteObjectValue(StorageAccountUsage, options); + } + if (options.Format != "W" && _serializedAdditionalRawData != null) + { + foreach (var item in _serializedAdditionalRawData) + { + writer.WritePropertyName(item.Key); +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + FileServiceUsageProperties IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileServiceUsageProperties)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeFileServiceUsageProperties(document.RootElement, options); + } + + internal static FileServiceUsageProperties DeserializeFileServiceUsageProperties(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + FileServiceAccountLimits storageAccountLimits = default; + FileShareLimits fileShareLimits = default; + FileShareRecommendations fileShareRecommendations = default; + BurstingConstants burstingConstants = default; + FileServiceAccountUsage storageAccountUsage = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("storageAccountLimits"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + storageAccountLimits = FileServiceAccountLimits.DeserializeFileServiceAccountLimits(property.Value, options); + continue; + } + if (property.NameEquals("fileShareLimits"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + fileShareLimits = FileShareLimits.DeserializeFileShareLimits(property.Value, options); + continue; + } + if (property.NameEquals("fileShareRecommendations"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + fileShareRecommendations = FileShareRecommendations.DeserializeFileShareRecommendations(property.Value, options); + continue; + } + if (property.NameEquals("burstingConstants"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + burstingConstants = BurstingConstants.DeserializeBurstingConstants(property.Value, options); + continue; + } + if (property.NameEquals("storageAccountUsage"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + storageAccountUsage = FileServiceAccountUsage.DeserializeFileServiceAccountUsage(property.Value, options); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new FileServiceUsageProperties( + storageAccountLimits, + fileShareLimits, + fileShareRecommendations, + burstingConstants, + storageAccountUsage, + serializedAdditionalRawData); + } + + private BinaryData SerializeBicep(ModelReaderWriterOptions options) + { + StringBuilder builder = new StringBuilder(); + BicepModelReaderWriterOptions bicepOptions = options as BicepModelReaderWriterOptions; + IDictionary propertyOverrides = null; + bool hasObjectOverride = bicepOptions != null && bicepOptions.PropertyOverrides.TryGetValue(this, out propertyOverrides); + bool hasPropertyOverride = false; + string propertyOverride = null; + + builder.AppendLine("{"); + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(StorageAccountLimits), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" storageAccountLimits: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(StorageAccountLimits)) + { + builder.Append(" storageAccountLimits: "); + BicepSerializationHelpers.AppendChildObject(builder, StorageAccountLimits, options, 2, false, " storageAccountLimits: "); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(FileShareLimits), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" fileShareLimits: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(FileShareLimits)) + { + builder.Append(" fileShareLimits: "); + BicepSerializationHelpers.AppendChildObject(builder, FileShareLimits, options, 2, false, " fileShareLimits: "); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(FileShareRecommendations), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" fileShareRecommendations: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(FileShareRecommendations)) + { + builder.Append(" fileShareRecommendations: "); + BicepSerializationHelpers.AppendChildObject(builder, FileShareRecommendations, options, 2, false, " fileShareRecommendations: "); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(BurstingConstants), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" burstingConstants: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(BurstingConstants)) + { + builder.Append(" burstingConstants: "); + BicepSerializationHelpers.AppendChildObject(builder, BurstingConstants, options, 2, false, " burstingConstants: "); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(StorageAccountUsage), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" storageAccountUsage: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(StorageAccountUsage)) + { + builder.Append(" storageAccountUsage: "); + BicepSerializationHelpers.AppendChildObject(builder, StorageAccountUsage, options, 2, false, " storageAccountUsage: "); + } + } + + builder.AppendLine("}"); + return BinaryData.FromString(builder.ToString()); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options); + case "bicep": + return SerializeBicep(options); + default: + throw new FormatException($"The model {nameof(FileServiceUsageProperties)} does not support writing '{options.Format}' format."); + } + } + + FileServiceUsageProperties IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data); + return DeserializeFileServiceUsageProperties(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(FileServiceUsageProperties)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsageProperties.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsageProperties.cs new file mode 100644 index 000000000000..5e193fc8c89e --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsageProperties.cs @@ -0,0 +1,86 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Storage.Models +{ + /// File service usage in storage account including account limits, file share limits and constants used in recommendations and bursting formula. + public partial class FileServiceUsageProperties + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + internal FileServiceUsageProperties() + { + } + + /// Initializes a new instance of . + /// Maximum provisioned storage, IOPS, bandwidth and number of file shares limits for the storage account. + /// Minimum and maximum provisioned storage, IOPS and bandwidth limits for a file share in the storage account. + /// Constants used for calculating recommended provisioned IOPS and bandwidth for a file share in the storage account. + /// Constants used for calculating included burst IOPS and maximum burst credits for IOPS for a file share in the storage account. + /// Usage of provisioned storage, IOPS, bandwidth and number of file shares across all live shares and soft-deleted shares in the account. + /// Keeps track of any properties unknown to the library. + internal FileServiceUsageProperties(FileServiceAccountLimits storageAccountLimits, FileShareLimits fileShareLimits, FileShareRecommendations fileShareRecommendations, BurstingConstants burstingConstants, FileServiceAccountUsage storageAccountUsage, IDictionary serializedAdditionalRawData) + { + StorageAccountLimits = storageAccountLimits; + FileShareLimits = fileShareLimits; + FileShareRecommendations = fileShareRecommendations; + BurstingConstants = burstingConstants; + StorageAccountUsage = storageAccountUsage; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// Maximum provisioned storage, IOPS, bandwidth and number of file shares limits for the storage account. + [WirePath("storageAccountLimits")] + public FileServiceAccountLimits StorageAccountLimits { get; } + /// Minimum and maximum provisioned storage, IOPS and bandwidth limits for a file share in the storage account. + [WirePath("fileShareLimits")] + public FileShareLimits FileShareLimits { get; } + /// Constants used for calculating recommended provisioned IOPS and bandwidth for a file share in the storage account. + [WirePath("fileShareRecommendations")] + public FileShareRecommendations FileShareRecommendations { get; } + /// Constants used for calculating included burst IOPS and maximum burst credits for IOPS for a file share in the storage account. + [WirePath("burstingConstants")] + public BurstingConstants BurstingConstants { get; } + /// Usage of provisioned storage, IOPS, bandwidth and number of file shares across all live shares and soft-deleted shares in the account. + [WirePath("storageAccountUsage")] + public FileServiceAccountUsage StorageAccountUsage { get; } + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsages.Serialization.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsages.Serialization.cs new file mode 100644 index 000000000000..4a72858ce254 --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsages.Serialization.cs @@ -0,0 +1,219 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Storage.Models +{ + internal partial class FileServiceUsages : IUtf8JsonSerializable, IJsonModel + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileServiceUsages)} does not support writing '{format}' format."); + } + + if (options.Format != "W" && Optional.IsCollectionDefined(Value)) + { + writer.WritePropertyName("value"u8); + writer.WriteStartArray(); + foreach (var item in Value) + { + writer.WriteObjectValue(item, options); + } + writer.WriteEndArray(); + } + if (options.Format != "W" && Optional.IsDefined(NextLink)) + { + writer.WritePropertyName("nextLink"u8); + writer.WriteStringValue(NextLink); + } + if (options.Format != "W" && _serializedAdditionalRawData != null) + { + foreach (var item in _serializedAdditionalRawData) + { + writer.WritePropertyName(item.Key); +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + FileServiceUsages IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileServiceUsages)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeFileServiceUsages(document.RootElement, options); + } + + internal static FileServiceUsages DeserializeFileServiceUsages(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + IReadOnlyList value = default; + string nextLink = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("value"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(FileServiceUsageData.DeserializeFileServiceUsageData(item, options)); + } + value = array; + continue; + } + if (property.NameEquals("nextLink"u8)) + { + nextLink = property.Value.GetString(); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new FileServiceUsages(value ?? new ChangeTrackingList(), nextLink, serializedAdditionalRawData); + } + + private BinaryData SerializeBicep(ModelReaderWriterOptions options) + { + StringBuilder builder = new StringBuilder(); + BicepModelReaderWriterOptions bicepOptions = options as BicepModelReaderWriterOptions; + IDictionary propertyOverrides = null; + bool hasObjectOverride = bicepOptions != null && bicepOptions.PropertyOverrides.TryGetValue(this, out propertyOverrides); + bool hasPropertyOverride = false; + string propertyOverride = null; + + builder.AppendLine("{"); + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(Value), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" value: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsCollectionDefined(Value)) + { + if (Value.Any()) + { + builder.Append(" value: "); + builder.AppendLine("["); + foreach (var item in Value) + { + BicepSerializationHelpers.AppendChildObject(builder, item, options, 4, true, " value: "); + } + builder.AppendLine(" ]"); + } + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(NextLink), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" nextLink: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(NextLink)) + { + builder.Append(" nextLink: "); + if (NextLink.Contains(Environment.NewLine)) + { + builder.AppendLine("'''"); + builder.AppendLine($"{NextLink}'''"); + } + else + { + builder.AppendLine($"'{NextLink}'"); + } + } + } + + builder.AppendLine("}"); + return BinaryData.FromString(builder.ToString()); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options); + case "bicep": + return SerializeBicep(options); + default: + throw new FormatException($"The model {nameof(FileServiceUsages)} does not support writing '{options.Format}' format."); + } + } + + FileServiceUsages IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data); + return DeserializeFileServiceUsages(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(FileServiceUsages)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsages.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsages.cs new file mode 100644 index 000000000000..c4b1a0755cdc --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileServiceUsages.cs @@ -0,0 +1,70 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Storage.Models +{ + /// List file service usages schema. + internal partial class FileServiceUsages + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + internal FileServiceUsages() + { + Value = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// List of file service usages returned. + /// Request URL that can be used to query next page of file service usages. Returned when total number of requested file service usages exceed maximum page size. + /// Keeps track of any properties unknown to the library. + internal FileServiceUsages(IReadOnlyList value, string nextLink, IDictionary serializedAdditionalRawData) + { + Value = value; + NextLink = nextLink; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// List of file service usages returned. + public IReadOnlyList Value { get; } + /// Request URL that can be used to query next page of file service usages. Returned when total number of requested file service usages exceed maximum page size. + public string NextLink { get; } + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareLimits.Serialization.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareLimits.Serialization.cs new file mode 100644 index 000000000000..695acfbaabd1 --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareLimits.Serialization.cs @@ -0,0 +1,323 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Storage.Models +{ + public partial class FileShareLimits : IUtf8JsonSerializable, IJsonModel + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileShareLimits)} does not support writing '{format}' format."); + } + + if (options.Format != "W" && Optional.IsDefined(MinProvisionedStorageGiB)) + { + writer.WritePropertyName("minProvisionedStorageGiB"u8); + writer.WriteNumberValue(MinProvisionedStorageGiB.Value); + } + if (options.Format != "W" && Optional.IsDefined(MaxProvisionedStorageGiB)) + { + writer.WritePropertyName("maxProvisionedStorageGiB"u8); + writer.WriteNumberValue(MaxProvisionedStorageGiB.Value); + } + if (options.Format != "W" && Optional.IsDefined(MinProvisionedIops)) + { + writer.WritePropertyName("minProvisionedIOPS"u8); + writer.WriteNumberValue(MinProvisionedIops.Value); + } + if (options.Format != "W" && Optional.IsDefined(MaxProvisionedIops)) + { + writer.WritePropertyName("maxProvisionedIOPS"u8); + writer.WriteNumberValue(MaxProvisionedIops.Value); + } + if (options.Format != "W" && Optional.IsDefined(MinProvisionedBandwidthMiBPerSec)) + { + writer.WritePropertyName("minProvisionedBandwidthMiBPerSec"u8); + writer.WriteNumberValue(MinProvisionedBandwidthMiBPerSec.Value); + } + if (options.Format != "W" && Optional.IsDefined(MaxProvisionedBandwidthMiBPerSec)) + { + writer.WritePropertyName("maxProvisionedBandwidthMiBPerSec"u8); + writer.WriteNumberValue(MaxProvisionedBandwidthMiBPerSec.Value); + } + if (options.Format != "W" && _serializedAdditionalRawData != null) + { + foreach (var item in _serializedAdditionalRawData) + { + writer.WritePropertyName(item.Key); +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + FileShareLimits IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileShareLimits)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeFileShareLimits(document.RootElement, options); + } + + internal static FileShareLimits DeserializeFileShareLimits(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + int? minProvisionedStorageGiB = default; + int? maxProvisionedStorageGiB = default; + int? minProvisionedIOPS = default; + int? maxProvisionedIOPS = default; + int? minProvisionedBandwidthMiBPerSec = default; + int? maxProvisionedBandwidthMiBPerSec = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("minProvisionedStorageGiB"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + minProvisionedStorageGiB = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("maxProvisionedStorageGiB"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + maxProvisionedStorageGiB = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("minProvisionedIOPS"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + minProvisionedIOPS = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("maxProvisionedIOPS"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + maxProvisionedIOPS = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("minProvisionedBandwidthMiBPerSec"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + minProvisionedBandwidthMiBPerSec = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("maxProvisionedBandwidthMiBPerSec"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + maxProvisionedBandwidthMiBPerSec = property.Value.GetInt32(); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new FileShareLimits( + minProvisionedStorageGiB, + maxProvisionedStorageGiB, + minProvisionedIOPS, + maxProvisionedIOPS, + minProvisionedBandwidthMiBPerSec, + maxProvisionedBandwidthMiBPerSec, + serializedAdditionalRawData); + } + + private BinaryData SerializeBicep(ModelReaderWriterOptions options) + { + StringBuilder builder = new StringBuilder(); + BicepModelReaderWriterOptions bicepOptions = options as BicepModelReaderWriterOptions; + IDictionary propertyOverrides = null; + bool hasObjectOverride = bicepOptions != null && bicepOptions.PropertyOverrides.TryGetValue(this, out propertyOverrides); + bool hasPropertyOverride = false; + string propertyOverride = null; + + builder.AppendLine("{"); + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(MinProvisionedStorageGiB), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" minProvisionedStorageGiB: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(MinProvisionedStorageGiB)) + { + builder.Append(" minProvisionedStorageGiB: "); + builder.AppendLine($"{MinProvisionedStorageGiB.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(MaxProvisionedStorageGiB), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" maxProvisionedStorageGiB: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(MaxProvisionedStorageGiB)) + { + builder.Append(" maxProvisionedStorageGiB: "); + builder.AppendLine($"{MaxProvisionedStorageGiB.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(MinProvisionedIops), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" minProvisionedIOPS: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(MinProvisionedIops)) + { + builder.Append(" minProvisionedIOPS: "); + builder.AppendLine($"{MinProvisionedIops.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(MaxProvisionedIops), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" maxProvisionedIOPS: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(MaxProvisionedIops)) + { + builder.Append(" maxProvisionedIOPS: "); + builder.AppendLine($"{MaxProvisionedIops.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(MinProvisionedBandwidthMiBPerSec), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" minProvisionedBandwidthMiBPerSec: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(MinProvisionedBandwidthMiBPerSec)) + { + builder.Append(" minProvisionedBandwidthMiBPerSec: "); + builder.AppendLine($"{MinProvisionedBandwidthMiBPerSec.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(MaxProvisionedBandwidthMiBPerSec), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" maxProvisionedBandwidthMiBPerSec: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(MaxProvisionedBandwidthMiBPerSec)) + { + builder.Append(" maxProvisionedBandwidthMiBPerSec: "); + builder.AppendLine($"{MaxProvisionedBandwidthMiBPerSec.Value}"); + } + } + + builder.AppendLine("}"); + return BinaryData.FromString(builder.ToString()); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options); + case "bicep": + return SerializeBicep(options); + default: + throw new FormatException($"The model {nameof(FileShareLimits)} does not support writing '{options.Format}' format."); + } + } + + FileShareLimits IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data); + return DeserializeFileShareLimits(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(FileShareLimits)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareLimits.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareLimits.cs new file mode 100644 index 000000000000..ce4ae41102ea --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareLimits.cs @@ -0,0 +1,91 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Storage.Models +{ + /// Minimum and maximum provisioned storage, IOPS and bandwidth limits for a file share in the storage account. + public partial class FileShareLimits + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + internal FileShareLimits() + { + } + + /// Initializes a new instance of . + /// The minimum provisioned storage quota limit in gibibytes for a file share in the storage account. + /// The maximum provisioned storage quota limit in gibibytes for a file share in the storage account. + /// The minimum provisioned IOPS limit for a file share in the storage account. + /// The maximum provisioned IOPS limit for a file share in the storage account. + /// The minimum provisioned bandwidth limit in mebibytes per second for a file share in the storage account. + /// The maximum provisioned bandwidth limit in mebibytes per second for a file share in the storage account. + /// Keeps track of any properties unknown to the library. + internal FileShareLimits(int? minProvisionedStorageGiB, int? maxProvisionedStorageGiB, int? minProvisionedIops, int? maxProvisionedIops, int? minProvisionedBandwidthMiBPerSec, int? maxProvisionedBandwidthMiBPerSec, IDictionary serializedAdditionalRawData) + { + MinProvisionedStorageGiB = minProvisionedStorageGiB; + MaxProvisionedStorageGiB = maxProvisionedStorageGiB; + MinProvisionedIops = minProvisionedIops; + MaxProvisionedIops = maxProvisionedIops; + MinProvisionedBandwidthMiBPerSec = minProvisionedBandwidthMiBPerSec; + MaxProvisionedBandwidthMiBPerSec = maxProvisionedBandwidthMiBPerSec; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// The minimum provisioned storage quota limit in gibibytes for a file share in the storage account. + [WirePath("minProvisionedStorageGiB")] + public int? MinProvisionedStorageGiB { get; } + /// The maximum provisioned storage quota limit in gibibytes for a file share in the storage account. + [WirePath("maxProvisionedStorageGiB")] + public int? MaxProvisionedStorageGiB { get; } + /// The minimum provisioned IOPS limit for a file share in the storage account. + [WirePath("minProvisionedIOPS")] + public int? MinProvisionedIops { get; } + /// The maximum provisioned IOPS limit for a file share in the storage account. + [WirePath("maxProvisionedIOPS")] + public int? MaxProvisionedIops { get; } + /// The minimum provisioned bandwidth limit in mebibytes per second for a file share in the storage account. + [WirePath("minProvisionedBandwidthMiBPerSec")] + public int? MinProvisionedBandwidthMiBPerSec { get; } + /// The maximum provisioned bandwidth limit in mebibytes per second for a file share in the storage account. + [WirePath("maxProvisionedBandwidthMiBPerSec")] + public int? MaxProvisionedBandwidthMiBPerSec { get; } + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileSharePropertiesFileSharePaidBursting.Serialization.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileSharePropertiesFileSharePaidBursting.Serialization.cs new file mode 100644 index 000000000000..d0d43a1c24ae --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileSharePropertiesFileSharePaidBursting.Serialization.cs @@ -0,0 +1,227 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Storage.Models +{ + public partial class FileSharePropertiesFileSharePaidBursting : IUtf8JsonSerializable, IJsonModel + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileSharePropertiesFileSharePaidBursting)} does not support writing '{format}' format."); + } + + if (Optional.IsDefined(PaidBurstingEnabled)) + { + writer.WritePropertyName("paidBurstingEnabled"u8); + writer.WriteBooleanValue(PaidBurstingEnabled.Value); + } + if (Optional.IsDefined(PaidBurstingMaxIops)) + { + writer.WritePropertyName("paidBurstingMaxIops"u8); + writer.WriteNumberValue(PaidBurstingMaxIops.Value); + } + if (Optional.IsDefined(PaidBurstingMaxBandwidthMibps)) + { + writer.WritePropertyName("paidBurstingMaxBandwidthMibps"u8); + writer.WriteNumberValue(PaidBurstingMaxBandwidthMibps.Value); + } + if (options.Format != "W" && _serializedAdditionalRawData != null) + { + foreach (var item in _serializedAdditionalRawData) + { + writer.WritePropertyName(item.Key); +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + FileSharePropertiesFileSharePaidBursting IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileSharePropertiesFileSharePaidBursting)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeFileSharePropertiesFileSharePaidBursting(document.RootElement, options); + } + + internal static FileSharePropertiesFileSharePaidBursting DeserializeFileSharePropertiesFileSharePaidBursting(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + bool? paidBurstingEnabled = default; + int? paidBurstingMaxIops = default; + int? paidBurstingMaxBandwidthMibps = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("paidBurstingEnabled"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + paidBurstingEnabled = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("paidBurstingMaxIops"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + paidBurstingMaxIops = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("paidBurstingMaxBandwidthMibps"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + paidBurstingMaxBandwidthMibps = property.Value.GetInt32(); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new FileSharePropertiesFileSharePaidBursting(paidBurstingEnabled, paidBurstingMaxIops, paidBurstingMaxBandwidthMibps, serializedAdditionalRawData); + } + + private BinaryData SerializeBicep(ModelReaderWriterOptions options) + { + StringBuilder builder = new StringBuilder(); + BicepModelReaderWriterOptions bicepOptions = options as BicepModelReaderWriterOptions; + IDictionary propertyOverrides = null; + bool hasObjectOverride = bicepOptions != null && bicepOptions.PropertyOverrides.TryGetValue(this, out propertyOverrides); + bool hasPropertyOverride = false; + string propertyOverride = null; + + builder.AppendLine("{"); + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(PaidBurstingEnabled), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" paidBurstingEnabled: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(PaidBurstingEnabled)) + { + builder.Append(" paidBurstingEnabled: "); + var boolValue = PaidBurstingEnabled.Value == true ? "true" : "false"; + builder.AppendLine($"{boolValue}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(PaidBurstingMaxIops), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" paidBurstingMaxIops: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(PaidBurstingMaxIops)) + { + builder.Append(" paidBurstingMaxIops: "); + builder.AppendLine($"{PaidBurstingMaxIops.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(PaidBurstingMaxBandwidthMibps), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" paidBurstingMaxBandwidthMibps: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(PaidBurstingMaxBandwidthMibps)) + { + builder.Append(" paidBurstingMaxBandwidthMibps: "); + builder.AppendLine($"{PaidBurstingMaxBandwidthMibps.Value}"); + } + } + + builder.AppendLine("}"); + return BinaryData.FromString(builder.ToString()); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options); + case "bicep": + return SerializeBicep(options); + default: + throw new FormatException($"The model {nameof(FileSharePropertiesFileSharePaidBursting)} does not support writing '{options.Format}' format."); + } + } + + FileSharePropertiesFileSharePaidBursting IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data); + return DeserializeFileSharePropertiesFileSharePaidBursting(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(FileSharePropertiesFileSharePaidBursting)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileSharePropertiesFileSharePaidBursting.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileSharePropertiesFileSharePaidBursting.cs new file mode 100644 index 000000000000..c4a58554db03 --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileSharePropertiesFileSharePaidBursting.cs @@ -0,0 +1,76 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Storage.Models +{ + /// File Share Paid Bursting properties. + public partial class FileSharePropertiesFileSharePaidBursting + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + public FileSharePropertiesFileSharePaidBursting() + { + } + + /// Initializes a new instance of . + /// Indicates whether paid bursting is enabled for the share. This property is only for file shares created under Files Provisioned v1 SSD account type. + /// The maximum paid bursting IOPS for the share. This property is only for file shares created under Files Provisioned v1 SSD account type. The maximum allowed value is 102400 which is the maximum allowed IOPS for a share. + /// The maximum paid bursting bandwidth for the share, in mebibytes per second. This property is only for file shares created under Files Provisioned v1 SSD account type. The maximum allowed value is 10340 which is the maximum allowed bandwidth for a share. + /// Keeps track of any properties unknown to the library. + internal FileSharePropertiesFileSharePaidBursting(bool? paidBurstingEnabled, int? paidBurstingMaxIops, int? paidBurstingMaxBandwidthMibps, IDictionary serializedAdditionalRawData) + { + PaidBurstingEnabled = paidBurstingEnabled; + PaidBurstingMaxIops = paidBurstingMaxIops; + PaidBurstingMaxBandwidthMibps = paidBurstingMaxBandwidthMibps; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// Indicates whether paid bursting is enabled for the share. This property is only for file shares created under Files Provisioned v1 SSD account type. + [WirePath("paidBurstingEnabled")] + public bool? PaidBurstingEnabled { get; set; } + /// The maximum paid bursting IOPS for the share. This property is only for file shares created under Files Provisioned v1 SSD account type. The maximum allowed value is 102400 which is the maximum allowed IOPS for a share. + [WirePath("paidBurstingMaxIops")] + public int? PaidBurstingMaxIops { get; set; } + /// The maximum paid bursting bandwidth for the share, in mebibytes per second. This property is only for file shares created under Files Provisioned v1 SSD account type. The maximum allowed value is 10340 which is the maximum allowed bandwidth for a share. + [WirePath("paidBurstingMaxBandwidthMibps")] + public int? PaidBurstingMaxBandwidthMibps { get; set; } + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareRecommendations.Serialization.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareRecommendations.Serialization.cs new file mode 100644 index 000000000000..4725dcf42aba --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareRecommendations.Serialization.cs @@ -0,0 +1,256 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Storage.Models +{ + public partial class FileShareRecommendations : IUtf8JsonSerializable, IJsonModel + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileShareRecommendations)} does not support writing '{format}' format."); + } + + if (options.Format != "W" && Optional.IsDefined(BaseIops)) + { + writer.WritePropertyName("baseIOPS"u8); + writer.WriteNumberValue(BaseIops.Value); + } + if (options.Format != "W" && Optional.IsDefined(IoScalar)) + { + writer.WritePropertyName("ioScalar"u8); + writer.WriteNumberValue(IoScalar.Value); + } + if (options.Format != "W" && Optional.IsDefined(BaseBandwidthMiBPerSec)) + { + writer.WritePropertyName("baseBandwidthMiBPerSec"u8); + writer.WriteNumberValue(BaseBandwidthMiBPerSec.Value); + } + if (options.Format != "W" && Optional.IsDefined(BandwidthScalar)) + { + writer.WritePropertyName("bandwidthScalar"u8); + writer.WriteNumberValue(BandwidthScalar.Value); + } + if (options.Format != "W" && _serializedAdditionalRawData != null) + { + foreach (var item in _serializedAdditionalRawData) + { + writer.WritePropertyName(item.Key); +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + FileShareRecommendations IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(FileShareRecommendations)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeFileShareRecommendations(document.RootElement, options); + } + + internal static FileShareRecommendations DeserializeFileShareRecommendations(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + int? baseIOPS = default; + double? ioScalar = default; + int? baseBandwidthMiBPerSec = default; + double? bandwidthScalar = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("baseIOPS"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + baseIOPS = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("ioScalar"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + ioScalar = property.Value.GetDouble(); + continue; + } + if (property.NameEquals("baseBandwidthMiBPerSec"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + baseBandwidthMiBPerSec = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("bandwidthScalar"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + bandwidthScalar = property.Value.GetDouble(); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new FileShareRecommendations(baseIOPS, ioScalar, baseBandwidthMiBPerSec, bandwidthScalar, serializedAdditionalRawData); + } + + private BinaryData SerializeBicep(ModelReaderWriterOptions options) + { + StringBuilder builder = new StringBuilder(); + BicepModelReaderWriterOptions bicepOptions = options as BicepModelReaderWriterOptions; + IDictionary propertyOverrides = null; + bool hasObjectOverride = bicepOptions != null && bicepOptions.PropertyOverrides.TryGetValue(this, out propertyOverrides); + bool hasPropertyOverride = false; + string propertyOverride = null; + + builder.AppendLine("{"); + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(BaseIops), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" baseIOPS: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(BaseIops)) + { + builder.Append(" baseIOPS: "); + builder.AppendLine($"{BaseIops.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(IoScalar), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" ioScalar: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(IoScalar)) + { + builder.Append(" ioScalar: "); + builder.AppendLine($"'{IoScalar.Value.ToString()}'"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(BaseBandwidthMiBPerSec), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" baseBandwidthMiBPerSec: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(BaseBandwidthMiBPerSec)) + { + builder.Append(" baseBandwidthMiBPerSec: "); + builder.AppendLine($"{BaseBandwidthMiBPerSec.Value}"); + } + } + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(BandwidthScalar), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" bandwidthScalar: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(BandwidthScalar)) + { + builder.Append(" bandwidthScalar: "); + builder.AppendLine($"'{BandwidthScalar.Value.ToString()}'"); + } + } + + builder.AppendLine("}"); + return BinaryData.FromString(builder.ToString()); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options); + case "bicep": + return SerializeBicep(options); + default: + throw new FormatException($"The model {nameof(FileShareRecommendations)} does not support writing '{options.Format}' format."); + } + } + + FileShareRecommendations IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data); + return DeserializeFileShareRecommendations(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(FileShareRecommendations)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareRecommendations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareRecommendations.cs new file mode 100644 index 000000000000..9cdb665a3ed1 --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/FileShareRecommendations.cs @@ -0,0 +1,81 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Storage.Models +{ + /// Constants used for calculating recommended provisioned IOPS and bandwidth for a file share in the storage account. + public partial class FileShareRecommendations + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + internal FileShareRecommendations() + { + } + + /// Initializes a new instance of . + /// The base IOPS in the file share provisioned IOPS recommendation formula. + /// The scalar for IO in the file share provisioned IOPS recommendation formula. + /// The base bandwidth in the file share provisioned bandwidth recommendation formula. + /// The scalar for bandwidth in the file share provisioned bandwidth recommendation formula. + /// Keeps track of any properties unknown to the library. + internal FileShareRecommendations(int? baseIops, double? ioScalar, int? baseBandwidthMiBPerSec, double? bandwidthScalar, IDictionary serializedAdditionalRawData) + { + BaseIops = baseIops; + IoScalar = ioScalar; + BaseBandwidthMiBPerSec = baseBandwidthMiBPerSec; + BandwidthScalar = bandwidthScalar; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// The base IOPS in the file share provisioned IOPS recommendation formula. + [WirePath("baseIOPS")] + public int? BaseIops { get; } + /// The scalar for IO in the file share provisioned IOPS recommendation formula. + [WirePath("ioScalar")] + public double? IoScalar { get; } + /// The base bandwidth in the file share provisioned bandwidth recommendation formula. + [WirePath("baseBandwidthMiBPerSec")] + public int? BaseBandwidthMiBPerSec { get; } + /// The scalar for bandwidth in the file share provisioned bandwidth recommendation formula. + [WirePath("bandwidthScalar")] + public double? BandwidthScalar { get; } + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/ObjectReplicationPolicyPropertiesMetrics.Serialization.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/ObjectReplicationPolicyPropertiesMetrics.Serialization.cs new file mode 100644 index 000000000000..7f0c526a1056 --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/ObjectReplicationPolicyPropertiesMetrics.Serialization.cs @@ -0,0 +1,167 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Storage.Models +{ + internal partial class ObjectReplicationPolicyPropertiesMetrics : IUtf8JsonSerializable, IJsonModel + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(ObjectReplicationPolicyPropertiesMetrics)} does not support writing '{format}' format."); + } + + if (Optional.IsDefined(IsMetricsEnabled)) + { + writer.WritePropertyName("enabled"u8); + writer.WriteBooleanValue(IsMetricsEnabled.Value); + } + if (options.Format != "W" && _serializedAdditionalRawData != null) + { + foreach (var item in _serializedAdditionalRawData) + { + writer.WritePropertyName(item.Key); +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + ObjectReplicationPolicyPropertiesMetrics IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(ObjectReplicationPolicyPropertiesMetrics)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeObjectReplicationPolicyPropertiesMetrics(document.RootElement, options); + } + + internal static ObjectReplicationPolicyPropertiesMetrics DeserializeObjectReplicationPolicyPropertiesMetrics(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + bool? enabled = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("enabled"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + enabled = property.Value.GetBoolean(); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new ObjectReplicationPolicyPropertiesMetrics(enabled, serializedAdditionalRawData); + } + + private BinaryData SerializeBicep(ModelReaderWriterOptions options) + { + StringBuilder builder = new StringBuilder(); + BicepModelReaderWriterOptions bicepOptions = options as BicepModelReaderWriterOptions; + IDictionary propertyOverrides = null; + bool hasObjectOverride = bicepOptions != null && bicepOptions.PropertyOverrides.TryGetValue(this, out propertyOverrides); + bool hasPropertyOverride = false; + string propertyOverride = null; + + builder.AppendLine("{"); + + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue(nameof(IsMetricsEnabled), out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" enabled: "); + builder.AppendLine(propertyOverride); + } + else + { + if (Optional.IsDefined(IsMetricsEnabled)) + { + builder.Append(" enabled: "); + var boolValue = IsMetricsEnabled.Value == true ? "true" : "false"; + builder.AppendLine($"{boolValue}"); + } + } + + builder.AppendLine("}"); + return BinaryData.FromString(builder.ToString()); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options); + case "bicep": + return SerializeBicep(options); + default: + throw new FormatException($"The model {nameof(ObjectReplicationPolicyPropertiesMetrics)} does not support writing '{options.Format}' format."); + } + } + + ObjectReplicationPolicyPropertiesMetrics IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data); + return DeserializeObjectReplicationPolicyPropertiesMetrics(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(ObjectReplicationPolicyPropertiesMetrics)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/ObjectReplicationPolicyPropertiesMetrics.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/ObjectReplicationPolicyPropertiesMetrics.cs new file mode 100644 index 000000000000..a239d5ed339b --- /dev/null +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/ObjectReplicationPolicyPropertiesMetrics.cs @@ -0,0 +1,66 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Storage.Models +{ + /// Optional. The object replication policy metrics feature options. + internal partial class ObjectReplicationPolicyPropertiesMetrics + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + public ObjectReplicationPolicyPropertiesMetrics() + { + } + + /// Initializes a new instance of . + /// Indicates whether object replication metrics feature is enabled for the policy. + /// Keeps track of any properties unknown to the library. + internal ObjectReplicationPolicyPropertiesMetrics(bool? isMetricsEnabled, IDictionary serializedAdditionalRawData) + { + IsMetricsEnabled = isMetricsEnabled; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// Indicates whether object replication metrics feature is enabled for the policy. + [WirePath("enabled")] + public bool? IsMetricsEnabled { get; set; } + } +} diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/StorageSkuName.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/StorageSkuName.cs index 7e5741fbba27..29b3507d9460 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/StorageSkuName.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/Models/StorageSkuName.cs @@ -30,6 +30,12 @@ public StorageSkuName(string value) private const string PremiumZrsValue = "Premium_ZRS"; private const string StandardGzrsValue = "Standard_GZRS"; private const string StandardRagzrsValue = "Standard_RAGZRS"; + private const string StandardV2LrsValue = "StandardV2_LRS"; + private const string StandardV2GrsValue = "StandardV2_GRS"; + private const string StandardV2ZrsValue = "StandardV2_ZRS"; + private const string StandardV2GzrsValue = "StandardV2_GZRS"; + private const string PremiumV2LrsValue = "PremiumV2_LRS"; + private const string PremiumV2ZrsValue = "PremiumV2_ZRS"; /// Standard_LRS. public static StorageSkuName StandardLrs { get; } = new StorageSkuName(StandardLrsValue); @@ -47,6 +53,18 @@ public StorageSkuName(string value) public static StorageSkuName StandardGzrs { get; } = new StorageSkuName(StandardGzrsValue); /// Standard_RAGZRS. public static StorageSkuName StandardRagzrs { get; } = new StorageSkuName(StandardRagzrsValue); + /// StandardV2_LRS. + public static StorageSkuName StandardV2Lrs { get; } = new StorageSkuName(StandardV2LrsValue); + /// StandardV2_GRS. + public static StorageSkuName StandardV2Grs { get; } = new StorageSkuName(StandardV2GrsValue); + /// StandardV2_ZRS. + public static StorageSkuName StandardV2Zrs { get; } = new StorageSkuName(StandardV2ZrsValue); + /// StandardV2_GZRS. + public static StorageSkuName StandardV2Gzrs { get; } = new StorageSkuName(StandardV2GzrsValue); + /// PremiumV2_LRS. + public static StorageSkuName PremiumV2Lrs { get; } = new StorageSkuName(PremiumV2LrsValue); + /// PremiumV2_ZRS. + public static StorageSkuName PremiumV2Zrs { get; } = new StorageSkuName(PremiumV2ZrsValue); /// Determines if two values are the same. public static bool operator ==(StorageSkuName left, StorageSkuName right) => left.Equals(right); /// Determines if two values are not the same. diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/NetworkSecurityPerimeterConfigurationCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/NetworkSecurityPerimeterConfigurationCollection.cs index 5c0569f99454..10da398287d4 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/NetworkSecurityPerimeterConfigurationCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/NetworkSecurityPerimeterConfigurationCollection.cs @@ -64,7 +64,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -109,7 +109,7 @@ public virtual async Task /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -154,7 +154,7 @@ public virtual Response Get(strin /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -183,7 +183,7 @@ public virtual AsyncPageable GetA /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -212,7 +212,7 @@ public virtual Pageable GetAll(Ca /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -255,7 +255,7 @@ public virtual async Task> ExistsAsync(string networkSecurityPeri /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -298,7 +298,7 @@ public virtual Response Exists(string networkSecurityPerimeterConfiguratio /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -343,7 +343,7 @@ public virtual async Task /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/NetworkSecurityPerimeterConfigurationResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/NetworkSecurityPerimeterConfigurationResource.cs index 0553d6ab5961..1ced8ef9ad3a 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/NetworkSecurityPerimeterConfigurationResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/NetworkSecurityPerimeterConfigurationResource.cs @@ -101,7 +101,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -141,7 +141,7 @@ public virtual async Task /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -181,7 +181,7 @@ public virtual Response Get(Cance /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -223,7 +223,7 @@ public virtual async Task ReconcileAsync(WaitUntil waitUntil, Canc /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyCollection.cs index 877f6a42e67e..d0880300ebd9 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyCollection.cs @@ -64,7 +64,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -115,7 +115,7 @@ public virtual async Task> CreateO /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -166,7 +166,7 @@ public virtual ArmOperation CreateOrUpdate(Wait /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -211,7 +211,7 @@ public virtual async Task> GetAsync(st /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -256,7 +256,7 @@ public virtual Response Get(string objectReplic /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -285,7 +285,7 @@ public virtual AsyncPageable GetAllAsync(Cancel /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -314,7 +314,7 @@ public virtual Pageable GetAll(CancellationToke /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -357,7 +357,7 @@ public virtual async Task> ExistsAsync(string objectReplicationPo /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -400,7 +400,7 @@ public virtual Response Exists(string objectReplicationPolicyId, Cancellat /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -445,7 +445,7 @@ public virtual async Task> Get /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyData.Serialization.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyData.Serialization.cs index 64745021ae4f..532d546cdb8d 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyData.Serialization.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyData.Serialization.cs @@ -71,6 +71,11 @@ protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWri } writer.WriteEndArray(); } + if (Optional.IsDefined(Metrics)) + { + writer.WritePropertyName("metrics"u8); + writer.WriteObjectValue(Metrics, options); + } writer.WriteEndObject(); } @@ -103,6 +108,7 @@ internal static ObjectReplicationPolicyData DeserializeObjectReplicationPolicyDa string sourceAccount = default; string destinationAccount = default; IList rules = default; + ObjectReplicationPolicyPropertiesMetrics metrics = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) @@ -178,6 +184,15 @@ internal static ObjectReplicationPolicyData DeserializeObjectReplicationPolicyDa rules = array; continue; } + if (property0.NameEquals("metrics"u8)) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + metrics = ObjectReplicationPolicyPropertiesMetrics.DeserializeObjectReplicationPolicyPropertiesMetrics(property0.Value, options); + continue; + } } continue; } @@ -197,6 +212,7 @@ internal static ObjectReplicationPolicyData DeserializeObjectReplicationPolicyDa sourceAccount, destinationAccount, rules ?? new ChangeTrackingList(), + metrics, serializedAdditionalRawData); } @@ -374,6 +390,26 @@ private BinaryData SerializeBicep(ModelReaderWriterOptions options) } } + hasPropertyOverride = hasObjectOverride && propertyOverrides.TryGetValue("IsMetricsEnabled", out propertyOverride); + if (hasPropertyOverride) + { + builder.Append(" metrics: "); + builder.AppendLine("{"); + builder.AppendLine(" metrics: {"); + builder.Append(" enabled: "); + builder.AppendLine(propertyOverride); + builder.AppendLine(" }"); + builder.AppendLine(" }"); + } + else + { + if (Optional.IsDefined(Metrics)) + { + builder.Append(" metrics: "); + BicepSerializationHelpers.AppendChildObject(builder, Metrics, options, 4, false, " metrics: "); + } + } + builder.AppendLine(" }"); builder.AppendLine("}"); return BinaryData.FromString(builder.ToString()); diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyData.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyData.cs index 36c5798c0da2..919afce03a26 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyData.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyData.cs @@ -67,14 +67,16 @@ public ObjectReplicationPolicyData() /// Required. Source account name. It should be full resource id if allowCrossTenantReplication set to false. /// Required. Destination account name. It should be full resource id if allowCrossTenantReplication set to false. /// The storage account object replication rules. + /// Optional. The object replication policy metrics feature options. /// Keeps track of any properties unknown to the library. - internal ObjectReplicationPolicyData(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, string policyId, DateTimeOffset? enabledOn, string sourceAccount, string destinationAccount, IList rules, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData) + internal ObjectReplicationPolicyData(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, string policyId, DateTimeOffset? enabledOn, string sourceAccount, string destinationAccount, IList rules, ObjectReplicationPolicyPropertiesMetrics metrics, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData) { PolicyId = policyId; EnabledOn = enabledOn; SourceAccount = sourceAccount; DestinationAccount = destinationAccount; Rules = rules; + Metrics = metrics; _serializedAdditionalRawData = serializedAdditionalRawData; } @@ -93,5 +95,19 @@ internal ObjectReplicationPolicyData(ResourceIdentifier id, string name, Resourc /// The storage account object replication rules. [WirePath("properties.rules")] public IList Rules { get; } + /// Optional. The object replication policy metrics feature options. + internal ObjectReplicationPolicyPropertiesMetrics Metrics { get; set; } + /// Indicates whether object replication metrics feature is enabled for the policy. + [WirePath("properties.metrics.enabled")] + public bool? IsMetricsEnabled + { + get => Metrics is null ? default : Metrics.IsMetricsEnabled; + set + { + if (Metrics is null) + Metrics = new ObjectReplicationPolicyPropertiesMetrics(); + Metrics.IsMetricsEnabled = value; + } + } } } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyResource.cs index fb992453603d..e3a455848fdc 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/ObjectReplicationPolicyResource.cs @@ -101,7 +101,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -141,7 +141,7 @@ public virtual async Task> GetAsync(Ca /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -181,7 +181,7 @@ public virtual Response Get(CancellationToken c /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -225,7 +225,7 @@ public virtual async Task DeleteAsync(WaitUntil waitUntil, Cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -269,7 +269,7 @@ public virtual ArmOperation Delete(WaitUntil waitUntil, CancellationToken cancel /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -317,7 +317,7 @@ public virtual async Task> UpdateA /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/QueueServiceResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/QueueServiceResource.cs index 97304f827558..893294fa771f 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/QueueServiceResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/QueueServiceResource.cs @@ -107,7 +107,7 @@ public virtual StorageQueueCollection GetStorageQueues() /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -138,7 +138,7 @@ public virtual async Task> GetStorageQueueAsync(s /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -169,7 +169,7 @@ public virtual Response GetStorageQueue(string queueName, /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -209,7 +209,7 @@ public virtual async Task> GetAsync(CancellationT /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -249,7 +249,7 @@ public virtual Response Get(CancellationToken cancellation /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -297,7 +297,7 @@ public virtual async Task> CreateOrUpdateAsyn /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/BlobContainersRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/BlobContainersRestOperations.cs index f3cad7af2400..8b6b05983753 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/BlobContainersRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/BlobContainersRestOperations.cs @@ -32,7 +32,7 @@ public BlobContainersRestOperations(HttpPipeline pipeline, string applicationId, { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } @@ -849,7 +849,7 @@ internal HttpMessage CreateCreateOrUpdateImmutabilityPolicyRequest(string subscr /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. /// The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. /// The ImmutabilityPolicy Properties that will be created or updated to a blob container. - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. /// , , , or is null. /// , , or is an empty string, and was expected to be non-empty. @@ -883,7 +883,7 @@ public async Task> CreateOrUpdateImmutabilityPo /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. /// The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. /// The ImmutabilityPolicy Properties that will be created or updated to a blob container. - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. /// , , , or is null. /// , , or is an empty string, and was expected to be non-empty. @@ -962,7 +962,7 @@ internal HttpMessage CreateGetImmutabilityPolicyRequest(string subscriptionId, s /// The name of the resource group within the user's subscription. The name is case insensitive. /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. /// The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. /// , , or is null. /// , , or is an empty string, and was expected to be non-empty. @@ -996,7 +996,7 @@ public async Task> GetImmutabilityPolicyAsync(s /// The name of the resource group within the user's subscription. The name is case insensitive. /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. /// The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. /// , , or is null. /// , , or is an empty string, and was expected to be non-empty. @@ -1073,7 +1073,7 @@ internal HttpMessage CreateDeleteImmutabilityPolicyRequest(string subscriptionId /// The name of the resource group within the user's subscription. The name is case insensitive. /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. /// The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. /// , , or is null. /// , , or is an empty string, and was expected to be non-empty. @@ -1105,7 +1105,7 @@ public async Task> DeleteImmutabilityPolicyAsyn /// The name of the resource group within the user's subscription. The name is case insensitive. /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. /// The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. /// , , or is null. /// , , or is an empty string, and was expected to be non-empty. @@ -1178,7 +1178,7 @@ internal HttpMessage CreateLockImmutabilityPolicyRequest(string subscriptionId, /// The name of the resource group within the user's subscription. The name is case insensitive. /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. /// The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. /// , , or is null. /// , , or is an empty string, and was expected to be non-empty. @@ -1210,7 +1210,7 @@ public async Task> LockImmutabilityPolicyAsync( /// The name of the resource group within the user's subscription. The name is case insensitive. /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. /// The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The cancellation token to use. /// , , or is null. /// , , or is an empty string, and was expected to be non-empty. @@ -1290,7 +1290,7 @@ internal HttpMessage CreateExtendImmutabilityPolicyRequest(string subscriptionId /// The name of the resource group within the user's subscription. The name is case insensitive. /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. /// The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The ImmutabilityPolicy Properties that will be extended for a blob container. /// The cancellation token to use. /// , , or is null. @@ -1323,7 +1323,7 @@ public async Task> ExtendImmutabilityPolicyAsyn /// The name of the resource group within the user's subscription. The name is case insensitive. /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. /// The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. - /// The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. + /// The entity state (ETag) version of the immutability policy to update must be returned to the server for all update operations. The ETag value must include the leading and trailing double quotes as returned by the service. /// The ImmutabilityPolicy Properties that will be extended for a blob container. /// The cancellation token to use. /// , , or is null. diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/BlobInventoryPoliciesRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/BlobInventoryPoliciesRestOperations.cs index 007647e80352..ca746278d950 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/BlobInventoryPoliciesRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/BlobInventoryPoliciesRestOperations.cs @@ -32,7 +32,7 @@ public BlobInventoryPoliciesRestOperations(HttpPipeline pipeline, string applica { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/BlobServicesRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/BlobServicesRestOperations.cs index 0ae1cffdb9fc..fe9ee4504723 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/BlobServicesRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/BlobServicesRestOperations.cs @@ -32,7 +32,7 @@ public BlobServicesRestOperations(HttpPipeline pipeline, string applicationId, U { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/DeletedAccountsRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/DeletedAccountsRestOperations.cs index 206dc555d10b..871741a84c6f 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/DeletedAccountsRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/DeletedAccountsRestOperations.cs @@ -32,7 +32,7 @@ public DeletedAccountsRestOperations(HttpPipeline pipeline, string applicationId { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/EncryptionScopesRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/EncryptionScopesRestOperations.cs index 64242cc7baaa..296820e9752c 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/EncryptionScopesRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/EncryptionScopesRestOperations.cs @@ -32,7 +32,7 @@ public EncryptionScopesRestOperations(HttpPipeline pipeline, string applicationI { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/FileServicesRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/FileServicesRestOperations.cs index 55c572b420f4..80f85e826155 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/FileServicesRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/FileServicesRestOperations.cs @@ -32,7 +32,7 @@ public FileServicesRestOperations(HttpPipeline pipeline, string applicationId, U { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } @@ -333,5 +333,303 @@ public Response GetServiceProperties(string subscriptionId, str throw new RequestFailedException(message.Response); } } + + internal RequestUriBuilder CreateListServiceUsagesRequestUri(string subscriptionId, string resourceGroupName, string accountName, int? maxpagesize) + { + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Storage/storageAccounts/", false); + uri.AppendPath(accountName, true); + uri.AppendPath("/fileServices/", false); + uri.AppendPath("default", true); + uri.AppendPath("/usages", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (maxpagesize != null) + { + uri.AppendQuery("$maxpagesize", maxpagesize.Value, true); + } + return uri; + } + + internal HttpMessage CreateListServiceUsagesRequest(string subscriptionId, string resourceGroupName, string accountName, int? maxpagesize) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Storage/storageAccounts/", false); + uri.AppendPath(accountName, true); + uri.AppendPath("/fileServices/", false); + uri.AppendPath("default", true); + uri.AppendPath("/usages", false); + uri.AppendQuery("api-version", _apiVersion, true); + if (maxpagesize != null) + { + uri.AppendQuery("$maxpagesize", maxpagesize.Value, true); + } + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + _userAgent.Apply(message); + return message; + } + + /// Gets the usages of file service in storage account. + /// The ID of the target subscription. + /// The name of the resource group within the user's subscription. The name is case insensitive. + /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. + /// Optional, specifies the maximum number of file service usages to be included in the list response. + /// The cancellation token to use. + /// , or is null. + /// , or is an empty string, and was expected to be non-empty. + public async Task> ListServiceUsagesAsync(string subscriptionId, string resourceGroupName, string accountName, int? maxpagesize = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(accountName, nameof(accountName)); + + using var message = CreateListServiceUsagesRequest(subscriptionId, resourceGroupName, accountName, maxpagesize); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + FileServiceUsages value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); + value = FileServiceUsages.DeserializeFileServiceUsages(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } + + /// Gets the usages of file service in storage account. + /// The ID of the target subscription. + /// The name of the resource group within the user's subscription. The name is case insensitive. + /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. + /// Optional, specifies the maximum number of file service usages to be included in the list response. + /// The cancellation token to use. + /// , or is null. + /// , or is an empty string, and was expected to be non-empty. + public Response ListServiceUsages(string subscriptionId, string resourceGroupName, string accountName, int? maxpagesize = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(accountName, nameof(accountName)); + + using var message = CreateListServiceUsagesRequest(subscriptionId, resourceGroupName, accountName, maxpagesize); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + FileServiceUsages value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream); + value = FileServiceUsages.DeserializeFileServiceUsages(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } + + internal RequestUriBuilder CreateGetServiceUsageRequestUri(string subscriptionId, string resourceGroupName, string accountName) + { + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Storage/storageAccounts/", false); + uri.AppendPath(accountName, true); + uri.AppendPath("/fileServices/", false); + uri.AppendPath("default", true); + uri.AppendPath("/usages/", false); + uri.AppendPath("default", true); + uri.AppendQuery("api-version", _apiVersion, true); + return uri; + } + + internal HttpMessage CreateGetServiceUsageRequest(string subscriptionId, string resourceGroupName, string accountName) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Storage/storageAccounts/", false); + uri.AppendPath(accountName, true); + uri.AppendPath("/fileServices/", false); + uri.AppendPath("default", true); + uri.AppendPath("/usages/", false); + uri.AppendPath("default", true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + _userAgent.Apply(message); + return message; + } + + /// Gets the usage of file service in storage account including account limits, file share limits and constants used in recommendations and bursting formula. + /// The ID of the target subscription. + /// The name of the resource group within the user's subscription. The name is case insensitive. + /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. + /// The cancellation token to use. + /// , or is null. + /// , or is an empty string, and was expected to be non-empty. + public async Task> GetServiceUsageAsync(string subscriptionId, string resourceGroupName, string accountName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(accountName, nameof(accountName)); + + using var message = CreateGetServiceUsageRequest(subscriptionId, resourceGroupName, accountName); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + FileServiceUsageData value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); + value = FileServiceUsageData.DeserializeFileServiceUsageData(document.RootElement); + return Response.FromValue(value, message.Response); + } + case 404: + return Response.FromValue((FileServiceUsageData)null, message.Response); + default: + throw new RequestFailedException(message.Response); + } + } + + /// Gets the usage of file service in storage account including account limits, file share limits and constants used in recommendations and bursting formula. + /// The ID of the target subscription. + /// The name of the resource group within the user's subscription. The name is case insensitive. + /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. + /// The cancellation token to use. + /// , or is null. + /// , or is an empty string, and was expected to be non-empty. + public Response GetServiceUsage(string subscriptionId, string resourceGroupName, string accountName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(accountName, nameof(accountName)); + + using var message = CreateGetServiceUsageRequest(subscriptionId, resourceGroupName, accountName); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + FileServiceUsageData value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream); + value = FileServiceUsageData.DeserializeFileServiceUsageData(document.RootElement); + return Response.FromValue(value, message.Response); + } + case 404: + return Response.FromValue((FileServiceUsageData)null, message.Response); + default: + throw new RequestFailedException(message.Response); + } + } + + internal RequestUriBuilder CreateListServiceUsagesNextPageRequestUri(string nextLink, string subscriptionId, string resourceGroupName, string accountName, int? maxpagesize) + { + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRawNextLink(nextLink, false); + return uri; + } + + internal HttpMessage CreateListServiceUsagesNextPageRequest(string nextLink, string subscriptionId, string resourceGroupName, string accountName, int? maxpagesize) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRawNextLink(nextLink, false); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + _userAgent.Apply(message); + return message; + } + + /// Gets the usages of file service in storage account. + /// The URL to the next page of results. + /// The ID of the target subscription. + /// The name of the resource group within the user's subscription. The name is case insensitive. + /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. + /// Optional, specifies the maximum number of file service usages to be included in the list response. + /// The cancellation token to use. + /// , , or is null. + /// , or is an empty string, and was expected to be non-empty. + public async Task> ListServiceUsagesNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string accountName, int? maxpagesize = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(nextLink, nameof(nextLink)); + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(accountName, nameof(accountName)); + + using var message = CreateListServiceUsagesNextPageRequest(nextLink, subscriptionId, resourceGroupName, accountName, maxpagesize); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + FileServiceUsages value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); + value = FileServiceUsages.DeserializeFileServiceUsages(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } + + /// Gets the usages of file service in storage account. + /// The URL to the next page of results. + /// The ID of the target subscription. + /// The name of the resource group within the user's subscription. The name is case insensitive. + /// The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. + /// Optional, specifies the maximum number of file service usages to be included in the list response. + /// The cancellation token to use. + /// , , or is null. + /// , or is an empty string, and was expected to be non-empty. + public Response ListServiceUsagesNextPage(string nextLink, string subscriptionId, string resourceGroupName, string accountName, int? maxpagesize = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(nextLink, nameof(nextLink)); + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(accountName, nameof(accountName)); + + using var message = CreateListServiceUsagesNextPageRequest(nextLink, subscriptionId, resourceGroupName, accountName, maxpagesize); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + FileServiceUsages value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream); + value = FileServiceUsages.DeserializeFileServiceUsages(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } } } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/FileSharesRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/FileSharesRestOperations.cs index 5ea4e221b919..26f9bf4f5540 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/FileSharesRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/FileSharesRestOperations.cs @@ -32,7 +32,7 @@ public FileSharesRestOperations(HttpPipeline pipeline, string applicationId, Uri { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/LocalUsersRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/LocalUsersRestOperations.cs index 622a2ab8231c..05fcc2bc6a4c 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/LocalUsersRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/LocalUsersRestOperations.cs @@ -32,7 +32,7 @@ public LocalUsersRestOperations(HttpPipeline pipeline, string applicationId, Uri { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/ManagementPoliciesRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/ManagementPoliciesRestOperations.cs index c691736d4aa5..6f7286a60720 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/ManagementPoliciesRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/ManagementPoliciesRestOperations.cs @@ -32,7 +32,7 @@ public ManagementPoliciesRestOperations(HttpPipeline pipeline, string applicatio { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/NetworkSecurityPerimeterConfigurationsRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/NetworkSecurityPerimeterConfigurationsRestOperations.cs index 60d12ad682e4..9b845b2c1ced 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/NetworkSecurityPerimeterConfigurationsRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/NetworkSecurityPerimeterConfigurationsRestOperations.cs @@ -32,7 +32,7 @@ public NetworkSecurityPerimeterConfigurationsRestOperations(HttpPipeline pipelin { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/ObjectReplicationPoliciesRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/ObjectReplicationPoliciesRestOperations.cs index e25140a7863c..442d5e658737 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/ObjectReplicationPoliciesRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/ObjectReplicationPoliciesRestOperations.cs @@ -32,7 +32,7 @@ public ObjectReplicationPoliciesRestOperations(HttpPipeline pipeline, string app { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/PrivateEndpointConnectionsRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/PrivateEndpointConnectionsRestOperations.cs index b4df5129a17b..0ccff835f41f 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/PrivateEndpointConnectionsRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/PrivateEndpointConnectionsRestOperations.cs @@ -32,7 +32,7 @@ public PrivateEndpointConnectionsRestOperations(HttpPipeline pipeline, string ap { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/PrivateLinkResourcesRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/PrivateLinkResourcesRestOperations.cs index 0683acd1d555..904aae1e55ff 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/PrivateLinkResourcesRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/PrivateLinkResourcesRestOperations.cs @@ -32,7 +32,7 @@ public PrivateLinkResourcesRestOperations(HttpPipeline pipeline, string applicat { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/QueueRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/QueueRestOperations.cs index 298db4357d7f..c4e5374ab354 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/QueueRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/QueueRestOperations.cs @@ -32,7 +32,7 @@ public QueueRestOperations(HttpPipeline pipeline, string applicationId, Uri endp { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/QueueServicesRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/QueueServicesRestOperations.cs index a947f10d60be..1468ebd167d4 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/QueueServicesRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/QueueServicesRestOperations.cs @@ -32,7 +32,7 @@ public QueueServicesRestOperations(HttpPipeline pipeline, string applicationId, { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/SkusRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/SkusRestOperations.cs index b4d7dc732ab9..2d119e7c1e5a 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/SkusRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/SkusRestOperations.cs @@ -32,7 +32,7 @@ public SkusRestOperations(HttpPipeline pipeline, string applicationId, Uri endpo { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageAccountsRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageAccountsRestOperations.cs index b96d92c89791..51f965c0d9df 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageAccountsRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageAccountsRestOperations.cs @@ -32,7 +32,7 @@ public StorageAccountsRestOperations(HttpPipeline pipeline, string applicationId { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageTaskAssignmentInstancesReportRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageTaskAssignmentInstancesReportRestOperations.cs index 5335d2298a8e..eaacd56ff1de 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageTaskAssignmentInstancesReportRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageTaskAssignmentInstancesReportRestOperations.cs @@ -32,7 +32,7 @@ public StorageTaskAssignmentInstancesReportRestOperations(HttpPipeline pipeline, { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageTaskAssignmentsInstancesReportRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageTaskAssignmentsInstancesReportRestOperations.cs index 6e661ac99b38..f72e177e5250 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageTaskAssignmentsInstancesReportRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageTaskAssignmentsInstancesReportRestOperations.cs @@ -32,7 +32,7 @@ public StorageTaskAssignmentsInstancesReportRestOperations(HttpPipeline pipeline { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageTaskAssignmentsRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageTaskAssignmentsRestOperations.cs index d663c47d65eb..81e5f93e785f 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageTaskAssignmentsRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/StorageTaskAssignmentsRestOperations.cs @@ -32,7 +32,7 @@ public StorageTaskAssignmentsRestOperations(HttpPipeline pipeline, string applic { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/TableRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/TableRestOperations.cs index 8e649d7f19a0..c1f167933b7c 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/TableRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/TableRestOperations.cs @@ -32,7 +32,7 @@ public TableRestOperations(HttpPipeline pipeline, string applicationId, Uri endp { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/TableServicesRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/TableServicesRestOperations.cs index c4b5f1898cbe..e937d4260ff0 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/TableServicesRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/TableServicesRestOperations.cs @@ -32,7 +32,7 @@ public TableServicesRestOperations(HttpPipeline pipeline, string applicationId, { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/UsagesRestOperations.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/UsagesRestOperations.cs index 6e17acf55bee..9a5b6b17ca76 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/UsagesRestOperations.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/RestOperations/UsagesRestOperations.cs @@ -32,7 +32,7 @@ public UsagesRestOperations(HttpPipeline pipeline, string applicationId, Uri end { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-05-01"; + _apiVersion = apiVersion ?? "2024-01-01"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountCollection.cs index d653046eab91..13cbab541fdc 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountCollection.cs @@ -66,7 +66,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -115,7 +115,7 @@ public virtual async Task> CreateOrUpdateAs /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -164,7 +164,7 @@ public virtual ArmOperation CreateOrUpdate(WaitUntil wai /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -210,7 +210,7 @@ public virtual async Task> GetAsync(string acco /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -256,7 +256,7 @@ public virtual Response Get(string accountName, StorageA /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -286,7 +286,7 @@ public virtual AsyncPageable GetAllAsync(CancellationTok /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -316,7 +316,7 @@ public virtual Pageable GetAll(CancellationToken cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -360,7 +360,7 @@ public virtual async Task> ExistsAsync(string accountName, Storag /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -404,7 +404,7 @@ public virtual Response Exists(string accountName, StorageAccountExpand? e /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -450,7 +450,7 @@ public virtual async Task> GetIfExistsA /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountLocalUserCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountLocalUserCollection.cs index 7e5801bf793c..0be58874caef 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountLocalUserCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountLocalUserCollection.cs @@ -65,7 +65,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -116,7 +116,7 @@ public virtual async Task> CreateO /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -167,7 +167,7 @@ public virtual ArmOperation CreateOrUpdate(Wait /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -212,7 +212,7 @@ public virtual async Task> GetAsync(st /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -257,7 +257,7 @@ public virtual Response Get(string username, Ca /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -289,7 +289,7 @@ public virtual AsyncPageable GetAllAsync(int? m /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -321,7 +321,7 @@ public virtual Pageable GetAll(int? maxpagesize /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -364,7 +364,7 @@ public virtual async Task> ExistsAsync(string username, Cancellat /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -407,7 +407,7 @@ public virtual Response Exists(string username, CancellationToken cancella /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -452,7 +452,7 @@ public virtual async Task> Get /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountLocalUserResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountLocalUserResource.cs index 0cde7d603514..486562bdcb7a 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountLocalUserResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountLocalUserResource.cs @@ -102,7 +102,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -142,7 +142,7 @@ public virtual async Task> GetAsync(Ca /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -182,7 +182,7 @@ public virtual Response Get(CancellationToken c /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -226,7 +226,7 @@ public virtual async Task DeleteAsync(WaitUntil waitUntil, Cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -270,7 +270,7 @@ public virtual ArmOperation Delete(WaitUntil waitUntil, CancellationToken cancel /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -318,7 +318,7 @@ public virtual async Task> UpdateA /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -366,7 +366,7 @@ public virtual ArmOperation Update(WaitUntil wa /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -404,7 +404,7 @@ public virtual async Task> GetKeysAsync(CancellationToke /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -442,7 +442,7 @@ public virtual Response GetKeys(CancellationToken cancellationTok /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -480,7 +480,7 @@ public virtual async Task> Regenerat /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountManagementPolicyResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountManagementPolicyResource.cs index 168b8d66e306..b255283df0b8 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountManagementPolicyResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountManagementPolicyResource.cs @@ -102,7 +102,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -142,7 +142,7 @@ public virtual async Task> GetA /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -182,7 +182,7 @@ public virtual Response Get(Cancellation /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -226,7 +226,7 @@ public virtual async Task DeleteAsync(WaitUntil waitUntil, Cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -270,7 +270,7 @@ public virtual ArmOperation Delete(WaitUntil waitUntil, CancellationToken cancel /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -318,7 +318,7 @@ public virtual async Task> /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountMigrationCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountMigrationCollection.cs index 3085fd128618..9658017e3eb0 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountMigrationCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountMigrationCollection.cs @@ -62,7 +62,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -103,7 +103,7 @@ public virtual async Task> GetAsync(St /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -144,7 +144,7 @@ public virtual Response Get(StorageAccountMigra /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -183,7 +183,7 @@ public virtual async Task> ExistsAsync(StorageAccountMigrationNam /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -222,7 +222,7 @@ public virtual Response Exists(StorageAccountMigrationName migrationName, /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -263,7 +263,7 @@ public virtual async Task> Get /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountMigrationResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountMigrationResource.cs index d32406ac1b98..e17e2af3f90c 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountMigrationResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountMigrationResource.cs @@ -102,7 +102,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -142,7 +142,7 @@ public virtual async Task> GetAsync(Ca /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountResource.cs index c86d27dd2263..d142ca614ca3 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageAccountResource.cs @@ -140,7 +140,7 @@ public virtual StorageAccountMigrationCollection GetStorageAccountMigrations() /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -169,7 +169,7 @@ public virtual async Task> GetStorageA /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -219,7 +219,7 @@ public virtual StoragePrivateEndpointConnectionCollection GetStoragePrivateEndpo /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -250,7 +250,7 @@ public virtual async Task> Ge /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -288,7 +288,7 @@ public virtual ObjectReplicationPolicyCollection GetObjectReplicationPolicies() /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -319,7 +319,7 @@ public virtual async Task> GetObjectRe /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -357,7 +357,7 @@ public virtual StorageAccountLocalUserCollection GetStorageAccountLocalUsers() /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -388,7 +388,7 @@ public virtual async Task> GetStorageA /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -426,7 +426,7 @@ public virtual EncryptionScopeCollection GetEncryptionScopes() /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -457,7 +457,7 @@ public virtual async Task> GetEncryptionScopeA /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -502,7 +502,7 @@ public virtual NetworkSecurityPerimeterConfigurationCollection GetNetworkSecurit /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -533,7 +533,7 @@ public virtual async Task /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -571,7 +571,7 @@ public virtual StorageTaskAssignmentCollection GetStorageTaskAssignments() /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -602,7 +602,7 @@ public virtual async Task> GetStorageTas /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -633,7 +633,7 @@ public virtual Response GetStorageTaskAssignment( /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -674,7 +674,7 @@ public virtual async Task> GetAsync(StorageAcco /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -715,7 +715,7 @@ public virtual Response Get(StorageAccountExpand? expand /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -759,7 +759,7 @@ public virtual async Task DeleteAsync(WaitUntil waitUntil, Cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -803,7 +803,7 @@ public virtual ArmOperation Delete(WaitUntil waitUntil, CancellationToken cancel /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -845,7 +845,7 @@ public virtual async Task> UpdateAsync(StorageA /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -887,7 +887,7 @@ public virtual Response Update(StorageAccountPatch patch /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -917,7 +917,7 @@ public virtual AsyncPageable GetKeysAsync(StorageListKeyExpan /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -947,7 +947,7 @@ public virtual Pageable GetKeys(StorageListKeyExpand? expand /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -980,7 +980,7 @@ public virtual AsyncPageable RegenerateKeyAsync(StorageAccoun /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1013,7 +1013,7 @@ public virtual Pageable RegenerateKey(StorageAccountRegenerat /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1055,7 +1055,7 @@ public virtual async Task> GetAccountSasAsync(Acco /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1097,7 +1097,7 @@ public virtual Response GetAccountSas(AccountSasContent con /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1139,7 +1139,7 @@ public virtual async Task> GetServiceSasAsync(Serv /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1181,7 +1181,7 @@ public virtual Response GetServiceSas(ServiceSasContent con /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1224,7 +1224,7 @@ public virtual async Task FailoverAsync(WaitUntil waitUntil, Stora /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1267,7 +1267,7 @@ public virtual ArmOperation Failover(WaitUntil waitUntil, StorageAccountFailover /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1313,7 +1313,7 @@ public virtual async Task EnableHierarchicalNamespaceAsync(WaitUnt /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1359,7 +1359,7 @@ public virtual ArmOperation EnableHierarchicalNamespace(WaitUntil waitUntil, str /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1401,7 +1401,7 @@ public virtual async Task AbortHierarchicalNamespaceMigrationAsync /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1443,7 +1443,7 @@ public virtual ArmOperation AbortHierarchicalNamespaceMigration(WaitUntil waitUn /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1489,7 +1489,7 @@ public virtual async Task CustomerInitiatedMigrationAsync(WaitUnti /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1535,7 +1535,7 @@ public virtual ArmOperation CustomerInitiatedMigration(WaitUntil waitUntil, Stor /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1573,7 +1573,7 @@ public virtual async Task RevokeUserDelegationKeysAsync(CancellationTo /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1611,7 +1611,7 @@ public virtual Response RevokeUserDelegationKeys(CancellationToken cancellationT /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// @@ -1636,7 +1636,7 @@ public virtual AsyncPageable GetPrivateLinkResou /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// @@ -1661,7 +1661,7 @@ public virtual Pageable GetPrivateLinkResources( /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// @@ -1689,7 +1689,7 @@ public virtual AsyncPageable GetStorageTaskAssignment /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// @@ -1717,7 +1717,7 @@ public virtual Pageable GetStorageTaskAssignmentsInst /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1779,7 +1779,7 @@ public virtual async Task> AddTagAsync(string k /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1841,7 +1841,7 @@ public virtual Response AddTag(string key, string value, /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1898,7 +1898,7 @@ public virtual async Task> SetTagsAsync(IDictio /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -1955,7 +1955,7 @@ public virtual Response SetTags(IDictionary /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -2015,7 +2015,7 @@ public virtual async Task> RemoveTagAsync(strin /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StoragePrivateEndpointConnectionCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StoragePrivateEndpointConnectionCollection.cs index f85490aa0fb0..208f661032c9 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StoragePrivateEndpointConnectionCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StoragePrivateEndpointConnectionCollection.cs @@ -64,7 +64,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -115,7 +115,7 @@ public virtual async Task /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -166,7 +166,7 @@ public virtual ArmOperation CreateOrUp /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -211,7 +211,7 @@ public virtual async Task> Ge /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -256,7 +256,7 @@ public virtual Response Get(string pri /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -285,7 +285,7 @@ public virtual AsyncPageable GetAllAsy /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -314,7 +314,7 @@ public virtual Pageable GetAll(Cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -357,7 +357,7 @@ public virtual async Task> ExistsAsync(string privateEndpointConn /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -400,7 +400,7 @@ public virtual Response Exists(string privateEndpointConnectionName, Cance /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -445,7 +445,7 @@ public virtual async Task /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StoragePrivateEndpointConnectionResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StoragePrivateEndpointConnectionResource.cs index 09a9ee3a9fcb..e5e630f42c15 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StoragePrivateEndpointConnectionResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StoragePrivateEndpointConnectionResource.cs @@ -101,7 +101,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -141,7 +141,7 @@ public virtual async Task> Ge /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -181,7 +181,7 @@ public virtual Response Get(Cancellati /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -225,7 +225,7 @@ public virtual async Task DeleteAsync(WaitUntil waitUntil, Cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -269,7 +269,7 @@ public virtual ArmOperation Delete(WaitUntil waitUntil, CancellationToken cancel /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -317,7 +317,7 @@ public virtual async Task /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageQueueCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageQueueCollection.cs index 94ebe72c688d..176301fe26e8 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageQueueCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageQueueCollection.cs @@ -64,7 +64,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -115,7 +115,7 @@ public virtual async Task> CreateOrUpdateAsyn /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -166,7 +166,7 @@ public virtual ArmOperation CreateOrUpdate(WaitUntil waitU /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -211,7 +211,7 @@ public virtual async Task> GetAsync(string queueN /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -256,7 +256,7 @@ public virtual Response Get(string queueName, Cancellation /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -288,7 +288,7 @@ public virtual AsyncPageable GetAllAsync(int? maxpagesize /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -320,7 +320,7 @@ public virtual Pageable GetAll(int? maxpagesize = null, st /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -363,7 +363,7 @@ public virtual async Task> ExistsAsync(string queueName, Cancella /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -406,7 +406,7 @@ public virtual Response Exists(string queueName, CancellationToken cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -451,7 +451,7 @@ public virtual async Task> GetIfExistsAsy /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageQueueResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageQueueResource.cs index b4b6c5e44d10..355771c62d4c 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageQueueResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageQueueResource.cs @@ -101,7 +101,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -141,7 +141,7 @@ public virtual async Task> GetAsync(CancellationT /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -181,7 +181,7 @@ public virtual Response Get(CancellationToken cancellation /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -225,7 +225,7 @@ public virtual async Task DeleteAsync(WaitUntil waitUntil, Cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -269,7 +269,7 @@ public virtual ArmOperation Delete(WaitUntil waitUntil, CancellationToken cancel /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -311,7 +311,7 @@ public virtual async Task> UpdateAsync(StorageQue /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageTaskAssignmentCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageTaskAssignmentCollection.cs index 92490bf85904..fc83bd6c35ca 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageTaskAssignmentCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageTaskAssignmentCollection.cs @@ -64,7 +64,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -113,7 +113,7 @@ public virtual async Task> CreateOrU /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -162,7 +162,7 @@ public virtual ArmOperation CreateOrUpdate(WaitUn /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -207,7 +207,7 @@ public virtual async Task> GetAsync(stri /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -252,7 +252,7 @@ public virtual Response Get(string storageTaskAss /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -283,7 +283,7 @@ public virtual AsyncPageable GetAllAsync(int? max /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -314,7 +314,7 @@ public virtual Pageable GetAll(int? maxpagesize = /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -357,7 +357,7 @@ public virtual async Task> ExistsAsync(string storageTaskAssignme /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -400,7 +400,7 @@ public virtual Response Exists(string storageTaskAssignmentName, Cancellat /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -445,7 +445,7 @@ public virtual async Task> GetIf /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageTaskAssignmentResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageTaskAssignmentResource.cs index ae3a863ddaed..beb3fd324303 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageTaskAssignmentResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/StorageTaskAssignmentResource.cs @@ -107,7 +107,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -147,7 +147,7 @@ public virtual async Task> GetAsync(Canc /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -187,7 +187,7 @@ public virtual Response Get(CancellationToken can /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -229,7 +229,7 @@ public virtual async Task DeleteAsync(WaitUntil waitUntil, Cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -271,7 +271,7 @@ public virtual ArmOperation Delete(WaitUntil waitUntil, CancellationToken cancel /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -317,7 +317,7 @@ public virtual async Task> UpdateAsy /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -363,7 +363,7 @@ public virtual ArmOperation Update(WaitUntil wait /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// @@ -391,7 +391,7 @@ public virtual AsyncPageable GetStorageTaskAssignment /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/TableCollection.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/TableCollection.cs index 4702718b8ad3..5238bab6ae7b 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/TableCollection.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/TableCollection.cs @@ -64,7 +64,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -115,7 +115,7 @@ public virtual async Task> CreateOrUpdateAsync(WaitU /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -166,7 +166,7 @@ public virtual ArmOperation CreateOrUpdate(WaitUntil waitUntil, s /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -211,7 +211,7 @@ public virtual async Task> GetAsync(string tableName, Ca /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -256,7 +256,7 @@ public virtual Response Get(string tableName, CancellationToken c /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -286,7 +286,7 @@ public virtual AsyncPageable GetAllAsync(CancellationToken cancel /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -316,7 +316,7 @@ public virtual Pageable GetAll(CancellationToken cancellationToke /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -359,7 +359,7 @@ public virtual async Task> ExistsAsync(string tableName, Cancella /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -402,7 +402,7 @@ public virtual Response Exists(string tableName, CancellationToken cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -447,7 +447,7 @@ public virtual async Task> GetIfExistsAsync(stri /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/TableResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/TableResource.cs index 7199a8d5c610..93557abb52e9 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/TableResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/TableResource.cs @@ -101,7 +101,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -141,7 +141,7 @@ public virtual async Task> GetAsync(CancellationToken ca /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -181,7 +181,7 @@ public virtual Response Get(CancellationToken cancellationToken = /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -225,7 +225,7 @@ public virtual async Task DeleteAsync(WaitUntil waitUntil, Cancell /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -269,7 +269,7 @@ public virtual ArmOperation Delete(WaitUntil waitUntil, CancellationToken cancel /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -311,7 +311,7 @@ public virtual async Task> UpdateAsync(TableData data, C /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/TableServiceResource.cs b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/TableServiceResource.cs index e3fddbececa2..46793fee9ed5 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/Generated/TableServiceResource.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/src/Generated/TableServiceResource.cs @@ -107,7 +107,7 @@ public virtual TableCollection GetTables() /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -138,7 +138,7 @@ public virtual async Task> GetTableAsync(string tableNam /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -169,7 +169,7 @@ public virtual Response GetTable(string tableName, CancellationTo /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -209,7 +209,7 @@ public virtual async Task> GetAsync(CancellationT /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -249,7 +249,7 @@ public virtual Response Get(CancellationToken cancellation /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource @@ -297,7 +297,7 @@ public virtual async Task> CreateOrUpdateAsyn /// /// /// Default Api Version - /// 2023-05-01 + /// 2024-01-01 /// /// /// Resource diff --git a/sdk/storage/Azure.ResourceManager.Storage/src/autorest.md b/sdk/storage/Azure.ResourceManager.Storage/src/autorest.md index 9c1ca5c5fda9..8edadb38ef48 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/src/autorest.md +++ b/sdk/storage/Azure.ResourceManager.Storage/src/autorest.md @@ -2,365 +2,369 @@ Run `dotnet build /t:GenerateCode` to generate code. -``` yaml +```yaml azure-arm: true csharp: true namespace: Azure.ResourceManager.Storage -require: https://github.com/Azure/azure-rest-api-specs/blob/220ad9c6554fc7d6d10a89bdb441c1e3b36e3285/specification/storage/resource-manager/readme.md -#tag: package-2023-05 +require: https://github.com/Azure/azure-rest-api-specs/blob/982bec06ab5076c1e91935640a09a15857761b66/specification/storage/resource-manager/readme.md +#tag: package-2024-01 output-folder: $(this-folder)/Generated clear-output-folder: true sample-gen: - output-folder: $(this-folder)/../samples/Generated - clear-output-folder: true + output-folder: $(this-folder)/../samples/Generated + clear-output-folder: true skip-csproj: true modelerfour: - flatten-payloads: false - lenient-model-deduplication: true + flatten-payloads: false + lenient-model-deduplication: true use-model-reader-writer: true enable-bicep-serialization: true -#mgmt-debug: +#mgmt-debug: # show-serialized-names: true list-exception: -- /subscriptions/{subscriptionId}/providers/Microsoft.Storage/locations/{location}/deletedAccounts/{deletedAccountName} -- /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/accountMigrations/{migrationName} + - /subscriptions/{subscriptionId}/providers/Microsoft.Storage/locations/{location}/deletedAccounts/{deletedAccountName} + - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/accountMigrations/{migrationName} override-operation-name: - StorageAccounts_CheckNameAvailability: CheckStorageAccountNameAvailability - StorageAccounts_HierarchicalNamespaceMigration: EnableHierarchicalNamespace - BlobContainers_ObjectLevelWorm: EnableVersionLevelImmutability + StorageAccounts_CheckNameAvailability: CheckStorageAccountNameAvailability + StorageAccounts_HierarchicalNamespaceMigration: EnableHierarchicalNamespace + BlobContainers_ObjectLevelWorm: EnableVersionLevelImmutability request-path-to-singleton-resource: - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/managementPolicies/{managementPolicyName}: managementPolicies/default - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/inventoryPolicies/{blobInventoryPolicyName}: inventoryPolicies/default + /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/managementPolicies/{managementPolicyName}: managementPolicies/default + /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/inventoryPolicies/{blobInventoryPolicyName}: inventoryPolicies/default format-by-name-rules: - 'tenantId': 'uuid' - 'ETag': 'etag' - 'location': 'azure-location' - '*Uri': 'Uri' - '*Uris': 'Uri' - '*Guid': 'uuid' - 'ifMatch': 'etag' + "tenantId": "uuid" + "ETag": "etag" + "location": "azure-location" + "*Uri": "Uri" + "*Uris": "Uri" + "*Guid": "uuid" + "ifMatch": "etag" acronym-mapping: - CPU: Cpu - CPUs: Cpus - Os: OS - Ip: IP - Ips: IPs|ips - ID: Id - IDs: Ids - VM: Vm - VMs: Vms - Vmos: VmOS - VMScaleSet: VmScaleSet - DNS: Dns - VPN: Vpn - NAT: Nat - WAN: Wan - Ipv4: IPv4|ipv4 - Ipv6: IPv6|ipv6 - Ipsec: IPsec|ipsec - SSO: Sso - URI: Uri - Etag: ETag|etag - SAS: Sas - SKU: Sku - SMB: Smb - NFS: Nfs - LRS: Lrs - ZRS: Zrs - GRS: Grs - TLS: Tls - AAD: Aad - GET: Get - PUT: Put + CPU: Cpu + CPUs: Cpus + Os: OS + Ip: IP + Ips: IPs|ips + ID: Id + IDs: Ids + VM: Vm + VMs: Vms + Vmos: VmOS + VMScaleSet: VmScaleSet + DNS: Dns + VPN: Vpn + NAT: Nat + WAN: Wan + Ipv4: IPv4|ipv4 + Ipv6: IPv6|ipv6 + Ipsec: IPsec|ipsec + SSO: Sso + URI: Uri + Etag: ETag|etag + SAS: Sas + SKU: Sku + SMB: Smb + NFS: Nfs + LRS: Lrs + ZRS: Zrs + GRS: Grs + TLS: Tls + AAD: Aad + GET: Get + PUT: Put prepend-rp-prefix: -- CorsRules -- CorsRule -- CustomDomain -- DnsEndpointType -- ListKeyExpand -- MinimumTlsVersion -- ProvisioningState -- PermissionScope -- SshPublicKey -- PublicNetworkAccess -- RoutingPreference -- RoutingChoice -- UsageName -- UsageUnit + - CorsRules + - CorsRule + - CustomDomain + - DnsEndpointType + - ListKeyExpand + - MinimumTlsVersion + - ProvisioningState + - PermissionScope + - SshPublicKey + - PublicNetworkAccess + - RoutingPreference + - RoutingChoice + - UsageName + - UsageUnit rename-mapping: - BlobServiceProperties: BlobService - QueueServiceProperties: QueueService - FileServiceProperties: FileService - TableServiceProperties: TableService - StorageAccountCheckNameAvailabilityParameters: StorageAccountNameAvailabilityContent - Multichannel.enabled: IsMultiChannelEnabled - AccessPolicy.expiryTime: expireOn - AccountStatus: StorageAccountStatus - ResourceAccessRule: StorageAccountResourceAccessRule - NetworkRuleSet: StorageAccountNetworkRuleSet - VirtualNetworkRule: StorageAccountVirtualNetworkRule - IPRule: StorageAccountIPRule - Action: StorageAccountNetworkRuleAction - State: StorageAccountNetworkRuleState - Bypass: StorageNetworkBypass - DefaultAction: StorageNetworkDefaultAction - EnabledProtocols: FileShareEnabledProtocol - FileShare.properties.enabledProtocols: enabledProtocol - Encryption: StorageAccountEncryption - EncryptionIdentity: StorageAccountEncryptionIdentity - EncryptionServices: StorageAccountEncryptionServices - EncryptionService: StorageEncryptionService - EncryptionService.enabled: IsEnabled - Endpoints: StorageAccountEndpoints - KeySource: StorageAccountKeySource - KeyType: StorageEncryptionKeyType - KeyPolicy: StorageAccountKeyPolicy - KeyPermission: StorageAccountKeyPermission - KeyCreationTime: StorageAccountKeyCreationTime - KeyVaultProperties: StorageAccountKeyVaultProperties - Format: BlobInventoryPolicyFormat - Schedule: BlobInventoryPolicySchedule - ObjectType: BlobInventoryPolicyObjectType - LastAccessTimeTrackingPolicy.enable: IsEnabled - HttpProtocol: StorageAccountHttpProtocol - Name: LastAccessTimeTrackingPolicyName - LeaseDuration: StorageLeaseDurationType - BlobContainer.properties.leaseDuration: LeaseDuration - FileShare.properties.leaseDuration: LeaseDuration - ManagementPolicyRule.enabled: IsEnabled - RuleType: ManagementPolicyRuleType - Permissions: StorageAccountSasPermission - Services: StorageAccountSasSignedService - AccountSasParameters.signedExpiry: SharedAccessExpireOn - SignedResourceTypes: StorageAccountSasSignedResourceType - SignedResource: ServiceSasSignedResourceType - Reason: StorageAccountNameUnavailableReason - Restriction: StorageSkuRestriction - ReasonCode: StorageRestrictionReasonCode - SKUCapability: StorageSkuCapability - RestorePolicyProperties.enabled: IsEnabled - SasPolicy: StorageAccountSasPolicy - ShareAccessTier: FileShareAccessTier - TagFilter: ManagementPolicyTagFilter - TagFilter.op: Operator - TagProperty: LegalHoldTag - AccessTier: StorageAccountAccessTier - StorageAccountSkuConversionStatus.startTime: StartOn - StorageAccountSkuConversionStatus.endTime: EndOn - SkuConversionStatus: StorageAccountSkuConversionState - PrivateLinkResource: StoragePrivateLinkResourceData - MigrationState: ImmutableStorageWithVersioningMigrationState - AccessPolicy: StorageServiceAccessPolicy - ChangeFeed: BlobServiceChangeFeed - ChangeFeed.enabled: IsEnabled - CheckNameAvailabilityResult: StorageAccountNameAvailabilityResult - CheckNameAvailabilityResult.nameAvailable: IsNameAvailable - BlobContainer.properties.deleted: IsDeleted - BlobServiceProperties.properties.automaticSnapshotPolicyEnabled: IsAutomaticSnapshotPolicyEnabled - FileShare.properties.deleted: IsDeleted - DeleteRetentionPolicy.enabled: IsEnabled - ImmutableStorageAccount.enabled: IsEnabled - ImmutableStorageWithVersioning.enabled: IsEnabled - BlobInventoryPolicyRule.enabled: IsEnabled - BlobInventoryPolicySchema.enabled: IsEnabled - ActiveDirectoryProperties: StorageActiveDirectoryProperties - AccountType: ActiveDirectoryAccountType - StorageAccount.properties.failoverInProgress: IsFailoverInProgress - StorageAccount.properties.isNfsV3Enabled: IsNfsV3Enabled - StorageAccountCreateParameters.properties.isNfsV3Enabled: IsNfsV3Enabled - StorageAccount.properties.defaultToOAuthAuthentication: IsDefaultToOAuthAuthentication - StorageAccountCreateParameters.properties.defaultToOAuthAuthentication: IsDefaultToOAuthAuthentication - StorageAccountUpdateParameters.properties.defaultToOAuthAuthentication: IsDefaultToOAuthAuthentication - CustomDomain.useSubDomainName: IsUseSubDomainNameEnabled - RoutingPreference.publishMicrosoftEndpoints: IsMicrosoftEndpointsPublished - RoutingPreference.publishInternetEndpoints: IsInternetEndpointsPublished - BlobContainer.properties.denyEncryptionScopeOverride: PreventEncryptionScopeOverride - BlobInventoryPolicy.properties.policy: PolicySchema - ProtocolSettings.smb: SmbSetting - LocalUser: StorageAccountLocalUser - ManagementPolicy: StorageAccountManagementPolicy - AzureFilesIdentityBasedAuthentication: FilesIdentityBasedAuthentication - BlobInventoryPolicyFilter.prefixMatch: IncludePrefix - AllowedMethods: CorsRuleAllowedMethod - DefaultSharePermission.StorageFileDataSmbShareReader: Reader - DefaultSharePermission.StorageFileDataSmbShareContributor: Contributor - DefaultSharePermission.StorageFileDataSmbShareElevatedContributor: ElevatedContributor - EncryptionScopeSource.Microsoft.Storage: Storage - EncryptionScopeSource.Microsoft.KeyVault: KeyVault - GeoReplicationStats: GeoReplicationStatistics - InventoryRuleType: BlobInventoryRuleType - LeaseContainerRequestAction: LeaseContainerAction - LeaseState: StorageLeaseState - LeaseStatus: StorageLeaseStatus - ListAccountSasResponse: GetAccountSasResult - ListServiceSasResponse: GetServiceSasResult - ListContainersInclude: BlobContainerState - RestorePolicyProperties: RestorePolicy - AccountImmutabilityPolicyProperties: AccountImmutabilityPolicy - ImmutabilityPolicyProperties: BlobContainerImmutabilityPolicy - SignedResource.b: Blob - SignedResource.c: Container - SignedResource.f: File - SignedResource.s: Share - SignedIdentifier: StorageSignedIdentifier - KeySource.Microsoft.Storage: Storage - KeySource.Microsoft.Keyvault: KeyVault - StorageAccountListKeysResult: StorageAccountGetKeysResult - TableAccessPolicy: StorageTableAccessPolicy - TableAccessPolicy.expiryTime: ExpireOn - TableSignedIdentifier: StorageTableSignedIdentifier - UpdateHistoryProperty: UpdateHistoryEntry - UpdateHistoryProperty.update: UpdateType - PublicAccess: StoragePublicAccessType - Endpoints.blob: BlobUri - Endpoints.queue: QueueUri - Endpoints.table: TableUri - Endpoints.file: FileUri - Endpoints.web: WebUri - Endpoints.dfs: DfsUri - StorageAccountMicrosoftEndpoints.blob: BlobUri - StorageAccountMicrosoftEndpoints.queue: QueueUri - StorageAccountMicrosoftEndpoints.table: TableUri - StorageAccountMicrosoftEndpoints.file: FileUri - StorageAccountMicrosoftEndpoints.web: WebUri - StorageAccountMicrosoftEndpoints.dfs: DfsUri - StorageAccountInternetEndpoints.blob: BlobUri - StorageAccountInternetEndpoints.file: FileUri - StorageAccountInternetEndpoints.web: WebUri - StorageAccountInternetEndpoints.dfs: DfsUri - FailoverType: StorageAccountFailoverType - ListEncryptionScopesInclude: EncryptionScopesIncludeType - StorageAccount.properties.accountMigrationInProgress: IsAccountMigrationInProgress - StorageAccount.properties.enableExtendedGroups: IsExtendedGroupEnabled - StorageAccountCreateParameters.properties.enableExtendedGroups: IsExtendedGroupEnabled - StorageAccountUpdateParameters.properties.enableExtendedGroups: IsExtendedGroupEnabled - LocalUser.properties.allowAclAuthorization: IsAclAuthorizationAllowed - LocalUser.properties.isNFSv3Enabled: IsNfsV3Enabled - StorageAccountMigration.type: ResourceType|resource-type - IntervalUnit: ExecutionIntervalUnit - IssueType: NetworkSecurityPerimeterProvisioningIssueType - MigrationName: StorageAccountMigrationName - MigrationStatus: StorageAccountMigrationStatus - ProvisioningIssue: NetworkSecurityPerimeterProvisioningIssue - ProvisioningIssueProperties: NetworkSecurityPerimeterProvisioningIssueProperties - RunResult: StorageTaskRunResult - RunStatusEnum: StorageTaskRunStatus - Severity: NetworkSecurityPerimeterProvisioningIssueSeverity - StorageTaskAssignmentUpdateProperties: StorageTaskAssignmentPatchProperties - StorageTaskAssignmentUpdateProperties.enabled: IsEnabled - StorageTaskAssignmentProperties.enabled: IsEnabled - StorageTaskReportProperties.startTime: StartedOn|date-time - StorageTaskReportProperties.finishTime: FinishedOn|date-time - TriggerParameters: ExecutionTriggerParameters - TriggerParametersUpdate: ExecutionTriggerParametersUpdate - TriggerType: ExecutionTriggerType + BlobServiceProperties: BlobService + QueueServiceProperties: QueueService + FileServiceProperties: FileService + TableServiceProperties: TableService + StorageAccountCheckNameAvailabilityParameters: StorageAccountNameAvailabilityContent + Multichannel.enabled: IsMultiChannelEnabled + AccessPolicy.expiryTime: expireOn + AccountStatus: StorageAccountStatus + ResourceAccessRule: StorageAccountResourceAccessRule + NetworkRuleSet: StorageAccountNetworkRuleSet + VirtualNetworkRule: StorageAccountVirtualNetworkRule + IPRule: StorageAccountIPRule + Action: StorageAccountNetworkRuleAction + State: StorageAccountNetworkRuleState + Bypass: StorageNetworkBypass + DefaultAction: StorageNetworkDefaultAction + EnabledProtocols: FileShareEnabledProtocol + FileShare.properties.enabledProtocols: enabledProtocol + Encryption: StorageAccountEncryption + EncryptionIdentity: StorageAccountEncryptionIdentity + EncryptionServices: StorageAccountEncryptionServices + EncryptionService: StorageEncryptionService + EncryptionService.enabled: IsEnabled + Endpoints: StorageAccountEndpoints + KeySource: StorageAccountKeySource + KeyType: StorageEncryptionKeyType + KeyPolicy: StorageAccountKeyPolicy + KeyPermission: StorageAccountKeyPermission + KeyCreationTime: StorageAccountKeyCreationTime + KeyVaultProperties: StorageAccountKeyVaultProperties + Format: BlobInventoryPolicyFormat + Schedule: BlobInventoryPolicySchedule + ObjectType: BlobInventoryPolicyObjectType + LastAccessTimeTrackingPolicy.enable: IsEnabled + HttpProtocol: StorageAccountHttpProtocol + Name: LastAccessTimeTrackingPolicyName + LeaseDuration: StorageLeaseDurationType + BlobContainer.properties.leaseDuration: LeaseDuration + FileShare.properties.leaseDuration: LeaseDuration + ManagementPolicyRule.enabled: IsEnabled + RuleType: ManagementPolicyRuleType + Permissions: StorageAccountSasPermission + Services: StorageAccountSasSignedService + AccountSasParameters.signedExpiry: SharedAccessExpireOn + SignedResourceTypes: StorageAccountSasSignedResourceType + SignedResource: ServiceSasSignedResourceType + Reason: StorageAccountNameUnavailableReason + Restriction: StorageSkuRestriction + ReasonCode: StorageRestrictionReasonCode + SKUCapability: StorageSkuCapability + RestorePolicyProperties.enabled: IsEnabled + SasPolicy: StorageAccountSasPolicy + ShareAccessTier: FileShareAccessTier + TagFilter: ManagementPolicyTagFilter + TagFilter.op: Operator + TagProperty: LegalHoldTag + AccessTier: StorageAccountAccessTier + StorageAccountSkuConversionStatus.startTime: StartOn + StorageAccountSkuConversionStatus.endTime: EndOn + SkuConversionStatus: StorageAccountSkuConversionState + PrivateLinkResource: StoragePrivateLinkResourceData + MigrationState: ImmutableStorageWithVersioningMigrationState + AccessPolicy: StorageServiceAccessPolicy + ChangeFeed: BlobServiceChangeFeed + ChangeFeed.enabled: IsEnabled + CheckNameAvailabilityResult: StorageAccountNameAvailabilityResult + CheckNameAvailabilityResult.nameAvailable: IsNameAvailable + BlobContainer.properties.deleted: IsDeleted + BlobServiceProperties.properties.automaticSnapshotPolicyEnabled: IsAutomaticSnapshotPolicyEnabled + FileShare.properties.deleted: IsDeleted + DeleteRetentionPolicy.enabled: IsEnabled + ImmutableStorageAccount.enabled: IsEnabled + ImmutableStorageWithVersioning.enabled: IsEnabled + BlobInventoryPolicyRule.enabled: IsEnabled + BlobInventoryPolicySchema.enabled: IsEnabled + ActiveDirectoryProperties: StorageActiveDirectoryProperties + AccountType: ActiveDirectoryAccountType + StorageAccount.properties.failoverInProgress: IsFailoverInProgress + StorageAccount.properties.isNfsV3Enabled: IsNfsV3Enabled + StorageAccountCreateParameters.properties.isNfsV3Enabled: IsNfsV3Enabled + StorageAccount.properties.defaultToOAuthAuthentication: IsDefaultToOAuthAuthentication + StorageAccountCreateParameters.properties.defaultToOAuthAuthentication: IsDefaultToOAuthAuthentication + StorageAccountUpdateParameters.properties.defaultToOAuthAuthentication: IsDefaultToOAuthAuthentication + CustomDomain.useSubDomainName: IsUseSubDomainNameEnabled + RoutingPreference.publishMicrosoftEndpoints: IsMicrosoftEndpointsPublished + RoutingPreference.publishInternetEndpoints: IsInternetEndpointsPublished + BlobContainer.properties.denyEncryptionScopeOverride: PreventEncryptionScopeOverride + BlobInventoryPolicy.properties.policy: PolicySchema + ProtocolSettings.smb: SmbSetting + LocalUser: StorageAccountLocalUser + ManagementPolicy: StorageAccountManagementPolicy + AzureFilesIdentityBasedAuthentication: FilesIdentityBasedAuthentication + BlobInventoryPolicyFilter.prefixMatch: IncludePrefix + AllowedMethods: CorsRuleAllowedMethod + DefaultSharePermission.StorageFileDataSmbShareReader: Reader + DefaultSharePermission.StorageFileDataSmbShareContributor: Contributor + DefaultSharePermission.StorageFileDataSmbShareElevatedContributor: ElevatedContributor + EncryptionScopeSource.Microsoft.Storage: Storage + EncryptionScopeSource.Microsoft.KeyVault: KeyVault + GeoReplicationStats: GeoReplicationStatistics + InventoryRuleType: BlobInventoryRuleType + LeaseContainerRequestAction: LeaseContainerAction + LeaseState: StorageLeaseState + LeaseStatus: StorageLeaseStatus + ListAccountSasResponse: GetAccountSasResult + ListServiceSasResponse: GetServiceSasResult + ListContainersInclude: BlobContainerState + RestorePolicyProperties: RestorePolicy + AccountImmutabilityPolicyProperties: AccountImmutabilityPolicy + ImmutabilityPolicyProperties: BlobContainerImmutabilityPolicy + SignedResource.b: Blob + SignedResource.c: Container + SignedResource.f: File + SignedResource.s: Share + SignedIdentifier: StorageSignedIdentifier + KeySource.Microsoft.Storage: Storage + KeySource.Microsoft.Keyvault: KeyVault + StorageAccountListKeysResult: StorageAccountGetKeysResult + TableAccessPolicy: StorageTableAccessPolicy + TableAccessPolicy.expiryTime: ExpireOn + TableSignedIdentifier: StorageTableSignedIdentifier + UpdateHistoryProperty: UpdateHistoryEntry + UpdateHistoryProperty.update: UpdateType + PublicAccess: StoragePublicAccessType + Endpoints.blob: BlobUri + Endpoints.queue: QueueUri + Endpoints.table: TableUri + Endpoints.file: FileUri + Endpoints.web: WebUri + Endpoints.dfs: DfsUri + StorageAccountMicrosoftEndpoints.blob: BlobUri + StorageAccountMicrosoftEndpoints.queue: QueueUri + StorageAccountMicrosoftEndpoints.table: TableUri + StorageAccountMicrosoftEndpoints.file: FileUri + StorageAccountMicrosoftEndpoints.web: WebUri + StorageAccountMicrosoftEndpoints.dfs: DfsUri + StorageAccountInternetEndpoints.blob: BlobUri + StorageAccountInternetEndpoints.file: FileUri + StorageAccountInternetEndpoints.web: WebUri + StorageAccountInternetEndpoints.dfs: DfsUri + FailoverType: StorageAccountFailoverType + ListEncryptionScopesInclude: EncryptionScopesIncludeType + StorageAccount.properties.accountMigrationInProgress: IsAccountMigrationInProgress + StorageAccount.properties.enableExtendedGroups: IsExtendedGroupEnabled + StorageAccountCreateParameters.properties.enableExtendedGroups: IsExtendedGroupEnabled + StorageAccountUpdateParameters.properties.enableExtendedGroups: IsExtendedGroupEnabled + LocalUser.properties.allowAclAuthorization: IsAclAuthorizationAllowed + LocalUser.properties.isNFSv3Enabled: IsNfsV3Enabled + StorageAccountMigration.type: ResourceType|resource-type + IntervalUnit: ExecutionIntervalUnit + IssueType: NetworkSecurityPerimeterProvisioningIssueType + MigrationName: StorageAccountMigrationName + MigrationStatus: StorageAccountMigrationStatus + ProvisioningIssue: NetworkSecurityPerimeterProvisioningIssue + ProvisioningIssueProperties: NetworkSecurityPerimeterProvisioningIssueProperties + RunResult: StorageTaskRunResult + RunStatusEnum: StorageTaskRunStatus + Severity: NetworkSecurityPerimeterProvisioningIssueSeverity + StorageTaskAssignmentUpdateProperties: StorageTaskAssignmentPatchProperties + StorageTaskAssignmentUpdateProperties.enabled: IsEnabled + StorageTaskAssignmentProperties.enabled: IsEnabled + StorageTaskReportProperties.startTime: StartedOn|date-time + StorageTaskReportProperties.finishTime: FinishedOn|date-time + TriggerParameters: ExecutionTriggerParameters + TriggerParametersUpdate: ExecutionTriggerParametersUpdate + TriggerType: ExecutionTriggerType + ObjectReplicationPolicyPropertiesMetrics.enabled: IsMetricsEnabled + AccountLimits: FileServiceAccountLimits + AccountUsage: FileServiceAccountUsage + AccountUsageElements: FileServiceAccountUsageElements directive: - - from: swagger-document - where: $.definitions.FileShareItems.properties.value.items["$ref"] - transform: return "#/definitions/FileShare" - - from: swagger-document - where: $.definitions.ListContainerItems.properties.value.items["$ref"] - transform: return "#/definitions/BlobContainer" - - from: swagger-document - where: $.definitions.ListQueueResource.properties.value.items["$ref"] - transform: return "#/definitions/StorageQueue" - - from: swagger-document - where: $.definitions.BlobRestoreParameters - transform: > - $.required = ["timetoRestore", "blobRanges"]; - for (var key in $.properties) { - var property = $.properties[key]; - delete $.properties[key]; - if (key === 'timeToRestore') { - $.properties['timetoRestore'] = property; - $.properties['timetoRestore']['x-ms-client-name'] = 'timeToRestore'; + - from: swagger-document + where: $.definitions.FileShareItems.properties.value.items["$ref"] + transform: return "#/definitions/FileShare" + - from: swagger-document + where: $.definitions.ListContainerItems.properties.value.items["$ref"] + transform: return "#/definitions/BlobContainer" + - from: swagger-document + where: $.definitions.ListQueueResource.properties.value.items["$ref"] + transform: return "#/definitions/StorageQueue" + - from: swagger-document + where: $.definitions.BlobRestoreParameters + transform: > + $.required = ["timetoRestore", "blobRanges"]; + for (var key in $.properties) { + var property = $.properties[key]; + delete $.properties[key]; + if (key === 'timeToRestore') { + $.properties['timetoRestore'] = property; + $.properties['timetoRestore']['x-ms-client-name'] = 'timeToRestore'; + } + else{ + $.properties[key] = property; + } } - else{ - $.properties[key] = property; - } - } - # assigning formats - - from: swagger-document - where: $.definitions.StorageAccountCheckNameAvailabilityParameters.properties.type - transform: $["x-ms-format"] = "resource-type"; - - from: swagger-document - where: $.definitions.DeletedAccountProperties.properties.storageAccountResourceId - transform: $["x-ms-format"] = "arm-id"; - - from: swagger-document - where: $.definitions.DeletedAccountProperties.properties.creationTime - transform: $["format"] = "date-time"; - - from: swagger-document - where: $.definitions.DeletedAccountProperties.properties.deletionTime - transform: $["format"] = "date-time"; - - from: swagger-document - where: $.definitions.StorageAccountProperties.properties.primaryLocation - transform: $["x-ms-format"] = "azure-location"; - - from: swagger-document - where: $.definitions.StorageAccountProperties.properties.secondaryLocation - transform: $["x-ms-format"] = "azure-location"; - - from: swagger-document - where: $.definitions.StorageAccountSkuConversionStatus.properties.startTime - transform: $["format"] = "date-time"; - - from: swagger-document - where: $.definitions.StorageAccountSkuConversionStatus.properties.endTime - transform: $["format"] = "date-time"; - - from: swagger-document - where: $.definitions.PrivateLinkResourceProperties.properties.groupId - transform: $["x-ms-format"] = "arm-id"; - - from: swagger-document - where: $.definitions.ResourceAccessRule.properties.resourceId - transform: $["x-ms-format"] = "arm-id"; - - from: swagger-document - where: $.definitions.VirtualNetworkRule.properties.id - transform: $["x-ms-format"] = "arm-id"; - - from: swagger-document - where: $.definitions.Encryption - transform: $.required = undefined; # this is a fix for swagger issue, and it should be resolved in azure-rest-api-specs/pull/19357 -# this is a temporary fix - - from: swagger-document - where: $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/tableServices/default/tables/{tableName}"].put.parameters - transform: $[2].required = true -# convenience change: expand the array result out - - from: swagger-document - where: $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/listKeys"].post - transform: > - $["x-ms-pageable"] = { - "itemName": "keys", - "nextLinkName": null - }; - - from: swagger-document - where: $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/regenerateKey"].post - transform: > - $["x-ms-pageable"] = { - "itemName": "keys", - "nextLinkName": null - }; - - from: swagger-document - where: $.definitions.StorageAccountCheckNameAvailabilityParameters.properties.type - transform: $["x-ms-constant"] = true; -# maxpagesize should be int - - from: blob.json - where: $.paths..parameters[?(@.name === "$maxpagesize")] - transform: > - $['type'] = "integer"; - $['format'] = "int32"; - - from: file.json - where: $.paths..parameters[?(@.name === "$maxpagesize")] - transform: > - $['type'] = "integer"; - $['format'] = "int32"; - - from: queue.json - where: $.paths..parameters[?(@.name === "$maxpagesize")] - transform: > - $['type'] = "integer"; - $['format'] = "int32"; + # assigning formats + - from: swagger-document + where: $.definitions.StorageAccountCheckNameAvailabilityParameters.properties.type + transform: $["x-ms-format"] = "resource-type"; + - from: swagger-document + where: $.definitions.DeletedAccountProperties.properties.storageAccountResourceId + transform: $["x-ms-format"] = "arm-id"; + - from: swagger-document + where: $.definitions.DeletedAccountProperties.properties.creationTime + transform: $["format"] = "date-time"; + - from: swagger-document + where: $.definitions.DeletedAccountProperties.properties.deletionTime + transform: $["format"] = "date-time"; + - from: swagger-document + where: $.definitions.StorageAccountProperties.properties.primaryLocation + transform: $["x-ms-format"] = "azure-location"; + - from: swagger-document + where: $.definitions.StorageAccountProperties.properties.secondaryLocation + transform: $["x-ms-format"] = "azure-location"; + - from: swagger-document + where: $.definitions.StorageAccountSkuConversionStatus.properties.startTime + transform: $["format"] = "date-time"; + - from: swagger-document + where: $.definitions.StorageAccountSkuConversionStatus.properties.endTime + transform: $["format"] = "date-time"; + - from: swagger-document + where: $.definitions.PrivateLinkResourceProperties.properties.groupId + transform: $["x-ms-format"] = "arm-id"; + - from: swagger-document + where: $.definitions.ResourceAccessRule.properties.resourceId + transform: $["x-ms-format"] = "arm-id"; + - from: swagger-document + where: $.definitions.VirtualNetworkRule.properties.id + transform: $["x-ms-format"] = "arm-id"; + - from: swagger-document + where: $.definitions.Encryption + transform: $.required = undefined; # this is a fix for swagger issue, and it should be resolved in azure-rest-api-specs/pull/19357 + # this is a temporary fix + - from: swagger-document + where: $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/tableServices/default/tables/{tableName}"].put.parameters + transform: $[2].required = true + # convenience change: expand the array result out + - from: swagger-document + where: $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/listKeys"].post + transform: > + $["x-ms-pageable"] = { + "itemName": "keys", + "nextLinkName": null + }; + - from: swagger-document + where: $.paths["/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/regenerateKey"].post + transform: > + $["x-ms-pageable"] = { + "itemName": "keys", + "nextLinkName": null + }; + - from: swagger-document + where: $.definitions.StorageAccountCheckNameAvailabilityParameters.properties.type + transform: $["x-ms-constant"] = true; + # maxpagesize should be int + - from: blob.json + where: $.paths..parameters[?(@.name === "$maxpagesize")] + transform: > + $['type'] = "integer"; + $['format'] = "int32"; + - from: file.json + where: $.paths..parameters[?(@.name === "$maxpagesize")] + transform: > + $['type'] = "integer"; + $['format'] = "int32"; + - from: queue.json + where: $.paths..parameters[?(@.name === "$maxpagesize")] + transform: > + $['type'] = "integer"; + $['format'] = "int32"; ``` diff --git a/sdk/storage/Azure.ResourceManager.Storage/tests/Tests/BlobContainerTests.cs b/sdk/storage/Azure.ResourceManager.Storage/tests/Tests/BlobContainerTests.cs index 3e768d9e3aec..583747eac06f 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/tests/Tests/BlobContainerTests.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/tests/Tests/BlobContainerTests.cs @@ -510,6 +510,7 @@ public async Task CreateGetDeleteObjectReplicationPolicy() { SourceAccount = sourceAccount.Id.Name, DestinationAccount = destAccount.Id.Name, + IsMetricsEnabled = true, Rules = { new ObjectReplicationPolicyRule(containerName1, containerName2) @@ -526,6 +527,7 @@ public async Task CreateGetDeleteObjectReplicationPolicy() Assert.NotNull(objectReplicationPolicy); Assert.AreEqual(objectReplicationPolicy.Data.DestinationAccount, destAccount.Id.Name); Assert.AreEqual(objectReplicationPolicy.Data.SourceAccount, sourceAccount.Id.Name); + Assert.AreEqual(objectReplicationPolicy.Data.IsMetricsEnabled, true); //get policy List policies = await objectReplicationPolicyCollection.GetAllAsync().ToEnumerableAsync(); @@ -533,6 +535,7 @@ public async Task CreateGetDeleteObjectReplicationPolicy() Assert.NotNull(objectReplicationPolicy); Assert.AreEqual(objectReplicationPolicy.Data.DestinationAccount, destAccount.Id.Name); Assert.AreEqual(objectReplicationPolicy.Data.SourceAccount, sourceAccount.Id.Name); + Assert.AreEqual(objectReplicationPolicy.Data.IsMetricsEnabled, true); //delete policy await objectReplicationPolicy.DeleteAsync(WaitUntil.Completed); diff --git a/sdk/storage/Azure.ResourceManager.Storage/tests/Tests/FileShareTests.cs b/sdk/storage/Azure.ResourceManager.Storage/tests/Tests/FileShareTests.cs index 91f7fb8346c4..94dbcb7ef958 100644 --- a/sdk/storage/Azure.ResourceManager.Storage/tests/Tests/FileShareTests.cs +++ b/sdk/storage/Azure.ResourceManager.Storage/tests/Tests/FileShareTests.cs @@ -487,5 +487,161 @@ public async Task FileServiceCors() Assert.AreEqual(putRule.MaxAgeInSeconds, getRule.MaxAgeInSeconds); } } + + [Test] + [RecordedTest] + public async Task ProvisionV2FileStorageAccount() + { + // Create PV2 account + string accountName = await CreateValidAccountNameAsync("teststoragemgmtpv2"); + StorageAccountCollection storageAccountCollection = _resourceGroup.GetStorageAccounts(); + _storageAccount = (await storageAccountCollection.CreateOrUpdateAsync(WaitUntil.Completed, + accountName, + GetDefaultStorageAccountParameters( + sku: new StorageSku(StorageSkuName.StandardV2Lrs), + StorageKind.FileStorage, + AzureLocation.WestUS2))) + //"eastus2euap"))) + .Value; + _fileService = _storageAccount.GetFileService(); + _fileService = await _fileService.GetAsync(); + _fileShareCollection = _fileService.GetFileShares(); + + // Get share usage + var usage = (_fileService.GetFileServiceUsage()).GetAsync().Result.Value.Data; + Assert.IsNotNull(usage.Properties.FileShareLimits); + Assert.IsTrue(usage.Properties.FileShareLimits.MaxProvisionedBandwidthMiBPerSec.Value > 0); + Assert.IsTrue(usage.Properties.FileShareLimits.MaxProvisionedIops.Value > 0); + Assert.IsTrue(usage.Properties.FileShareLimits.MaxProvisionedStorageGiB.Value > 0); + Assert.IsTrue(usage.Properties.FileShareLimits.MinProvisionedBandwidthMiBPerSec.Value > 0); + Assert.IsTrue(usage.Properties.FileShareLimits.MinProvisionedIops.Value > 0); + Assert.IsTrue(usage.Properties.FileShareLimits.MinProvisionedStorageGiB.Value > 0); + Assert.IsNotNull(usage.Properties.BurstingConstants); + Assert.IsTrue(usage.Properties.FileShareRecommendations.BandwidthScalar.Value > 0); + Assert.IsTrue(usage.Properties.FileShareRecommendations.BaseBandwidthMiBPerSec.Value > 0); + Assert.IsTrue(usage.Properties.FileShareRecommendations.BaseIops.Value > 0); + Assert.IsTrue(usage.Properties.FileShareRecommendations.IoScalar.Value > 0); + Assert.IsTrue(usage.Properties.StorageAccountLimits.MaxFileShares.Value > 0); + Assert.IsTrue(usage.Properties.StorageAccountLimits.MaxProvisionedBandwidthMiBPerSec.Value > 0); + Assert.IsTrue(usage.Properties.StorageAccountLimits.MaxProvisionedIops.Value > 0); + Assert.IsTrue(usage.Properties.StorageAccountLimits.MaxProvisionedStorageGiB.Value > 0); + Assert.IsNotNull(usage.Properties.StorageAccountUsage); + + //create file share + string fileShareName = Recording.GenerateAssetName("testfileshare"); + var data = new FileShareData() + { + ProvisionedBandwidthMibps = usage.Properties.FileShareLimits.MaxProvisionedBandwidthMiBPerSec.Value - 1, + ProvisionedIops = usage.Properties.FileShareLimits.MaxProvisionedIops.Value - 1, + ShareQuota = usage.Properties.FileShareLimits.MaxProvisionedStorageGiB.Value - 1 + }; + FileShareResource share1 = (await _fileShareCollection.CreateOrUpdateAsync(WaitUntil.Completed, fileShareName, data)).Value; + Assert.AreEqual(share1.Id.Name, fileShareName); + Assert.AreEqual(data.ProvisionedBandwidthMibps, share1.Data.ProvisionedBandwidthMibps); + Assert.AreEqual(data.ProvisionedIops, share1.Data.ProvisionedIops); + Assert.AreEqual(data.ShareQuota, share1.Data.ShareQuota); + + //validate if created successfully + FileShareResource share2 = await _fileShareCollection.GetAsync(fileShareName); + Assert.AreEqual(share1.Data.ProvisionedBandwidthMibps, share2.Data.ProvisionedBandwidthMibps); + Assert.AreEqual(share1.Data.ProvisionedIops, share2.Data.ProvisionedIops); + Assert.AreEqual(share1.Data.ShareQuota, share2.Data.ShareQuota); + + // Update File share + data.ProvisionedBandwidthMibps = usage.Properties.FileShareLimits.MinProvisionedBandwidthMiBPerSec.Value + 1; + data.ProvisionedIops = usage.Properties.FileShareLimits.MinProvisionedIops.Value + 1; + data.ShareQuota = usage.Properties.FileShareLimits.MinProvisionedStorageGiB.Value + 1; + + share1 = (await _fileShareCollection.CreateOrUpdateAsync(WaitUntil.Completed, fileShareName, data)).Value; + Assert.AreEqual(share1.Id.Name, fileShareName); + Assert.AreEqual(data.ProvisionedBandwidthMibps, share1.Data.ProvisionedBandwidthMibps); + Assert.AreEqual(data.ProvisionedIops, share1.Data.ProvisionedIops); + Assert.AreEqual(data.ShareQuota, share1.Data.ShareQuota); + + share2 = (await _fileShareCollection.GetAsync(fileShareName)).Value; + Assert.AreEqual(share1.Data.ProvisionedBandwidthMibps, share2.Data.ProvisionedBandwidthMibps); + Assert.AreEqual(share1.Data.ProvisionedIops, share2.Data.ProvisionedIops); + Assert.AreEqual(share1.Data.ShareQuota, share2.Data.ShareQuota); + + //delete file share + await share1.DeleteAsync(WaitUntil.Completed); + + //validate if deleted successfully + var exception = Assert.ThrowsAsync(async () => { await _fileShareCollection.GetAsync(fileShareName); }); + Assert.AreEqual(404, exception.Status); + Assert.IsFalse(await _fileShareCollection.ExistsAsync(fileShareName)); + } + + [Test] + [RecordedTest] + public async Task PaidBursting() + { + // Create account + string accountName = Recording.GenerateAssetName("account"); + var content = new StorageAccountCreateOrUpdateContent(new StorageSku(StorageSkuName.PremiumLrs), StorageKind.FileStorage, "eastus2euap"); + var account = (await _resourceGroup.GetStorageAccounts().CreateOrUpdateAsync(WaitUntil.Completed, accountName, content)).Value; + + //create file share + _fileShareCollection = (await account.GetFileService().GetAsync()).Value.GetFileShares(); + string fileShareName = Recording.GenerateAssetName("testfileshare"); + var data = new FileShareData(); + data.FileSharePaidBursting = new FileSharePropertiesFileSharePaidBursting() + { + PaidBurstingEnabled = true, + PaidBurstingMaxBandwidthMibps = 129, + PaidBurstingMaxIops = 3230 + }; + FileShareResource share1 = (await _fileShareCollection.CreateOrUpdateAsync(WaitUntil.Completed, fileShareName, data)).Value; + Assert.AreEqual(share1.Id.Name, fileShareName); + Assert.AreEqual(data.FileSharePaidBursting.PaidBurstingEnabled, share1.Data.FileSharePaidBursting.PaidBurstingEnabled); + Assert.AreEqual(data.FileSharePaidBursting.PaidBurstingMaxBandwidthMibps, share1.Data.FileSharePaidBursting.PaidBurstingMaxBandwidthMibps); + Assert.AreEqual(data.FileSharePaidBursting.PaidBurstingMaxIops, share1.Data.FileSharePaidBursting.PaidBurstingMaxIops); + + //validate if created successfully + FileShareResource share2 = await _fileShareCollection.GetAsync(fileShareName); + AssertFileShareEqual(share1, share2); + Assert.AreEqual(data.FileSharePaidBursting.PaidBurstingEnabled, share2.Data.FileSharePaidBursting.PaidBurstingEnabled); + Assert.AreEqual(data.FileSharePaidBursting.PaidBurstingMaxBandwidthMibps, share2.Data.FileSharePaidBursting.PaidBurstingMaxBandwidthMibps); + Assert.AreEqual(data.FileSharePaidBursting.PaidBurstingMaxIops, share2.Data.FileSharePaidBursting.PaidBurstingMaxIops); + + // update file share - disable PaidBursting + data = new FileShareData(); + data.FileSharePaidBursting = new FileSharePropertiesFileSharePaidBursting() + { + PaidBurstingEnabled = false + }; + share1 = (await share1.UpdateAsync(data)).Value; + Assert.AreEqual(data.FileSharePaidBursting.PaidBurstingEnabled, share1.Data.FileSharePaidBursting.PaidBurstingEnabled); + + share2 = (await _fileShareCollection.GetAsync(fileShareName)).Value; + Assert.AreEqual(data.FileSharePaidBursting.PaidBurstingEnabled, share2.Data.FileSharePaidBursting.PaidBurstingEnabled); + + // update file share - enable PaidBursting + data.FileSharePaidBursting = new FileSharePropertiesFileSharePaidBursting() + { + PaidBurstingEnabled = true, + PaidBurstingMaxBandwidthMibps = 128, + PaidBurstingMaxIops = 3229 + }; + share1 = (await share1.UpdateAsync(data)).Value; + Assert.AreEqual(share1.Id.Name, fileShareName); + Assert.AreEqual(data.FileSharePaidBursting.PaidBurstingEnabled, share1.Data.FileSharePaidBursting.PaidBurstingEnabled); + Assert.AreEqual(data.FileSharePaidBursting.PaidBurstingMaxBandwidthMibps, share1.Data.FileSharePaidBursting.PaidBurstingMaxBandwidthMibps); + Assert.AreEqual(data.FileSharePaidBursting.PaidBurstingMaxIops, share1.Data.FileSharePaidBursting.PaidBurstingMaxIops); + + share2 = await _fileShareCollection.GetAsync(fileShareName); + AssertFileShareEqual(share1, share2); + Assert.AreEqual(data.FileSharePaidBursting.PaidBurstingEnabled, share2.Data.FileSharePaidBursting.PaidBurstingEnabled); + Assert.AreEqual(data.FileSharePaidBursting.PaidBurstingMaxBandwidthMibps, share2.Data.FileSharePaidBursting.PaidBurstingMaxBandwidthMibps); + Assert.AreEqual(data.FileSharePaidBursting.PaidBurstingMaxIops, share2.Data.FileSharePaidBursting.PaidBurstingMaxIops); + + //delete file share + await share1.DeleteAsync(WaitUntil.Completed); + + //validate if deleted successfully + var exception = Assert.ThrowsAsync(async () => { await _fileShareCollection.GetAsync(fileShareName); }); + Assert.AreEqual(404, exception.Status); + Assert.IsFalse(await _fileShareCollection.ExistsAsync(fileShareName)); + } } }