From 14985d4467b5ac52fee898eeab6f418760b9c7a0 Mon Sep 17 00:00:00 2001 From: stankovski Date: Mon, 27 Jul 2015 14:10:04 -0700 Subject: [PATCH 1/2] Fixed NuGet.Config files and updated ResourceManagement swagger files --- src/Authentication/NuGet.Config | 8 +- .../NuGet.Config | 8 +- src/Common/NuGet.Config | 8 +- src/Gallery/NuGet.Config | 8 +- src/KeyVault/NuGet.Config | 8 +- src/ResourceManagement/ApiApp/NuGet.Config | 8 +- .../ApiManagement/NuGet.Config | 8 +- .../Authorization/NuGet.Config | 8 +- .../Automation/NuGet.Config | 8 +- src/ResourceManagement/Batch/NuGet.Config | 8 +- src/ResourceManagement/Commerce/NuGet.Config | 8 +- src/ResourceManagement/Compute/NuGet.Config | 8 +- .../DataFactory/NuGet.Config | 8 +- src/ResourceManagement/Dns/NuGet.Config | 8 +- src/ResourceManagement/Insights/NuGet.Config | 8 +- .../KeyVaultManagement/NuGet.Config | 8 +- src/ResourceManagement/Network/NuGet.Config | 8 +- .../OperationalInsights/NuGet.Config | 8 +- .../RedisCache/NuGet.Config | 8 +- src/ResourceManagement/Resource/NuGet.Config | 8 +- .../AuthorizationClient.json | 69 ++++++------ .../ResourceManagement/FeatureClient.json | 2 +- .../Generated/IManagementLocksOperations.cs | 24 ++-- .../Generated/IResourceGroupsOperations.cs | 27 ++++- .../Generated/IResourcesOperations.cs | 30 +++++ .../Generated/ManagementLocksOperations.cs | 104 +++++++++--------- .../ManagementLocksOperationsExtensions.cs | 72 ++++++------ ...agementLockObject.cs => ManagementLock.cs} | 14 +-- .../Generated/Models/ResourceGroup.cs | 29 +++-- .../Generated/Models/ResourceGroupExtended.cs | 54 --------- ...tendedFilter.cs => ResourceGroupFilter.cs} | 2 +- ...operties.cs => ResourceGroupProperties.cs} | 6 +- .../Generated/ResourceGroupsOperations.cs | 64 +++++++---- .../ResourceGroupsOperationsExtensions.cs | 70 +++++++++--- ...ourceProviderOperationDetailsOperations.cs | 6 +- .../Generated/ResourcesOperations.cs | 53 +++++++-- .../ResourcesOperationsExtensions.cs | 66 +++++++++++ .../Generated/TagsOperations.cs | 16 +-- .../ResourceManagementClient.json | 100 +++++++---------- .../ResourceManagementClientOData.json | 21 ---- .../SubscriptionClient.json | 2 +- .../InMemoryTests/ResourceTests.InMemory.cs | 12 +- src/ResourceManagement/Sql/NuGet.Config | 8 +- src/ResourceManagement/Storage/NuGet.Config | 8 +- .../StreamAnalytics/NuGet.Config | 8 +- .../TrafficManager/NuGet.Config | 8 +- src/ResourceManagement/WebSite/NuGet.Config | 8 +- src/Search/NuGet.Config | 8 +- src/ServiceManagement/Automation/NuGet.Config | 8 +- src/ServiceManagement/Compute/NuGet.Config | 8 +- .../ExpressRoute/NuGet.Config | 8 +- src/ServiceManagement/Management/NuGet.Config | 8 +- .../MediaServices/NuGet.Config | 8 +- src/ServiceManagement/Monitoring/NuGet.Config | 8 +- src/ServiceManagement/Network/NuGet.Config | 8 +- src/ServiceManagement/RemoteApp/NuGet.Config | 8 +- src/ServiceManagement/Scheduler/NuGet.Config | 8 +- src/ServiceManagement/ServiceBus/NuGet.Config | 8 +- .../SiteRecovery/NuGet.Config | 8 +- src/ServiceManagement/Sql/NuGet.Config | 8 +- src/ServiceManagement/StorSimple/NuGet.Config | 8 +- src/ServiceManagement/Storage/NuGet.Config | 8 +- src/ServiceManagement/Store/NuGet.Config | 8 +- .../TrafficManager/NuGet.Config | 8 +- src/ServiceManagement/WebSite/NuGet.Config | 8 +- 65 files changed, 703 insertions(+), 484 deletions(-) rename src/ResourceManagement/Resource/ResourceManagement/Generated/Models/{ManagementLockObject.cs => ManagementLock.cs} (72%) delete mode 100644 src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupExtended.cs rename src/ResourceManagement/Resource/ResourceManagement/Generated/Models/{ResourceGroupExtendedFilter.cs => ResourceGroupFilter.cs} (92%) rename src/ResourceManagement/Resource/ResourceManagement/Generated/Models/{ResourceGroupFormatResourceProperties.cs => ResourceGroupProperties.cs} (70%) delete mode 100644 src/ResourceManagement/Resource/ResourceManagement/ResourceManagementClientOData.json diff --git a/src/Authentication/NuGet.Config b/src/Authentication/NuGet.Config index edafa204a2dd..2de911013532 100644 --- a/src/Authentication/NuGet.Config +++ b/src/Authentication/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\packages - + + + + + diff --git a/src/ClientRuntime.Azure.TestFramework/NuGet.Config b/src/ClientRuntime.Azure.TestFramework/NuGet.Config index edafa204a2dd..2de911013532 100644 --- a/src/ClientRuntime.Azure.TestFramework/NuGet.Config +++ b/src/ClientRuntime.Azure.TestFramework/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\packages - + + + + + diff --git a/src/Common/NuGet.Config b/src/Common/NuGet.Config index edafa204a2dd..2de911013532 100644 --- a/src/Common/NuGet.Config +++ b/src/Common/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\packages - + + + + + diff --git a/src/Gallery/NuGet.Config b/src/Gallery/NuGet.Config index edafa204a2dd..2de911013532 100644 --- a/src/Gallery/NuGet.Config +++ b/src/Gallery/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\packages - + + + + + diff --git a/src/KeyVault/NuGet.Config b/src/KeyVault/NuGet.Config index edafa204a2dd..2de911013532 100644 --- a/src/KeyVault/NuGet.Config +++ b/src/KeyVault/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\packages - + + + + + diff --git a/src/ResourceManagement/ApiApp/NuGet.Config b/src/ResourceManagement/ApiApp/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/ApiApp/NuGet.Config +++ b/src/ResourceManagement/ApiApp/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/ApiManagement/NuGet.Config b/src/ResourceManagement/ApiManagement/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/ApiManagement/NuGet.Config +++ b/src/ResourceManagement/ApiManagement/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/Authorization/NuGet.Config b/src/ResourceManagement/Authorization/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/Authorization/NuGet.Config +++ b/src/ResourceManagement/Authorization/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/Automation/NuGet.Config b/src/ResourceManagement/Automation/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/Automation/NuGet.Config +++ b/src/ResourceManagement/Automation/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/Batch/NuGet.Config b/src/ResourceManagement/Batch/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/Batch/NuGet.Config +++ b/src/ResourceManagement/Batch/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/Commerce/NuGet.Config b/src/ResourceManagement/Commerce/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/Commerce/NuGet.Config +++ b/src/ResourceManagement/Commerce/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/Compute/NuGet.Config b/src/ResourceManagement/Compute/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/Compute/NuGet.Config +++ b/src/ResourceManagement/Compute/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/DataFactory/NuGet.Config b/src/ResourceManagement/DataFactory/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/DataFactory/NuGet.Config +++ b/src/ResourceManagement/DataFactory/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/Dns/NuGet.Config b/src/ResourceManagement/Dns/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/Dns/NuGet.Config +++ b/src/ResourceManagement/Dns/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/Insights/NuGet.Config b/src/ResourceManagement/Insights/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/Insights/NuGet.Config +++ b/src/ResourceManagement/Insights/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/KeyVaultManagement/NuGet.Config b/src/ResourceManagement/KeyVaultManagement/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/KeyVaultManagement/NuGet.Config +++ b/src/ResourceManagement/KeyVaultManagement/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/Network/NuGet.Config b/src/ResourceManagement/Network/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/Network/NuGet.Config +++ b/src/ResourceManagement/Network/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/OperationalInsights/NuGet.Config b/src/ResourceManagement/OperationalInsights/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/OperationalInsights/NuGet.Config +++ b/src/ResourceManagement/OperationalInsights/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/RedisCache/NuGet.Config b/src/ResourceManagement/RedisCache/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/RedisCache/NuGet.Config +++ b/src/ResourceManagement/RedisCache/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/Resource/NuGet.Config b/src/ResourceManagement/Resource/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/Resource/NuGet.Config +++ b/src/ResourceManagement/Resource/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/Resource/ResourceManagement/AuthorizationClient.json b/src/ResourceManagement/Resource/ResourceManagement/AuthorizationClient.json index 8950191d7a29..20433e198d35 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/AuthorizationClient.json +++ b/src/ResourceManagement/Resource/ResourceManagement/AuthorizationClient.json @@ -44,7 +44,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/ManagementLockProperties" + "$ref": "#/definitions/ManagementLock" }, "description": "The management lock parameters." }, @@ -56,16 +56,16 @@ } ], "responses": { - "201": { + "200": { "description": "", "schema": { - "$ref": "#/definitions/ManagementLockObject" + "$ref": "#/definitions/ManagementLock" } }, - "200": { + "201": { "description": "", "schema": { - "$ref": "#/definitions/ManagementLockObject" + "$ref": "#/definitions/ManagementLock" } } } @@ -128,7 +128,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/ManagementLockProperties" + "$ref": "#/definitions/ManagementLock" }, "description": "Create or update management lock parameters." }, @@ -143,13 +143,13 @@ "200": { "description": "", "schema": { - "$ref": "#/definitions/ManagementLockObject" + "$ref": "#/definitions/ManagementLock" } }, "201": { "description": "", "schema": { - "$ref": "#/definitions/ManagementLockObject" + "$ref": "#/definitions/ManagementLock" } } } @@ -213,13 +213,13 @@ } ], "responses": { - "202": { + "204": { "description": "" }, "200": { "description": "" }, - "204": { + "202": { "description": "" } } @@ -245,7 +245,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/ManagementLockProperties" + "$ref": "#/definitions/ManagementLock" }, "description": "The management lock parameters." }, @@ -257,16 +257,16 @@ } ], "responses": { - "200": { + "201": { "description": "", "schema": { - "$ref": "#/definitions/ManagementLockObject" + "$ref": "#/definitions/ManagementLock" } }, - "201": { + "200": { "description": "", "schema": { - "$ref": "#/definitions/ManagementLockObject" + "$ref": "#/definitions/ManagementLock" } } } @@ -296,10 +296,10 @@ "204": { "description": "" }, - "202": { + "200": { "description": "" }, - "200": { + "202": { "description": "" } } @@ -326,16 +326,16 @@ } ], "responses": { - "204": { + "200": { "description": "", "schema": { - "$ref": "#/definitions/ManagementLockObject" + "$ref": "#/definitions/ManagementLock" } }, - "200": { + "204": { "description": "", "schema": { - "$ref": "#/definitions/ManagementLockObject" + "$ref": "#/definitions/ManagementLock" } } } @@ -371,13 +371,13 @@ } ], "responses": { - "200": { + "204": { "description": "" }, - "202": { + "200": { "description": "" }, - "204": { + "202": { "description": "" } } @@ -421,7 +421,7 @@ } }, "x-ms-pageable": true, - "x-ms-odata": "#/definitions/ManagementLockObject" + "x-ms-odata": "#/definitions/ManagementLock" } }, "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}/providers/Microsoft.Authorization/locks": { @@ -492,7 +492,7 @@ } }, "x-ms-pageable": true, - "x-ms-odata": "#/definitions/ManagementLockObject" + "x-ms-odata": "#/definitions/ManagementLock" } }, "/{nextLink}": { @@ -557,7 +557,7 @@ } }, "x-ms-pageable": true, - "x-ms-odata": "#/definitions/ManagementLockObject" + "x-ms-odata": "#/definitions/ManagementLock" } } }, @@ -588,7 +588,7 @@ }, "description": "Resource filter." }, - "ResourceGroupExtendedFilter": { + "ResourceGroupFilter": { "properties": { "tagName": { "type": "string", @@ -620,23 +620,26 @@ }, "description": "The management lock properties." }, - "ManagementLockObject": { + "ManagementLock": { "properties": { "properties": { "$ref": "#/definitions/ManagementLockProperties", "description": "Gets or sets the properties of the lock." }, "id": { + "readOnly": true, "type": "string", - "description": "Gets or sets the Id of the lock." + "description": "Gets the Id of the lock." }, "type": { + "readOnly": true, "type": "string", - "description": "Gets or sets the type of the lock." + "description": "Gets the type of the lock." }, "name": { + "readOnly": true, "type": "string", - "description": "Gets or sets the name of the lock." + "description": "Gets the name of the lock." } }, "description": "Management lock information." @@ -646,7 +649,7 @@ "value": { "type": "array", "items": { - "$ref": "#/definitions/ManagementLockObject" + "$ref": "#/definitions/ManagementLock" }, "description": "Gets or sets the list of locks." }, diff --git a/src/ResourceManagement/Resource/ResourceManagement/FeatureClient.json b/src/ResourceManagement/Resource/ResourceManagement/FeatureClient.json index a04299a8bff8..1b52764561e2 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/FeatureClient.json +++ b/src/ResourceManagement/Resource/ResourceManagement/FeatureClient.json @@ -182,7 +182,7 @@ }, "description": "Resource filter." }, - "ResourceGroupExtendedFilter": { + "ResourceGroupFilter": { "properties": { "tagName": { "type": "string", diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/IManagementLocksOperations.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/IManagementLocksOperations.cs index 538d9afbcfdb..f9ef2229dd7f 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/IManagementLocksOperations.cs +++ b/src/ResourceManagement/Resource/ResourceManagement/Generated/IManagementLocksOperations.cs @@ -35,7 +35,7 @@ public partial interface IManagementLocksOperations /// /// The cancellation token. /// - Task> CreateOrUpdateAtResourceGroupLevelWithHttpMessagesAsync(string resourceGroupName, string lockName, ManagementLockProperties parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task> CreateOrUpdateAtResourceGroupLevelWithHttpMessagesAsync(string resourceGroupName, string lockName, ManagementLock parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// /// Create or update a management lock at the resource level or any /// level below resource. @@ -67,7 +67,7 @@ public partial interface IManagementLocksOperations /// /// The cancellation token. /// - Task> CreateOrUpdateAtResourceLevelWithHttpMessagesAsync(string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, string lockName, ManagementLockProperties parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task> CreateOrUpdateAtResourceLevelWithHttpMessagesAsync(string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, string lockName, ManagementLock parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// /// Deletes the management lock of a resource or any level below /// resource. @@ -112,7 +112,7 @@ public partial interface IManagementLocksOperations /// /// The cancellation token. /// - Task> CreateOrUpdateAtSubscriptionLevelWithHttpMessagesAsync(string lockName, ManagementLockProperties parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task> CreateOrUpdateAtSubscriptionLevelWithHttpMessagesAsync(string lockName, ManagementLock parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// /// Deletes the management lock of a subscription. /// @@ -138,7 +138,7 @@ public partial interface IManagementLocksOperations /// /// The cancellation token. /// - Task> GetWithHttpMessagesAsync(string lockName, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task> GetWithHttpMessagesAsync(string lockName, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// /// Deletes the management lock of a resource group. /// @@ -170,7 +170,7 @@ public partial interface IManagementLocksOperations /// /// The cancellation token. /// - Task>> ListAtResourceGroupLevelWithHttpMessagesAsync(string resourceGroupName, Expression> filter = default(Expression>), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task>> ListAtResourceGroupLevelWithHttpMessagesAsync(string resourceGroupName, Expression> filter = default(Expression>), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// /// Gets all the management locks of a resource or any level below /// resource. @@ -199,7 +199,7 @@ public partial interface IManagementLocksOperations /// /// The cancellation token. /// - Task>> ListAtResourceLevelWithHttpMessagesAsync(string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, Expression> filter = default(Expression>), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task>> ListAtResourceLevelWithHttpMessagesAsync(string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, Expression> filter = default(Expression>), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// /// Get a list of management locks at resource level or below. /// @@ -212,7 +212,7 @@ public partial interface IManagementLocksOperations /// /// The cancellation token. /// - Task>> ListNextWithHttpMessagesAsync(string nextLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task>> ListNextWithHttpMessagesAsync(string nextLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// /// Gets all the management locks of a subscription. /// @@ -225,7 +225,7 @@ public partial interface IManagementLocksOperations /// /// The cancellation token. /// - Task>> ListAtSubscriptionLevelWithHttpMessagesAsync(Expression> filter = default(Expression>), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task>> ListAtSubscriptionLevelWithHttpMessagesAsync(Expression> filter = default(Expression>), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// /// Gets all the management locks of a resource group. /// @@ -238,7 +238,7 @@ public partial interface IManagementLocksOperations /// /// The cancellation token. /// - Task>> ListAtResourceGroupLevelNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task>> ListAtResourceGroupLevelNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// /// Gets all the management locks of a resource or any level below /// resource. @@ -252,7 +252,7 @@ public partial interface IManagementLocksOperations /// /// The cancellation token. /// - Task>> ListAtResourceLevelNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task>> ListAtResourceLevelNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// /// Get a list of management locks at resource level or below. /// @@ -265,7 +265,7 @@ public partial interface IManagementLocksOperations /// /// The cancellation token. /// - Task>> ListNextNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task>> ListNextNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// /// Gets all the management locks of a subscription. /// @@ -278,6 +278,6 @@ public partial interface IManagementLocksOperations /// /// The cancellation token. /// - Task>> ListAtSubscriptionLevelNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task>> ListAtSubscriptionLevelNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); } } diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/IResourceGroupsOperations.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/IResourceGroupsOperations.cs index f4bc904532c2..a41eaabdbb9d 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/IResourceGroupsOperations.cs +++ b/src/ResourceManagement/Resource/ResourceManagement/Generated/IResourceGroupsOperations.cs @@ -66,7 +66,24 @@ public partial interface IResourceGroupsOperations /// /// The cancellation token. /// - Task> CreateOrUpdateWithHttpMessagesAsync(string resourceGroupName, ResourceGroup parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task> CreateOrUpdateWithHttpMessagesAsync(string resourceGroupName, ResourceGroup parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + /// + /// Create a resource group. + /// + /// + /// The name of the resource group to be created or updated. + /// + /// + /// Parameters supplied to the create or update resource group service + /// operation. + /// + /// + /// The headers that will be added to request. + /// + /// + /// The cancellation token. + /// + Task> BeginCreateOrUpdateWithHttpMessagesAsync(string resourceGroupName, ResourceGroup parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// /// Begin deleting resource group.To determine whether the operation /// has finished processing the request, call @@ -112,7 +129,7 @@ public partial interface IResourceGroupsOperations /// /// The cancellation token. /// - Task> GetWithHttpMessagesAsync(string resourceGroupName, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task> GetWithHttpMessagesAsync(string resourceGroupName, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// /// Resource groups can be updated through a simple PATCH operation to /// a group address. The format of the request is the same as that @@ -133,7 +150,7 @@ public partial interface IResourceGroupsOperations /// /// The cancellation token. /// - Task> PatchWithHttpMessagesAsync(string resourceGroupName, ResourceGroup parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task> PatchWithHttpMessagesAsync(string resourceGroupName, ResourceGroup parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// /// Gets a collection of resource groups. /// @@ -149,7 +166,7 @@ public partial interface IResourceGroupsOperations /// /// The cancellation token. /// - Task>> ListWithHttpMessagesAsync(Expression> filter = default(Expression>), int? top = default(int?), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task>> ListWithHttpMessagesAsync(Expression> filter = default(Expression>), int? top = default(int?), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// /// Get all of the resources under a subscription. /// @@ -175,6 +192,6 @@ public partial interface IResourceGroupsOperations /// /// The cancellation token. /// - Task>> ListNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + Task>> ListNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); } } diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/IResourcesOperations.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/IResourcesOperations.cs index e414026fab56..3b8676c00744 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/IResourcesOperations.cs +++ b/src/ResourceManagement/Resource/ResourceManagement/Generated/IResourcesOperations.cs @@ -134,6 +134,36 @@ public partial interface IResourcesOperations /// Task> CreateOrUpdateWithHttpMessagesAsync(string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, string apiVersion, GenericResource parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); /// + /// Create a resource. + /// + /// + /// The name of the resource group. The name is case insensitive. + /// + /// + /// Resource identity. + /// + /// + /// Resource identity. + /// + /// + /// Resource identity. + /// + /// + /// Resource identity. + /// + /// + /// + /// + /// Create or update resource parameters. + /// + /// + /// The headers that will be added to request. + /// + /// + /// The cancellation token. + /// + Task> BeginCreateOrUpdateWithHttpMessagesAsync(string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, string apiVersion, GenericResource parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)); + /// /// Returns a resource belonging to a resource group. /// /// diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/ManagementLocksOperations.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/ManagementLocksOperations.cs index 2e221edfd6cd..ad2d370b7079 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/ManagementLocksOperations.cs +++ b/src/ResourceManagement/Resource/ResourceManagement/Generated/ManagementLocksOperations.cs @@ -56,7 +56,7 @@ internal ManagementLocksOperations(AuthorizationClient client) /// /// Cancellation token. /// - public async Task> CreateOrUpdateAtResourceGroupLevelWithHttpMessagesAsync(string resourceGroupName, string lockName, ManagementLockProperties parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task> CreateOrUpdateAtResourceGroupLevelWithHttpMessagesAsync(string resourceGroupName, string lockName, ManagementLock parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (resourceGroupName == null) { @@ -154,7 +154,7 @@ internal ManagementLocksOperations(AuthorizationClient client) } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); @@ -173,7 +173,7 @@ internal ManagementLocksOperations(AuthorizationClient client) throw ex; } // Create Result - var result = new AzureOperationResponse(); + var result = new AzureOperationResponse(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -181,16 +181,16 @@ internal ManagementLocksOperations(AuthorizationClient client) result.RequestId = httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault(); } // Deserialize Response - if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created")) + if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } // Deserialize Response - if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) + if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { @@ -230,7 +230,7 @@ internal ManagementLocksOperations(AuthorizationClient client) /// /// Cancellation token. /// - public async Task> CreateOrUpdateAtResourceLevelWithHttpMessagesAsync(string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, string lockName, ManagementLockProperties parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task> CreateOrUpdateAtResourceLevelWithHttpMessagesAsync(string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, string lockName, ManagementLock parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (resourceGroupName == null) { @@ -371,7 +371,7 @@ internal ManagementLocksOperations(AuthorizationClient client) throw ex; } // Create Result - var result = new AzureOperationResponse(); + var result = new AzureOperationResponse(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -382,13 +382,13 @@ internal ManagementLocksOperations(AuthorizationClient client) if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } // Deserialize Response if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { @@ -537,7 +537,7 @@ internal ManagementLocksOperations(AuthorizationClient client) } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Accepted") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Accepted"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); ex.Request = httpRequest; @@ -578,7 +578,7 @@ internal ManagementLocksOperations(AuthorizationClient client) /// /// Cancellation token. /// - public async Task> CreateOrUpdateAtSubscriptionLevelWithHttpMessagesAsync(string lockName, ManagementLockProperties parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task> CreateOrUpdateAtSubscriptionLevelWithHttpMessagesAsync(string lockName, ManagementLock parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (lockName == null) { @@ -670,7 +670,7 @@ internal ManagementLocksOperations(AuthorizationClient client) } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); @@ -689,7 +689,7 @@ internal ManagementLocksOperations(AuthorizationClient client) throw ex; } // Create Result - var result = new AzureOperationResponse(); + var result = new AzureOperationResponse(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -697,16 +697,16 @@ internal ManagementLocksOperations(AuthorizationClient client) result.RequestId = httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault(); } // Deserialize Response - if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) + if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } // Deserialize Response - if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created")) + if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { @@ -810,7 +810,7 @@ internal ManagementLocksOperations(AuthorizationClient client) } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Accepted") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Accepted"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); ex.Request = httpRequest; @@ -848,7 +848,7 @@ internal ManagementLocksOperations(AuthorizationClient client) /// /// Cancellation token. /// - public async Task> GetWithHttpMessagesAsync(string lockName, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task> GetWithHttpMessagesAsync(string lockName, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (lockName == null) { @@ -931,7 +931,7 @@ internal ManagementLocksOperations(AuthorizationClient client) } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); @@ -950,7 +950,7 @@ internal ManagementLocksOperations(AuthorizationClient client) throw ex; } // Create Result - var result = new AzureOperationResponse(); + var result = new AzureOperationResponse(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -958,16 +958,16 @@ internal ManagementLocksOperations(AuthorizationClient client) result.RequestId = httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault(); } // Deserialize Response - if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent")) + if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } // Deserialize Response - if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) + if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { @@ -1080,7 +1080,7 @@ internal ManagementLocksOperations(AuthorizationClient client) } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Accepted") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Accepted"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); ex.Request = httpRequest; @@ -1121,7 +1121,7 @@ internal ManagementLocksOperations(AuthorizationClient client) /// /// Cancellation token. /// - public async Task>> ListAtResourceGroupLevelWithHttpMessagesAsync(string resourceGroupName, Expression> filter = default(Expression>), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task>> ListAtResourceGroupLevelWithHttpMessagesAsync(string resourceGroupName, Expression> filter = default(Expression>), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (resourceGroupName == null) { @@ -1228,7 +1228,7 @@ internal ManagementLocksOperations(AuthorizationClient client) throw ex; } // Create Result - var result = new AzureOperationResponse>(); + var result = new AzureOperationResponse>(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -1239,7 +1239,7 @@ internal ManagementLocksOperations(AuthorizationClient client) if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { @@ -1275,7 +1275,7 @@ internal ManagementLocksOperations(AuthorizationClient client) /// /// Cancellation token. /// - public async Task>> ListAtResourceLevelWithHttpMessagesAsync(string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, Expression> filter = default(Expression>), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task>> ListAtResourceLevelWithHttpMessagesAsync(string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, Expression> filter = default(Expression>), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (resourceGroupName == null) { @@ -1406,7 +1406,7 @@ internal ManagementLocksOperations(AuthorizationClient client) throw ex; } // Create Result - var result = new AzureOperationResponse>(); + var result = new AzureOperationResponse>(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -1417,7 +1417,7 @@ internal ManagementLocksOperations(AuthorizationClient client) if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { @@ -1438,7 +1438,7 @@ internal ManagementLocksOperations(AuthorizationClient client) /// /// Cancellation token. /// - public async Task>> ListNextWithHttpMessagesAsync(string nextLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task>> ListNextWithHttpMessagesAsync(string nextLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (nextLink == null) { @@ -1532,7 +1532,7 @@ internal ManagementLocksOperations(AuthorizationClient client) throw ex; } // Create Result - var result = new AzureOperationResponse>(); + var result = new AzureOperationResponse>(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -1543,7 +1543,7 @@ internal ManagementLocksOperations(AuthorizationClient client) if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { @@ -1564,7 +1564,7 @@ internal ManagementLocksOperations(AuthorizationClient client) /// /// Cancellation token. /// - public async Task>> ListAtSubscriptionLevelWithHttpMessagesAsync(Expression> filter = default(Expression>), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task>> ListAtSubscriptionLevelWithHttpMessagesAsync(Expression> filter = default(Expression>), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (this.Client.ApiVersion == null) { @@ -1665,7 +1665,7 @@ internal ManagementLocksOperations(AuthorizationClient client) throw ex; } // Create Result - var result = new AzureOperationResponse>(); + var result = new AzureOperationResponse>(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -1676,7 +1676,7 @@ internal ManagementLocksOperations(AuthorizationClient client) if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { @@ -1697,7 +1697,7 @@ internal ManagementLocksOperations(AuthorizationClient client) /// /// Cancellation token. /// - public async Task>> ListAtResourceGroupLevelNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task>> ListAtResourceGroupLevelNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (nextPageLink == null) { @@ -1785,7 +1785,7 @@ internal ManagementLocksOperations(AuthorizationClient client) throw ex; } // Create Result - var result = new AzureOperationResponse>(); + var result = new AzureOperationResponse>(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -1796,7 +1796,7 @@ internal ManagementLocksOperations(AuthorizationClient client) if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { @@ -1817,7 +1817,7 @@ internal ManagementLocksOperations(AuthorizationClient client) /// /// Cancellation token. /// - public async Task>> ListAtResourceLevelNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task>> ListAtResourceLevelNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (nextPageLink == null) { @@ -1905,7 +1905,7 @@ internal ManagementLocksOperations(AuthorizationClient client) throw ex; } // Create Result - var result = new AzureOperationResponse>(); + var result = new AzureOperationResponse>(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -1916,7 +1916,7 @@ internal ManagementLocksOperations(AuthorizationClient client) if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { @@ -1937,7 +1937,7 @@ internal ManagementLocksOperations(AuthorizationClient client) /// /// Cancellation token. /// - public async Task>> ListNextNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task>> ListNextNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (nextPageLink == null) { @@ -2025,7 +2025,7 @@ internal ManagementLocksOperations(AuthorizationClient client) throw ex; } // Create Result - var result = new AzureOperationResponse>(); + var result = new AzureOperationResponse>(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -2036,7 +2036,7 @@ internal ManagementLocksOperations(AuthorizationClient client) if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { @@ -2057,7 +2057,7 @@ internal ManagementLocksOperations(AuthorizationClient client) /// /// Cancellation token. /// - public async Task>> ListAtSubscriptionLevelNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task>> ListAtSubscriptionLevelNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (nextPageLink == null) { @@ -2145,7 +2145,7 @@ internal ManagementLocksOperations(AuthorizationClient client) throw ex; } // Create Result - var result = new AzureOperationResponse>(); + var result = new AzureOperationResponse>(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -2156,7 +2156,7 @@ internal ManagementLocksOperations(AuthorizationClient client) if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/ManagementLocksOperationsExtensions.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/ManagementLocksOperationsExtensions.cs index a0bd4fe3c1fd..89814eb02738 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/ManagementLocksOperationsExtensions.cs +++ b/src/ResourceManagement/Resource/ResourceManagement/Generated/ManagementLocksOperationsExtensions.cs @@ -27,7 +27,7 @@ public static partial class ManagementLocksOperationsExtensions /// /// The management lock parameters. /// - public static ManagementLockObject CreateOrUpdateAtResourceGroupLevel(this IManagementLocksOperations operations, string resourceGroupName, string lockName, ManagementLockProperties parameters) + public static ManagementLock CreateOrUpdateAtResourceGroupLevel(this IManagementLocksOperations operations, string resourceGroupName, string lockName, ManagementLock parameters) { return Task.Factory.StartNew(s => ((IManagementLocksOperations)s).CreateOrUpdateAtResourceGroupLevelAsync(resourceGroupName, lockName, parameters), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -50,9 +50,9 @@ public static ManagementLockObject CreateOrUpdateAtResourceGroupLevel(this IMana /// /// Cancellation token. /// - public static async Task CreateOrUpdateAtResourceGroupLevelAsync( this IManagementLocksOperations operations, string resourceGroupName, string lockName, ManagementLockProperties parameters, CancellationToken cancellationToken = default(CancellationToken)) + public static async Task CreateOrUpdateAtResourceGroupLevelAsync( this IManagementLocksOperations operations, string resourceGroupName, string lockName, ManagementLock parameters, CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse result = await operations.CreateOrUpdateAtResourceGroupLevelWithHttpMessagesAsync(resourceGroupName, lockName, parameters, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse result = await operations.CreateOrUpdateAtResourceGroupLevelWithHttpMessagesAsync(resourceGroupName, lockName, parameters, null, cancellationToken).ConfigureAwait(false); return result.Body; } @@ -84,7 +84,7 @@ public static ManagementLockObject CreateOrUpdateAtResourceGroupLevel(this IMana /// /// Create or update management lock parameters. /// - public static ManagementLockObject CreateOrUpdateAtResourceLevel(this IManagementLocksOperations operations, string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, string lockName, ManagementLockProperties parameters) + public static ManagementLock CreateOrUpdateAtResourceLevel(this IManagementLocksOperations operations, string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, string lockName, ManagementLock parameters) { return Task.Factory.StartNew(s => ((IManagementLocksOperations)s).CreateOrUpdateAtResourceLevelAsync(resourceGroupName, resourceProviderNamespace, parentResourcePath, resourceType, resourceName, lockName, parameters), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -120,9 +120,9 @@ public static ManagementLockObject CreateOrUpdateAtResourceLevel(this IManagemen /// /// Cancellation token. /// - public static async Task CreateOrUpdateAtResourceLevelAsync( this IManagementLocksOperations operations, string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, string lockName, ManagementLockProperties parameters, CancellationToken cancellationToken = default(CancellationToken)) + public static async Task CreateOrUpdateAtResourceLevelAsync( this IManagementLocksOperations operations, string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, string lockName, ManagementLock parameters, CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse result = await operations.CreateOrUpdateAtResourceLevelWithHttpMessagesAsync(resourceGroupName, resourceProviderNamespace, parentResourcePath, resourceType, resourceName, lockName, parameters, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse result = await operations.CreateOrUpdateAtResourceLevelWithHttpMessagesAsync(resourceGroupName, resourceProviderNamespace, parentResourcePath, resourceType, resourceName, lockName, parameters, null, cancellationToken).ConfigureAwait(false); return result.Body; } @@ -199,7 +199,7 @@ public static void DeleteAtResourceLevel(this IManagementLocksOperations operati /// /// The management lock parameters. /// - public static ManagementLockObject CreateOrUpdateAtSubscriptionLevel(this IManagementLocksOperations operations, string lockName, ManagementLockProperties parameters) + public static ManagementLock CreateOrUpdateAtSubscriptionLevel(this IManagementLocksOperations operations, string lockName, ManagementLock parameters) { return Task.Factory.StartNew(s => ((IManagementLocksOperations)s).CreateOrUpdateAtSubscriptionLevelAsync(lockName, parameters), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -219,9 +219,9 @@ public static ManagementLockObject CreateOrUpdateAtSubscriptionLevel(this IManag /// /// Cancellation token. /// - public static async Task CreateOrUpdateAtSubscriptionLevelAsync( this IManagementLocksOperations operations, string lockName, ManagementLockProperties parameters, CancellationToken cancellationToken = default(CancellationToken)) + public static async Task CreateOrUpdateAtSubscriptionLevelAsync( this IManagementLocksOperations operations, string lockName, ManagementLock parameters, CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse result = await operations.CreateOrUpdateAtSubscriptionLevelWithHttpMessagesAsync(lockName, parameters, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse result = await operations.CreateOrUpdateAtSubscriptionLevelWithHttpMessagesAsync(lockName, parameters, null, cancellationToken).ConfigureAwait(false); return result.Body; } @@ -265,7 +265,7 @@ public static void DeleteAtSubscriptionLevel(this IManagementLocksOperations ope /// /// Name of the management lock. /// - public static ManagementLockObject Get(this IManagementLocksOperations operations, string lockName) + public static ManagementLock Get(this IManagementLocksOperations operations, string lockName) { return Task.Factory.StartNew(s => ((IManagementLocksOperations)s).GetAsync(lockName), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -282,9 +282,9 @@ public static ManagementLockObject Get(this IManagementLocksOperations operation /// /// Cancellation token. /// - public static async Task GetAsync( this IManagementLocksOperations operations, string lockName, CancellationToken cancellationToken = default(CancellationToken)) + public static async Task GetAsync( this IManagementLocksOperations operations, string lockName, CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse result = await operations.GetWithHttpMessagesAsync(lockName, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse result = await operations.GetWithHttpMessagesAsync(lockName, null, cancellationToken).ConfigureAwait(false); return result.Body; } @@ -337,7 +337,7 @@ public static void DeleteAtResourceGroupLevel(this IManagementLocksOperations op /// /// The filter to apply on the operation. /// - public static Page ListAtResourceGroupLevel(this IManagementLocksOperations operations, string resourceGroupName, Expression> filter = default(Expression>)) + public static Page ListAtResourceGroupLevel(this IManagementLocksOperations operations, string resourceGroupName, Expression> filter = default(Expression>)) { return Task.Factory.StartNew(s => ((IManagementLocksOperations)s).ListAtResourceGroupLevelAsync(resourceGroupName, filter), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -357,9 +357,9 @@ public static void DeleteAtResourceGroupLevel(this IManagementLocksOperations op /// /// Cancellation token. /// - public static async Task> ListAtResourceGroupLevelAsync( this IManagementLocksOperations operations, string resourceGroupName, Expression> filter = default(Expression>), CancellationToken cancellationToken = default(CancellationToken)) + public static async Task> ListAtResourceGroupLevelAsync( this IManagementLocksOperations operations, string resourceGroupName, Expression> filter = default(Expression>), CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse> result = await operations.ListAtResourceGroupLevelWithHttpMessagesAsync(resourceGroupName, filter, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse> result = await operations.ListAtResourceGroupLevelWithHttpMessagesAsync(resourceGroupName, filter, null, cancellationToken).ConfigureAwait(false); return result.Body; } @@ -387,7 +387,7 @@ public static void DeleteAtResourceGroupLevel(this IManagementLocksOperations op /// /// The filter to apply on the operation. /// - public static Page ListAtResourceLevel(this IManagementLocksOperations operations, string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, Expression> filter = default(Expression>)) + public static Page ListAtResourceLevel(this IManagementLocksOperations operations, string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, Expression> filter = default(Expression>)) { return Task.Factory.StartNew(s => ((IManagementLocksOperations)s).ListAtResourceLevelAsync(resourceGroupName, resourceProviderNamespace, parentResourcePath, resourceType, resourceName, filter), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -419,9 +419,9 @@ public static void DeleteAtResourceGroupLevel(this IManagementLocksOperations op /// /// Cancellation token. /// - public static async Task> ListAtResourceLevelAsync( this IManagementLocksOperations operations, string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, Expression> filter = default(Expression>), CancellationToken cancellationToken = default(CancellationToken)) + public static async Task> ListAtResourceLevelAsync( this IManagementLocksOperations operations, string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, Expression> filter = default(Expression>), CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse> result = await operations.ListAtResourceLevelWithHttpMessagesAsync(resourceGroupName, resourceProviderNamespace, parentResourcePath, resourceType, resourceName, filter, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse> result = await operations.ListAtResourceLevelWithHttpMessagesAsync(resourceGroupName, resourceProviderNamespace, parentResourcePath, resourceType, resourceName, filter, null, cancellationToken).ConfigureAwait(false); return result.Body; } @@ -434,7 +434,7 @@ public static void DeleteAtResourceGroupLevel(this IManagementLocksOperations op /// /// NextLink from the previous successful call to List operation. /// - public static Page ListNext(this IManagementLocksOperations operations, string nextLink) + public static Page ListNext(this IManagementLocksOperations operations, string nextLink) { return Task.Factory.StartNew(s => ((IManagementLocksOperations)s).ListNextAsync(nextLink), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -451,9 +451,9 @@ public static Page ListNext(this IManagementLocksOperation /// /// Cancellation token. /// - public static async Task> ListNextAsync( this IManagementLocksOperations operations, string nextLink, CancellationToken cancellationToken = default(CancellationToken)) + public static async Task> ListNextAsync( this IManagementLocksOperations operations, string nextLink, CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse> result = await operations.ListNextWithHttpMessagesAsync(nextLink, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse> result = await operations.ListNextWithHttpMessagesAsync(nextLink, null, cancellationToken).ConfigureAwait(false); return result.Body; } @@ -466,7 +466,7 @@ public static Page ListNext(this IManagementLocksOperation /// /// The filter to apply on the operation. /// - public static Page ListAtSubscriptionLevel(this IManagementLocksOperations operations, Expression> filter = default(Expression>)) + public static Page ListAtSubscriptionLevel(this IManagementLocksOperations operations, Expression> filter = default(Expression>)) { return Task.Factory.StartNew(s => ((IManagementLocksOperations)s).ListAtSubscriptionLevelAsync(filter), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -483,9 +483,9 @@ public static Page ListNext(this IManagementLocksOperation /// /// Cancellation token. /// - public static async Task> ListAtSubscriptionLevelAsync( this IManagementLocksOperations operations, Expression> filter = default(Expression>), CancellationToken cancellationToken = default(CancellationToken)) + public static async Task> ListAtSubscriptionLevelAsync( this IManagementLocksOperations operations, Expression> filter = default(Expression>), CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse> result = await operations.ListAtSubscriptionLevelWithHttpMessagesAsync(filter, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse> result = await operations.ListAtSubscriptionLevelWithHttpMessagesAsync(filter, null, cancellationToken).ConfigureAwait(false); return result.Body; } @@ -498,7 +498,7 @@ public static Page ListNext(this IManagementLocksOperation /// /// NextLink from the previous successful call to List operation. /// - public static Page ListAtResourceGroupLevelNext(this IManagementLocksOperations operations, string nextPageLink) + public static Page ListAtResourceGroupLevelNext(this IManagementLocksOperations operations, string nextPageLink) { return Task.Factory.StartNew(s => ((IManagementLocksOperations)s).ListAtResourceGroupLevelNextAsync(nextPageLink), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -515,9 +515,9 @@ public static Page ListAtResourceGroupLevelNext(this IMana /// /// Cancellation token. /// - public static async Task> ListAtResourceGroupLevelNextAsync( this IManagementLocksOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken)) + public static async Task> ListAtResourceGroupLevelNextAsync( this IManagementLocksOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse> result = await operations.ListAtResourceGroupLevelNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse> result = await operations.ListAtResourceGroupLevelNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false); return result.Body; } @@ -530,7 +530,7 @@ public static Page ListAtResourceGroupLevelNext(this IMana /// /// NextLink from the previous successful call to List operation. /// - public static Page ListAtResourceLevelNext(this IManagementLocksOperations operations, string nextPageLink) + public static Page ListAtResourceLevelNext(this IManagementLocksOperations operations, string nextPageLink) { return Task.Factory.StartNew(s => ((IManagementLocksOperations)s).ListAtResourceLevelNextAsync(nextPageLink), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -547,9 +547,9 @@ public static Page ListAtResourceLevelNext(this IManagemen /// /// Cancellation token. /// - public static async Task> ListAtResourceLevelNextAsync( this IManagementLocksOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken)) + public static async Task> ListAtResourceLevelNextAsync( this IManagementLocksOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse> result = await operations.ListAtResourceLevelNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse> result = await operations.ListAtResourceLevelNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false); return result.Body; } @@ -562,7 +562,7 @@ public static Page ListAtResourceLevelNext(this IManagemen /// /// NextLink from the previous successful call to List operation. /// - public static Page ListNextNext(this IManagementLocksOperations operations, string nextPageLink) + public static Page ListNextNext(this IManagementLocksOperations operations, string nextPageLink) { return Task.Factory.StartNew(s => ((IManagementLocksOperations)s).ListNextNextAsync(nextPageLink), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -579,9 +579,9 @@ public static Page ListNextNext(this IManagementLocksOpera /// /// Cancellation token. /// - public static async Task> ListNextNextAsync( this IManagementLocksOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken)) + public static async Task> ListNextNextAsync( this IManagementLocksOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse> result = await operations.ListNextNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse> result = await operations.ListNextNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false); return result.Body; } @@ -594,7 +594,7 @@ public static Page ListNextNext(this IManagementLocksOpera /// /// NextLink from the previous successful call to List operation. /// - public static Page ListAtSubscriptionLevelNext(this IManagementLocksOperations operations, string nextPageLink) + public static Page ListAtSubscriptionLevelNext(this IManagementLocksOperations operations, string nextPageLink) { return Task.Factory.StartNew(s => ((IManagementLocksOperations)s).ListAtSubscriptionLevelNextAsync(nextPageLink), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -611,9 +611,9 @@ public static Page ListAtSubscriptionLevelNext(this IManag /// /// Cancellation token. /// - public static async Task> ListAtSubscriptionLevelNextAsync( this IManagementLocksOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken)) + public static async Task> ListAtSubscriptionLevelNextAsync( this IManagementLocksOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse> result = await operations.ListAtSubscriptionLevelNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse> result = await operations.ListAtSubscriptionLevelNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false); return result.Body; } diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ManagementLockObject.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ManagementLock.cs similarity index 72% rename from src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ManagementLockObject.cs rename to src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ManagementLock.cs index 4d3867b7bc18..761df295d6ba 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ManagementLockObject.cs +++ b/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ManagementLock.cs @@ -10,7 +10,7 @@ namespace Microsoft.Azure.Management.Resources.Models /// /// Management lock information. /// - public partial class ManagementLockObject + public partial class ManagementLock { /// /// Gets or sets the properties of the lock. @@ -19,22 +19,22 @@ public partial class ManagementLockObject public ManagementLockProperties Properties { get; set; } /// - /// Gets or sets the Id of the lock. + /// Gets the Id of the lock. /// [JsonProperty(PropertyName = "id")] - public string Id { get; set; } + public string Id { get; private set; } /// - /// Gets or sets the type of the lock. + /// Gets the type of the lock. /// [JsonProperty(PropertyName = "type")] - public string Type { get; set; } + public string Type { get; private set; } /// - /// Gets or sets the name of the lock. + /// Gets the name of the lock. /// [JsonProperty(PropertyName = "name")] - public string Name { get; set; } + public string Name { get; private set; } } } diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroup.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroup.cs index 74541701d2cc..0d95d2ab78a4 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroup.cs +++ b/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroup.cs @@ -12,6 +12,23 @@ namespace Microsoft.Azure.Management.Resources.Models /// public partial class ResourceGroup { + /// + /// Gets the ID of the resource group. + /// + [JsonProperty(PropertyName = "id")] + public string Id { get; private set; } + + /// + /// Gets or sets the Name of the resource group. + /// + [JsonProperty(PropertyName = "name")] + public string Name { get; set; } + + /// + /// + [JsonProperty(PropertyName = "properties")] + public ResourceGroupProperties Properties { get; set; } + /// /// Gets or sets the location of the resource group. It cannot be /// changed after the resource group has been created. Has to be one @@ -21,23 +38,11 @@ public partial class ResourceGroup [JsonProperty(PropertyName = "location")] public string Location { get; set; } - /// - /// Gets or sets the resource group properties. - /// - [JsonProperty(PropertyName = "properties")] - public object Properties { get; set; } - /// /// Gets or sets the tags attached to the resource group. /// [JsonProperty(PropertyName = "tags")] public IDictionary Tags { get; set; } - /// - /// Gets or sets resource group provisioning state. - /// - [JsonProperty(PropertyName = "provisioningState")] - public string ProvisioningState { get; set; } - } } diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupExtended.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupExtended.cs deleted file mode 100644 index c3a568baf808..000000000000 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupExtended.cs +++ /dev/null @@ -1,54 +0,0 @@ -namespace Microsoft.Azure.Management.Resources.Models -{ - using System; - using System.Collections.Generic; - using Newtonsoft.Json; - using Microsoft.Rest; - using Microsoft.Rest.Serialization; - using Microsoft.Rest.Azure; - - /// - /// Resource group information. - /// - public partial class ResourceGroupExtended - { - /// - /// Gets or sets the ID of the resource group. - /// - [JsonProperty(PropertyName = "id")] - public string Id { get; set; } - - /// - /// Gets or sets the Name of the resource group. - /// - [JsonProperty(PropertyName = "name")] - public string Name { get; set; } - - /// - /// - [JsonProperty(PropertyName = "properties")] - public ResourceGroupFormatResourceProperties Properties { get; set; } - - /// - /// Gets or sets the location of the resource group. It cannot be - /// changed after the resource group has been created. Has to be one - /// of the supported Azure Locations, such as West US, East US, West - /// Europe, East Asia, etc. - /// - [JsonProperty(PropertyName = "location")] - public string Location { get; set; } - - /// - /// Gets or sets the tags attached to the resource group. - /// - [JsonProperty(PropertyName = "tags")] - public IDictionary Tags { get; set; } - - /// - /// Gets or sets resource group provisioning state. - /// - [JsonProperty(PropertyName = "provisioningState")] - public string ProvisioningState { get; set; } - - } -} diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupExtendedFilter.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupFilter.cs similarity index 92% rename from src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupExtendedFilter.cs rename to src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupFilter.cs index 0579954c067f..2edf452bfb58 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupExtendedFilter.cs +++ b/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupFilter.cs @@ -10,7 +10,7 @@ namespace Microsoft.Azure.Management.Resources.Models /// /// Resource group filter. /// - public partial class ResourceGroupExtendedFilter + public partial class ResourceGroupFilter { /// /// Gets or sets the tag name. diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupFormatResourceProperties.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupProperties.cs similarity index 70% rename from src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupFormatResourceProperties.cs rename to src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupProperties.cs index 134426abe34a..12c0bb39b7c2 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupFormatResourceProperties.cs +++ b/src/ResourceManagement/Resource/ResourceManagement/Generated/Models/ResourceGroupProperties.cs @@ -10,13 +10,13 @@ namespace Microsoft.Azure.Management.Resources.Models /// /// The resource group properties. /// - public partial class ResourceGroupFormatResourceProperties + public partial class ResourceGroupProperties { /// - /// Gets or sets resource group provisioning state. + /// Gets resource group provisioning state. /// [JsonProperty(PropertyName = "provisioningState")] - public string ProvisioningState { get; set; } + public string ProvisioningState { get; private set; } } } diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourceGroupsOperations.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourceGroupsOperations.cs index 0218c88aa1b8..abc821d68d73 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourceGroupsOperations.cs +++ b/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourceGroupsOperations.cs @@ -283,7 +283,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NotFound") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NotFound"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); @@ -317,6 +317,32 @@ internal ResourceGroupsOperations(ResourceManagementClient client) return result; } + /// + /// Create a resource group. + /// + /// + /// The name of the resource group to be created or updated. + /// + /// + /// Parameters supplied to the create or update resource group service + /// operation. + /// + /// + /// The headers that will be added to request. + /// + /// + /// The cancellation token. + /// + public async Task> CreateOrUpdateWithHttpMessagesAsync(string resourceGroupName, ResourceGroup parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + { + // Send Request + AzureOperationResponse response = await BeginCreateOrUpdateWithHttpMessagesAsync( + resourceGroupName, parameters, customHeaders, cancellationToken); + return await this.Client.GetPutOrPatchOperationResultAsync(response, + customHeaders, + cancellationToken); + } + /// /// Create a resource group. /// @@ -333,7 +359,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) /// /// Cancellation token. /// - public async Task> CreateOrUpdateWithHttpMessagesAsync(string resourceGroupName, ResourceGroup parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task> BeginCreateOrUpdateWithHttpMessagesAsync(string resourceGroupName, ResourceGroup parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (resourceGroupName == null) { @@ -361,7 +387,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) tracingParameters.Add("resourceGroupName", resourceGroupName); tracingParameters.Add("parameters", parameters); tracingParameters.Add("cancellationToken", cancellationToken); - ServiceClientTracing.Enter(invocationId, this, "CreateOrUpdate", tracingParameters); + ServiceClientTracing.Enter(invocationId, this, "BeginCreateOrUpdate", tracingParameters); } // Construct URL string url = this.Client.BaseUri.AbsoluteUri + @@ -425,7 +451,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Accepted"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); @@ -444,7 +470,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) throw ex; } // Create Result - var result = new AzureOperationResponse(); + var result = new AzureOperationResponse(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -455,13 +481,13 @@ internal ResourceGroupsOperations(ResourceManagementClient client) if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } // Deserialize Response if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { @@ -625,7 +651,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) /// /// Cancellation token. /// - public async Task> GetWithHttpMessagesAsync(string resourceGroupName, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task> GetWithHttpMessagesAsync(string resourceGroupName, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (resourceGroupName == null) { @@ -727,7 +753,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) throw ex; } // Create Result - var result = new AzureOperationResponse(); + var result = new AzureOperationResponse(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -738,7 +764,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { @@ -766,7 +792,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) /// /// Cancellation token. /// - public async Task> PatchWithHttpMessagesAsync(string resourceGroupName, ResourceGroup parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task> PatchWithHttpMessagesAsync(string resourceGroupName, ResourceGroup parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (resourceGroupName == null) { @@ -877,7 +903,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) throw ex; } // Create Result - var result = new AzureOperationResponse(); + var result = new AzureOperationResponse(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -888,7 +914,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { @@ -912,7 +938,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) /// /// Cancellation token. /// - public async Task>> ListWithHttpMessagesAsync(Expression> filter = default(Expression>), int? top = default(int?), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task>> ListWithHttpMessagesAsync(Expression> filter = default(Expression>), int? top = default(int?), Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (this.Client.ApiVersion == null) { @@ -1018,7 +1044,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) throw ex; } // Create Result - var result = new AzureOperationResponse>(); + var result = new AzureOperationResponse>(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -1029,7 +1055,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { @@ -1170,7 +1196,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) /// /// Cancellation token. /// - public async Task>> ListNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task>> ListNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (nextPageLink == null) { @@ -1258,7 +1284,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) throw ex; } // Create Result - var result = new AzureOperationResponse>(); + var result = new AzureOperationResponse>(); result.Request = httpRequest; result.Response = httpResponse; if (httpResponse.Headers.Contains("x-ms-request-id")) @@ -1269,7 +1295,7 @@ internal ResourceGroupsOperations(ResourceManagementClient client) if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); - result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); + result.Body = JsonConvert.DeserializeObject>(responseContent, this.Client.DeserializationSettings); } if (shouldTrace) { diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourceGroupsOperationsExtensions.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourceGroupsOperationsExtensions.cs index 4e0069997360..773f8e8c0820 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourceGroupsOperationsExtensions.cs +++ b/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourceGroupsOperationsExtensions.cs @@ -101,7 +101,7 @@ public static partial class ResourceGroupsOperationsExtensions /// Parameters supplied to the create or update resource group service /// operation. /// - public static ResourceGroupExtended CreateOrUpdate(this IResourceGroupsOperations operations, string resourceGroupName, ResourceGroup parameters) + public static ResourceGroup CreateOrUpdate(this IResourceGroupsOperations operations, string resourceGroupName, ResourceGroup parameters) { return Task.Factory.StartNew(s => ((IResourceGroupsOperations)s).CreateOrUpdateAsync(resourceGroupName, parameters), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -122,9 +122,49 @@ public static ResourceGroupExtended CreateOrUpdate(this IResourceGroupsOperation /// /// Cancellation token. /// - public static async Task CreateOrUpdateAsync( this IResourceGroupsOperations operations, string resourceGroupName, ResourceGroup parameters, CancellationToken cancellationToken = default(CancellationToken)) + public static async Task CreateOrUpdateAsync( this IResourceGroupsOperations operations, string resourceGroupName, ResourceGroup parameters, CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse result = await operations.CreateOrUpdateWithHttpMessagesAsync(resourceGroupName, parameters, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse result = await operations.CreateOrUpdateWithHttpMessagesAsync(resourceGroupName, parameters, null, cancellationToken).ConfigureAwait(false); + return result.Body; + } + + /// + /// Create a resource group. + /// + /// + /// The operations group for this extension method. + /// + /// + /// The name of the resource group to be created or updated. + /// + /// + /// Parameters supplied to the create or update resource group service + /// operation. + /// + public static ResourceGroup BeginCreateOrUpdate(this IResourceGroupsOperations operations, string resourceGroupName, ResourceGroup parameters) + { + return Task.Factory.StartNew(s => ((IResourceGroupsOperations)s).BeginCreateOrUpdateAsync(resourceGroupName, parameters), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); + } + + /// + /// Create a resource group. + /// + /// + /// The operations group for this extension method. + /// + /// + /// The name of the resource group to be created or updated. + /// + /// + /// Parameters supplied to the create or update resource group service + /// operation. + /// + /// + /// Cancellation token. + /// + public static async Task BeginCreateOrUpdateAsync( this IResourceGroupsOperations operations, string resourceGroupName, ResourceGroup parameters, CancellationToken cancellationToken = default(CancellationToken)) + { + AzureOperationResponse result = await operations.BeginCreateOrUpdateWithHttpMessagesAsync(resourceGroupName, parameters, null, cancellationToken).ConfigureAwait(false); return result.Body; } @@ -203,7 +243,7 @@ public static void BeginDelete(this IResourceGroupsOperations operations, string /// /// The name of the resource group to get. The name is case insensitive. /// - public static ResourceGroupExtended Get(this IResourceGroupsOperations operations, string resourceGroupName) + public static ResourceGroup Get(this IResourceGroupsOperations operations, string resourceGroupName) { return Task.Factory.StartNew(s => ((IResourceGroupsOperations)s).GetAsync(resourceGroupName), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -220,9 +260,9 @@ public static ResourceGroupExtended Get(this IResourceGroupsOperations operation /// /// Cancellation token. /// - public static async Task GetAsync( this IResourceGroupsOperations operations, string resourceGroupName, CancellationToken cancellationToken = default(CancellationToken)) + public static async Task GetAsync( this IResourceGroupsOperations operations, string resourceGroupName, CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse result = await operations.GetWithHttpMessagesAsync(resourceGroupName, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse result = await operations.GetWithHttpMessagesAsync(resourceGroupName, null, cancellationToken).ConfigureAwait(false); return result.Body; } @@ -242,7 +282,7 @@ public static ResourceGroupExtended Get(this IResourceGroupsOperations operation /// /// Parameters supplied to the update state resource group service operation. /// - public static ResourceGroupExtended Patch(this IResourceGroupsOperations operations, string resourceGroupName, ResourceGroup parameters) + public static ResourceGroup Patch(this IResourceGroupsOperations operations, string resourceGroupName, ResourceGroup parameters) { return Task.Factory.StartNew(s => ((IResourceGroupsOperations)s).PatchAsync(resourceGroupName, parameters), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -266,9 +306,9 @@ public static ResourceGroupExtended Patch(this IResourceGroupsOperations operati /// /// Cancellation token. /// - public static async Task PatchAsync( this IResourceGroupsOperations operations, string resourceGroupName, ResourceGroup parameters, CancellationToken cancellationToken = default(CancellationToken)) + public static async Task PatchAsync( this IResourceGroupsOperations operations, string resourceGroupName, ResourceGroup parameters, CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse result = await operations.PatchWithHttpMessagesAsync(resourceGroupName, parameters, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse result = await operations.PatchWithHttpMessagesAsync(resourceGroupName, parameters, null, cancellationToken).ConfigureAwait(false); return result.Body; } @@ -284,7 +324,7 @@ public static ResourceGroupExtended Patch(this IResourceGroupsOperations operati /// /// Query parameters. If null is passed returns all resource groups. /// - public static Page List(this IResourceGroupsOperations operations, Expression> filter = default(Expression>), int? top = default(int?)) + public static Page List(this IResourceGroupsOperations operations, Expression> filter = default(Expression>), int? top = default(int?)) { return Task.Factory.StartNew(s => ((IResourceGroupsOperations)s).ListAsync(filter, top), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -304,9 +344,9 @@ public static ResourceGroupExtended Patch(this IResourceGroupsOperations operati /// /// Cancellation token. /// - public static async Task> ListAsync( this IResourceGroupsOperations operations, Expression> filter = default(Expression>), int? top = default(int?), CancellationToken cancellationToken = default(CancellationToken)) + public static async Task> ListAsync( this IResourceGroupsOperations operations, Expression> filter = default(Expression>), int? top = default(int?), CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse> result = await operations.ListWithHttpMessagesAsync(filter, top, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse> result = await operations.ListWithHttpMessagesAsync(filter, top, null, cancellationToken).ConfigureAwait(false); return result.Body; } @@ -351,7 +391,7 @@ public static Page ListResourcesNext(this IResourceGroupsOperat /// /// NextLink from the previous successful call to List operation. /// - public static Page ListNext(this IResourceGroupsOperations operations, string nextPageLink) + public static Page ListNext(this IResourceGroupsOperations operations, string nextPageLink) { return Task.Factory.StartNew(s => ((IResourceGroupsOperations)s).ListNextAsync(nextPageLink), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); } @@ -368,9 +408,9 @@ public static Page ListNext(this IResourceGroupsOperation /// /// Cancellation token. /// - public static async Task> ListNextAsync( this IResourceGroupsOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken)) + public static async Task> ListNextAsync( this IResourceGroupsOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken)) { - AzureOperationResponse> result = await operations.ListNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false); + AzureOperationResponse> result = await operations.ListNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false); return result.Body; } diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourceProviderOperationDetailsOperations.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourceProviderOperationDetailsOperations.cs index 087f22e1d31a..f6c20c753be7 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourceProviderOperationDetailsOperations.cs +++ b/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourceProviderOperationDetailsOperations.cs @@ -136,7 +136,7 @@ internal ResourceProviderOperationDetailsOperations(ResourceManagementClient cli } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); @@ -163,13 +163,13 @@ internal ResourceProviderOperationDetailsOperations(ResourceManagementClient cli result.RequestId = httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault(); } // Deserialize Response - if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent")) + if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } // Deserialize Response - if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) + if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourcesOperations.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourcesOperations.cs index c62b867942a6..550408d4ab02 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourcesOperations.cs +++ b/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourcesOperations.cs @@ -614,7 +614,7 @@ internal ResourcesOperations(ResourceManagementClient client) } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Accepted") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Accepted"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); ex.Request = httpRequest; @@ -640,6 +640,45 @@ internal ResourcesOperations(ResourceManagementClient client) return result; } + /// + /// Create a resource. + /// + /// + /// The name of the resource group. The name is case insensitive. + /// + /// + /// Resource identity. + /// + /// + /// Resource identity. + /// + /// + /// Resource identity. + /// + /// + /// Resource identity. + /// + /// + /// + /// + /// Create or update resource parameters. + /// + /// + /// The headers that will be added to request. + /// + /// + /// The cancellation token. + /// + public async Task> CreateOrUpdateWithHttpMessagesAsync(string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, string apiVersion, GenericResource parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + { + // Send Request + AzureOperationResponse response = await BeginCreateOrUpdateWithHttpMessagesAsync( + resourceGroupName, resourceProviderNamespace, parentResourcePath, resourceType, resourceName, apiVersion, parameters, customHeaders, cancellationToken); + return await this.Client.GetPutOrPatchOperationResultAsync(response, + customHeaders, + cancellationToken); + } + /// /// Create a resource. /// @@ -669,7 +708,7 @@ internal ResourcesOperations(ResourceManagementClient client) /// /// Cancellation token. /// - public async Task> CreateOrUpdateWithHttpMessagesAsync(string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, string apiVersion, GenericResource parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) + public async Task> BeginCreateOrUpdateWithHttpMessagesAsync(string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, string apiVersion, GenericResource parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken)) { if (resourceGroupName == null) { @@ -722,7 +761,7 @@ internal ResourcesOperations(ResourceManagementClient client) tracingParameters.Add("apiVersion", apiVersion); tracingParameters.Add("parameters", parameters); tracingParameters.Add("cancellationToken", cancellationToken); - ServiceClientTracing.Enter(invocationId, this, "CreateOrUpdate", tracingParameters); + ServiceClientTracing.Enter(invocationId, this, "BeginCreateOrUpdate", tracingParameters); } // Construct URL string url = this.Client.BaseUri.AbsoluteUri + @@ -790,7 +829,7 @@ internal ResourcesOperations(ResourceManagementClient client) } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Accepted") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); @@ -969,7 +1008,7 @@ internal ResourcesOperations(ResourceManagementClient client) } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); @@ -996,13 +1035,13 @@ internal ResourcesOperations(ResourceManagementClient client) result.RequestId = httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault(); } // Deserialize Response - if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent")) + if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } // Deserialize Response - if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) + if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourcesOperationsExtensions.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourcesOperationsExtensions.cs index 20c466a1b4d7..c9d077960e99 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourcesOperationsExtensions.cs +++ b/src/ResourceManagement/Resource/ResourceManagement/Generated/ResourcesOperationsExtensions.cs @@ -272,6 +272,72 @@ public static GenericResource CreateOrUpdate(this IResourcesOperations operation return result.Body; } + /// + /// Create a resource. + /// + /// + /// The operations group for this extension method. + /// + /// + /// The name of the resource group. The name is case insensitive. + /// + /// + /// Resource identity. + /// + /// + /// Resource identity. + /// + /// + /// Resource identity. + /// + /// + /// Resource identity. + /// + /// + /// + /// + /// Create or update resource parameters. + /// + public static GenericResource BeginCreateOrUpdate(this IResourcesOperations operations, string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, string apiVersion, GenericResource parameters) + { + return Task.Factory.StartNew(s => ((IResourcesOperations)s).BeginCreateOrUpdateAsync(resourceGroupName, resourceProviderNamespace, parentResourcePath, resourceType, resourceName, apiVersion, parameters), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult(); + } + + /// + /// Create a resource. + /// + /// + /// The operations group for this extension method. + /// + /// + /// The name of the resource group. The name is case insensitive. + /// + /// + /// Resource identity. + /// + /// + /// Resource identity. + /// + /// + /// Resource identity. + /// + /// + /// Resource identity. + /// + /// + /// + /// + /// Create or update resource parameters. + /// + /// + /// Cancellation token. + /// + public static async Task BeginCreateOrUpdateAsync( this IResourcesOperations operations, string resourceGroupName, string resourceProviderNamespace, string parentResourcePath, string resourceType, string resourceName, string apiVersion, GenericResource parameters, CancellationToken cancellationToken = default(CancellationToken)) + { + AzureOperationResponse result = await operations.BeginCreateOrUpdateWithHttpMessagesAsync(resourceGroupName, resourceProviderNamespace, parentResourcePath, resourceType, resourceName, apiVersion, parameters, null, cancellationToken).ConfigureAwait(false); + return result.Body; + } + /// /// Returns a resource belonging to a resource group. /// diff --git a/src/ResourceManagement/Resource/ResourceManagement/Generated/TagsOperations.cs b/src/ResourceManagement/Resource/ResourceManagement/Generated/TagsOperations.cs index 9223ee751a4e..ec0e6ad4b772 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/Generated/TagsOperations.cs +++ b/src/ResourceManagement/Resource/ResourceManagement/Generated/TagsOperations.cs @@ -142,7 +142,7 @@ internal TagsOperations(ResourceManagementClient client) } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); ex.Request = httpRequest; @@ -272,7 +272,7 @@ internal TagsOperations(ResourceManagementClient client) } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); @@ -299,13 +299,13 @@ internal TagsOperations(ResourceManagementClient client) result.RequestId = httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault(); } // Deserialize Response - if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created")) + if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } // Deserialize Response - if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) + if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); @@ -412,7 +412,7 @@ internal TagsOperations(ResourceManagementClient client) } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); @@ -439,13 +439,13 @@ internal TagsOperations(ResourceManagementClient client) result.RequestId = httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault(); } // Deserialize Response - if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created")) + if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); } // Deserialize Response - if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK")) + if (statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "Created")) { string responseContent = await httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false); result.Body = JsonConvert.DeserializeObject(responseContent, this.Client.DeserializationSettings); @@ -552,7 +552,7 @@ internal TagsOperations(ResourceManagementClient client) } HttpStatusCode statusCode = httpResponse.StatusCode; cancellationToken.ThrowIfCancellationRequested(); - if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK"))) + if (!(statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "OK") || statusCode == (HttpStatusCode)Enum.Parse(typeof(HttpStatusCode), "NoContent"))) { var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", statusCode)); ex.Request = httpRequest; diff --git a/src/ResourceManagement/Resource/ResourceManagement/ResourceManagementClient.json b/src/ResourceManagement/Resource/ResourceManagement/ResourceManagementClient.json index 55d830458133..4608a37609fb 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/ResourceManagementClient.json +++ b/src/ResourceManagement/Resource/ResourceManagement/ResourceManagementClient.json @@ -219,10 +219,10 @@ } ], "responses": { - "404": { + "204": { "description": "" }, - "204": { + "404": { "description": "" } } @@ -261,16 +261,20 @@ "201": { "description": "", "schema": { - "$ref": "#/definitions/ResourceGroupExtended" + "$ref": "#/definitions/ResourceGroup" } }, "200": { "description": "", "schema": { - "$ref": "#/definitions/ResourceGroupExtended" + "$ref": "#/definitions/ResourceGroup" } + }, + "202": { + "description": "" } - } + }, + "x-ms-long-running-operation": true }, "delete": { "tags": [ @@ -328,7 +332,7 @@ "200": { "description": "", "schema": { - "$ref": "#/definitions/ResourceGroupExtended" + "$ref": "#/definitions/ResourceGroup" } } } @@ -367,7 +371,7 @@ "200": { "description": "", "schema": { - "$ref": "#/definitions/ResourceGroupExtended" + "$ref": "#/definitions/ResourceGroup" } } } @@ -412,7 +416,7 @@ } }, "x-ms-pageable": true, - "x-ms-odata": "#/definitions/ResourceGroupExtendedFilter" + "x-ms-odata": "#/definitions/ResourceGroupFilter" } }, "/subscriptions/{subscriptionId}/resourceGroups/{sourceResourceGroupName}/moveResources": { @@ -614,13 +618,13 @@ } ], "responses": { - "204": { + "200": { "description": "" }, - "202": { + "204": { "description": "" }, - "200": { + "202": { "description": "" } } @@ -695,13 +699,17 @@ "$ref": "#/definitions/GenericResource" } }, + "202": { + "description": "" + }, "200": { "description": "", "schema": { "$ref": "#/definitions/GenericResource" } } - } + }, + "x-ms-long-running-operation": true }, "get": { "tags": [ @@ -758,13 +766,13 @@ } ], "responses": { - "204": { + "200": { "description": "", "schema": { "$ref": "#/definitions/GenericResource" } }, - "200": { + "204": { "description": "", "schema": { "$ref": "#/definitions/GenericResource" @@ -803,10 +811,10 @@ } ], "responses": { - "204": { + "200": { "description": "" }, - "200": { + "204": { "description": "" } } @@ -840,13 +848,13 @@ } ], "responses": { - "201": { + "200": { "description": "", "schema": { "$ref": "#/definitions/TagValue" } }, - "200": { + "201": { "description": "", "schema": { "$ref": "#/definitions/TagValue" @@ -878,13 +886,13 @@ } ], "responses": { - "201": { + "200": { "description": "", "schema": { "$ref": "#/definitions/TagDetails" } }, - "200": { + "201": { "description": "", "schema": { "$ref": "#/definitions/TagDetails" @@ -914,10 +922,10 @@ } ], "responses": { - "204": { + "200": { "description": "" }, - "200": { + "204": { "description": "" } } @@ -1069,13 +1077,13 @@ } ], "responses": { - "204": { + "200": { "description": "", "schema": { "$ref": "#/definitions/ResourceProviderOperationDetailListResult" } }, - "200": { + "204": { "description": "", "schema": { "$ref": "#/definitions/ResourceProviderOperationDetailListResult" @@ -1342,7 +1350,7 @@ }, "description": "Resource filter." }, - "ResourceGroupExtendedFilter": { + "ResourceGroupFilter": { "properties": { "tagName": { "type": "string", @@ -1480,51 +1488,29 @@ }, "description": "List of resource groups." }, - "ResourceGroup": { - "properties": { - "location": { - "type": "string", - "description": "Gets or sets the location of the resource group. It cannot be changed after the resource group has been created. Has to be one of the supported Azure Locations, such as West US, East US, West Europe, East Asia, etc." - }, - "properties": { - "type": "object", - "description": "Gets or sets the resource group properties." - }, - "tags": { - "type": "object", - "additionalProperties": { - "type": "string" - }, - "description": "Gets or sets the tags attached to the resource group." - }, - "provisioningState": { - "type": "string", - "description": "Gets or sets resource group provisioning state." - } - }, - "description": "Resource group information." - }, - "ResourceGroupFormatResourceProperties": { + "ResourceGroupProperties": { "properties": { "provisioningState": { + "readOnly": true, "type": "string", - "description": "Gets or sets resource group provisioning state." + "description": "Gets resource group provisioning state." } }, "description": "The resource group properties." }, - "ResourceGroupExtended": { + "ResourceGroup": { "properties": { "id": { + "readOnly": true, "type": "string", - "description": "Gets or sets the ID of the resource group." + "description": "Gets the ID of the resource group." }, "name": { "type": "string", "description": "Gets or sets the Name of the resource group." }, "properties": { - "$ref": "#/definitions/ResourceGroupFormatResourceProperties" + "$ref": "#/definitions/ResourceGroupProperties" }, "location": { "type": "string", @@ -1536,10 +1522,6 @@ "type": "string" }, "description": "Gets or sets the tags attached to the resource group." - }, - "provisioningState": { - "type": "string", - "description": "Gets or sets resource group provisioning state." } }, "description": "Resource group information." @@ -1549,7 +1531,7 @@ "value": { "type": "array", "items": { - "$ref": "#/definitions/ResourceGroupExtended" + "$ref": "#/definitions/ResourceGroup" }, "description": "Gets or sets the list of resource groups." }, diff --git a/src/ResourceManagement/Resource/ResourceManagement/ResourceManagementClientOData.json b/src/ResourceManagement/Resource/ResourceManagement/ResourceManagementClientOData.json deleted file mode 100644 index a96ab695d6fb..000000000000 --- a/src/ResourceManagement/Resource/ResourceManagement/ResourceManagementClientOData.json +++ /dev/null @@ -1,21 +0,0 @@ -{ - "definitions": { - "GenericResourceFilter": { - "properties": { - "resourceType": { - "type": "string", - "description": "Gets or sets the type of the resource." - }, - "tagname": { - "type": "string", - "description": "Gets or sets the tag name." - }, - "tagvalue": { - "type": "string", - "description": "Gets or sets the tag value." - } - }, - "description": "Resource filter." - } - } -} \ No newline at end of file diff --git a/src/ResourceManagement/Resource/ResourceManagement/SubscriptionClient.json b/src/ResourceManagement/Resource/ResourceManagement/SubscriptionClient.json index 7db4ae2816e1..b8ef2159628f 100644 --- a/src/ResourceManagement/Resource/ResourceManagement/SubscriptionClient.json +++ b/src/ResourceManagement/Resource/ResourceManagement/SubscriptionClient.json @@ -126,7 +126,7 @@ }, "description": "Resource filter." }, - "ResourceGroupExtendedFilter": { + "ResourceGroupFilter": { "properties": { "tagName": { "type": "string", diff --git a/src/ResourceManagement/Resource/Resources.Tests/InMemoryTests/ResourceTests.InMemory.cs b/src/ResourceManagement/Resource/Resources.Tests/InMemoryTests/ResourceTests.InMemory.cs index e86290a5b643..8651a95a3930 100644 --- a/src/ResourceManagement/Resource/Resources.Tests/InMemoryTests/ResourceTests.InMemory.cs +++ b/src/ResourceManagement/Resource/Resources.Tests/InMemoryTests/ResourceTests.InMemory.cs @@ -52,7 +52,7 @@ public void ResourceGetValidateMessage() 'name':'site1', 'siteMode': 'Standard', 'computeMode':'Dedicated', - 'provisioningState':'Running' + 'provisioningState':'Succeeded' } }") }; @@ -71,7 +71,7 @@ public void ResourceGetValidateMessage() Assert.Equal("site1", result.Name); Assert.Equal("/subscriptions/12345/resourceGroups/foo/providers/Microsoft.Web/Sites/site1", result.Id); Assert.True(result.Properties.ToString().Contains("Dedicated")); - Assert.Equal("Running", (result.Properties as JObject)["provisioningState"]); + Assert.Equal("Succeeded", (result.Properties as JObject)["provisioningState"]); } [Fact] @@ -137,7 +137,7 @@ public void ResourceListValidateMessage() 'name':'site1', 'siteMode': 'Standard', 'computeMode':'Dedicated', - 'provisioningState':'Running' + 'provisioningState':'Succeeded' } }, { @@ -175,7 +175,7 @@ public void ResourceListValidateMessage() Assert.Equal("/subscriptions/12345/resourceGroups/foo/providers/Microsoft.Web/Sites/site1", result.First().Id); Assert.Equal("/subscriptions/12345/resourceGroups/foo/providers/Microsoft.Web/Sites/site1", result.First().Id); Assert.True(result.First().Properties.ToString().Contains("Dedicated")); - Assert.Equal("Running", (result.First().Properties as JObject)["provisioningState"]); + Assert.Equal("Succeeded", (result.First().Properties as JObject)["provisioningState"]); } [Fact] @@ -242,7 +242,7 @@ public void ResourceCreateOrUpdateValidateMessage() 'name':'site3', 'siteMode': 'Standard', 'computeMode':'Dedicated', - 'provisioningState':'Running' + 'provisioningState':'Succeeded' } }") }; @@ -282,7 +282,7 @@ public void ResourceCreateOrUpdateValidateMessage() // Validate result Assert.Equal("South Central US", result.Location); - Assert.Equal("Running", (result.Properties as JObject)["provisioningState"]); + Assert.Equal("Succeeded", (result.Properties as JObject)["provisioningState"]); Assert.Equal("finance", result.Tags["department"]); Assert.Equal("tagvalue", result.Tags["tagname"]); Assert.True(result.Properties.ToString().Contains("Dedicated")); diff --git a/src/ResourceManagement/Sql/NuGet.Config b/src/ResourceManagement/Sql/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/Sql/NuGet.Config +++ b/src/ResourceManagement/Sql/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/Storage/NuGet.Config b/src/ResourceManagement/Storage/NuGet.Config index dcff8ff3ab0e..4f17a255bb2f 100644 --- a/src/ResourceManagement/Storage/NuGet.Config +++ b/src/ResourceManagement/Storage/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + \ No newline at end of file diff --git a/src/ResourceManagement/StreamAnalytics/NuGet.Config b/src/ResourceManagement/StreamAnalytics/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/StreamAnalytics/NuGet.Config +++ b/src/ResourceManagement/StreamAnalytics/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/TrafficManager/NuGet.Config b/src/ResourceManagement/TrafficManager/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/TrafficManager/NuGet.Config +++ b/src/ResourceManagement/TrafficManager/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ResourceManagement/WebSite/NuGet.Config b/src/ResourceManagement/WebSite/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ResourceManagement/WebSite/NuGet.Config +++ b/src/ResourceManagement/WebSite/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/Search/NuGet.Config b/src/Search/NuGet.Config index edafa204a2dd..2de911013532 100644 --- a/src/Search/NuGet.Config +++ b/src/Search/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\packages - + + + + + diff --git a/src/ServiceManagement/Automation/NuGet.Config b/src/ServiceManagement/Automation/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/Automation/NuGet.Config +++ b/src/ServiceManagement/Automation/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/Compute/NuGet.Config b/src/ServiceManagement/Compute/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/Compute/NuGet.Config +++ b/src/ServiceManagement/Compute/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/ExpressRoute/NuGet.Config b/src/ServiceManagement/ExpressRoute/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/ExpressRoute/NuGet.Config +++ b/src/ServiceManagement/ExpressRoute/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/Management/NuGet.Config b/src/ServiceManagement/Management/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/Management/NuGet.Config +++ b/src/ServiceManagement/Management/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/MediaServices/NuGet.Config b/src/ServiceManagement/MediaServices/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/MediaServices/NuGet.Config +++ b/src/ServiceManagement/MediaServices/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/Monitoring/NuGet.Config b/src/ServiceManagement/Monitoring/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/Monitoring/NuGet.Config +++ b/src/ServiceManagement/Monitoring/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/Network/NuGet.Config b/src/ServiceManagement/Network/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/Network/NuGet.Config +++ b/src/ServiceManagement/Network/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/RemoteApp/NuGet.Config b/src/ServiceManagement/RemoteApp/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/RemoteApp/NuGet.Config +++ b/src/ServiceManagement/RemoteApp/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/Scheduler/NuGet.Config b/src/ServiceManagement/Scheduler/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/Scheduler/NuGet.Config +++ b/src/ServiceManagement/Scheduler/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/ServiceBus/NuGet.Config b/src/ServiceManagement/ServiceBus/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/ServiceBus/NuGet.Config +++ b/src/ServiceManagement/ServiceBus/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/SiteRecovery/NuGet.Config b/src/ServiceManagement/SiteRecovery/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/SiteRecovery/NuGet.Config +++ b/src/ServiceManagement/SiteRecovery/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/Sql/NuGet.Config b/src/ServiceManagement/Sql/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/Sql/NuGet.Config +++ b/src/ServiceManagement/Sql/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/StorSimple/NuGet.Config b/src/ServiceManagement/StorSimple/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/StorSimple/NuGet.Config +++ b/src/ServiceManagement/StorSimple/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/Storage/NuGet.Config b/src/ServiceManagement/Storage/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/Storage/NuGet.Config +++ b/src/ServiceManagement/Storage/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/Store/NuGet.Config b/src/ServiceManagement/Store/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/Store/NuGet.Config +++ b/src/ServiceManagement/Store/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/TrafficManager/NuGet.Config b/src/ServiceManagement/TrafficManager/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/TrafficManager/NuGet.Config +++ b/src/ServiceManagement/TrafficManager/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + diff --git a/src/ServiceManagement/WebSite/NuGet.Config b/src/ServiceManagement/WebSite/NuGet.Config index dcff8ff3ab0e..ffd4ee71e642 100644 --- a/src/ServiceManagement/WebSite/NuGet.Config +++ b/src/ServiceManagement/WebSite/NuGet.Config @@ -1,4 +1,6 @@  - - ..\..\..\packages - + + + + + From a0780a614e19a0197a01028a9e4016bcec203483 Mon Sep 17 00:00:00 2001 From: stankovski Date: Mon, 27 Jul 2015 14:40:36 -0700 Subject: [PATCH 2/2] Fixed Compute test --- .../Compute/Compute.Tests/ScenarioTests/AvailabilitySetTests.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ResourceManagement/Compute/Compute.Tests/ScenarioTests/AvailabilitySetTests.cs b/src/ResourceManagement/Compute/Compute.Tests/ScenarioTests/AvailabilitySetTests.cs index bb54c3a71a57..ed009b203f06 100644 --- a/src/ResourceManagement/Compute/Compute.Tests/ScenarioTests/AvailabilitySetTests.cs +++ b/src/ResourceManagement/Compute/Compute.Tests/ScenarioTests/AvailabilitySetTests.cs @@ -33,7 +33,7 @@ public class AvailabilitySetTests ComputeManagementClient computeClient; ResourceManagementClient resourcesClient; - ResourceGroupExtended resourceGroup; + ResourceGroup resourceGroup; string subId; string location;