diff --git a/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/DaprComponents.json b/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/DaprComponents.json index 4e5f5f8b3124..052cd51328fb 100644 --- a/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/DaprComponents.json +++ b/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/DaprComponents.json @@ -230,6 +230,58 @@ } }, "x-ms-long-running-operation": false + }, + "patch": { + "tags": [ + "DaprComponents" + ], + "summary": "Update Dapr Component's properties.", + "description": "Patches a Dapr Component. Only patching of tags is supported currently", + "operationId": "DaprComponents_Update", + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ResourceGroupNameParameter" + }, + { + "name": "environmentName", + "in": "path", + "description": "Name of the Managed Environment.", + "required": true, + "type": "string" + }, + { + "name": "name", + "in": "path", + "description": "Name of the Dapr Component.", + "required": true, + "type": "string" + }, + { + "$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/DaprComponent" + } + }, + "default": { + "description": "Common error response.", + "schema": { + "$ref": "./CommonDefinitions.json#/definitions/DefaultErrorResponse" + } + } + }, + "x-ms-examples": { + "Patch Dapr Component": { + "$ref": "./examples/DaprComponents_Patch.json" + } + } } } }, @@ -260,7 +312,7 @@ "type": "object", "allOf": [ { - "$ref": "../../../../../common-types/resource-management/v3/types.json#/definitions/ProxyResource" + "$ref": "../../../../../common-types/resource-management/v3/types.json#/definitions/TrackedResource" } ], "properties": { diff --git a/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_CreateOrUpdate.json b/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_CreateOrUpdate.json index c09192bf024f..00a2dd1f8c8a 100644 --- a/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_CreateOrUpdate.json +++ b/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_CreateOrUpdate.json @@ -6,6 +6,7 @@ "name": "reddog", "api-version": "2022-01-01-preview", "daprComponentEnvelope": { + "location": "East US", "properties": { "componentType": "state.azure.cosmosdb", "version": "v1", @@ -47,6 +48,7 @@ "body": { "id": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/jlaw-demo1/daprcomponents/reddog", "name": "reddog", + "location": "East US", "type": "Microsoft.App/managedEnvironments/daprcomponents", "properties": { "componentType": "state.azure.cosmosdb", diff --git a/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_Get.json b/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_Get.json index f9ed1449c963..917e5c3c68e4 100644 --- a/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_Get.json +++ b/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_Get.json @@ -12,6 +12,7 @@ "id": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/jlaw-demo1/daprcomponents/reddog", "name": "reddog", "type": "Microsoft.App/managedEnvironments/daprcomponents", + "location": "East US", "properties": { "componentType": "state.azure.cosmosdb", "version": "v1", diff --git a/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_List.json b/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_List.json index ed1b8068ca8c..b352b96ebc1d 100644 --- a/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_List.json +++ b/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_List.json @@ -13,6 +13,7 @@ "id": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/myenvironment/daprcomponents/reddog", "name": "reddog", "type": "Microsoft.App/managedEnvironments/daprcomponents", + "location": "East US", "properties": { "componentType": "state.azure.cosmosdb", "version": "v1", diff --git a/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_Patch.json b/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_Patch.json new file mode 100644 index 000000000000..d33ce656222c --- /dev/null +++ b/specification/app/resource-manager/Microsoft.App/preview/2022-01-01-preview/examples/DaprComponents_Patch.json @@ -0,0 +1,62 @@ +{ + "parameters": { + "subscriptionId": "8efdecc5-919e-44eb-b179-915dca89ebf9", + "resourceGroupName": "examplerg", + "environmentName": "myenvironment", + "name": "reddog", + "api-version": "2022-01-01-preview", + "daprComponentEnvelope": { + "tags": { + "tag1": "value1", + "tag2": "value2" + } + } + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.App/managedEnvironments/jlaw-demo1/daprcomponents/reddog", + "name": "reddog", + "location": "East US", + "type": "Microsoft.App/managedEnvironments/daprcomponents", + "tags": { + "tag1": "value1", + "tag2": "value2" + }, + "properties": { + "componentType": "state.azure.cosmosdb", + "version": "v1", + "ignoreErrors": false, + "initTimeout": "50s", + "secrets": [ + { + "name": "masterkey" + } + ], + "metadata": [ + { + "name": "url", + "value": "" + }, + { + "name": "database", + "value": "itemsDB" + }, + { + "name": "collection", + "value": "items" + }, + { + "name": "masterkey", + "secretRef": "masterkey" + } + ], + "scopes": [ + "container-app-1", + "container-app-2" + ] + } + } + } + } +}