From a851b6406a091ef6566f3125acc75c15cb62a326 Mon Sep 17 00:00:00 2001 From: zman-ms <99997769+zman-ms@users.noreply.github.com> Date: Mon, 12 Feb 2024 13:59:38 -0800 Subject: [PATCH] sync to async (#27745) --- .../2024-02-02-preview/UpdateRuns_Skip.json | 6 ++++++ .../Fleet.Management/update/run.tsp | 2 +- .../examples/UpdateRuns_Skip.json | 6 ++++++ .../preview/2024-02-02-preview/fleets.json | 20 ++++++++++++++++++- 4 files changed, 32 insertions(+), 2 deletions(-) diff --git a/specification/containerservice/Fleet.Management/examples/2024-02-02-preview/UpdateRuns_Skip.json b/specification/containerservice/Fleet.Management/examples/2024-02-02-preview/UpdateRuns_Skip.json index 922e925316c4..bc0d38cb8f45 100644 --- a/specification/containerservice/Fleet.Management/examples/2024-02-02-preview/UpdateRuns_Skip.json +++ b/specification/containerservice/Fleet.Management/examples/2024-02-02-preview/UpdateRuns_Skip.json @@ -119,6 +119,12 @@ }, "eTag": "\"EtagValue\"" } + }, + "202": { + "headers": { + "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.ContainerService/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000?api-version=2022-02-01", + "Location": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.ContainerService/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000?api-version=2022-02-01" + } } } } diff --git a/specification/containerservice/Fleet.Management/update/run.tsp b/specification/containerservice/Fleet.Management/update/run.tsp index ee8fa3723b34..d530205dc42c 100644 --- a/specification/containerservice/Fleet.Management/update/run.tsp +++ b/specification/containerservice/Fleet.Management/update/run.tsp @@ -365,7 +365,7 @@ interface UpdateRuns { @doc("Skips one or a combination of member/group/stage/afterStageWait(s) of an update run.") @added(Versions.v2024_02_02_preview) - skip is ArmResourceActionSync< + skip is ArmResourceActionAsync< UpdateRun, SkipProperties, UpdateRun, diff --git a/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-02-02-preview/examples/UpdateRuns_Skip.json b/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-02-02-preview/examples/UpdateRuns_Skip.json index 922e925316c4..bc0d38cb8f45 100644 --- a/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-02-02-preview/examples/UpdateRuns_Skip.json +++ b/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-02-02-preview/examples/UpdateRuns_Skip.json @@ -119,6 +119,12 @@ }, "eTag": "\"EtagValue\"" } + }, + "202": { + "headers": { + "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.ContainerService/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000?api-version=2022-02-01", + "Location": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.ContainerService/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000?api-version=2022-02-01" + } } } } diff --git a/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-02-02-preview/fleets.json b/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-02-02-preview/fleets.json index cf6e6e9b4ad6..09255ced71a3 100644 --- a/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-02-02-preview/fleets.json +++ b/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-02-02-preview/fleets.json @@ -1255,6 +1255,20 @@ "$ref": "#/definitions/UpdateRun" } }, + "202": { + "description": "Resource operation accepted.", + "headers": { + "Retry-After": { + "type": "integer", + "format": "int32", + "description": "The Retry-After header can indicate how long the client should wait before polling the operation status." + }, + "Location": { + "type": "string", + "description": "The Location header contains the URL where the status of the long running operation can be checked." + } + } + }, "default": { "description": "An unexpected error response.", "schema": { @@ -1266,7 +1280,11 @@ "Skips one or more member/group/stage/afterStageWait(s) of an UpdateRun.": { "$ref": "./examples/UpdateRuns_Skip.json" } - } + }, + "x-ms-long-running-operation-options": { + "final-state-via": "location" + }, + "x-ms-long-running-operation": true } }, "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/fleets/{fleetName}/updateRuns/{updateRunName}/start": {