Skip to content

Commit

Permalink
[ACR] Add patch for replications (Azure#1586)
Browse files Browse the repository at this point in the history
  • Loading branch information
djyou authored and dsgouda committed Aug 24, 2017
1 parent dab840e commit 31d65bd
Show file tree
Hide file tree
Showing 4 changed files with 164 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -240,13 +240,20 @@
"schema": {
"$ref": "#/definitions/Registry"
}
},
"201": {
"description": "The request was successful; the operation will complete asynchronously.",
"schema": {
"$ref": "#/definitions/Registry"
}
}
},
"x-ms-examples": {
"RegistryUpdate": {
"$ref": "./examples/RegistryUpdate.json"
}
}
},
"x-ms-long-running-operation": true
}
},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries": {
Expand Down Expand Up @@ -477,8 +484,8 @@
"tags": [
"Replications"
],
"description": "Creates or updates a replication for a container registry with the specified parameters.",
"operationId": "Replications_CreateOrUpdate",
"description": "Creates a replication for a container registry with the specified parameters.",
"operationId": "Replications_Create",
"parameters": [
{
"$ref": "#/parameters/ApiVersionParameter"
Expand All @@ -498,7 +505,7 @@
{
"name": "replication",
"in": "body",
"description": "The parameters for creating or updating a replication.",
"description": "The parameters for creating a replication.",
"required": true,
"schema": {
"$ref": "#/definitions/Replication"
Expand All @@ -520,8 +527,8 @@
}
},
"x-ms-examples": {
"ReplicationCreateOrUpdate": {
"$ref": "./examples/ReplicationCreateOrUpdate.json"
"ReplicationCreate": {
"$ref": "./examples/ReplicationCreate.json"
}
},
"x-ms-long-running-operation": true
Expand Down Expand Up @@ -566,6 +573,59 @@
}
},
"x-ms-long-running-operation": true
},
"patch": {
"tags": [
"Replications"
],
"description": "Updates a replication for a container registry with the specified parameters.",
"operationId": "Replications_Update",
"parameters": [
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"$ref": "#/parameters/SubscriptionIdParameter"
},
{
"$ref": "#/parameters/ResourceGroupParameter"
},
{
"$ref": "#/parameters/RegistryNameParameter"
},
{
"$ref": "#/parameters/ReplicationNameParameter"
},
{
"name": "replicationUpdateParameters",
"in": "body",
"description": "The parameters for updating a replication.",
"required": true,
"schema": {
"$ref": "#/definitions/ReplicationUpdateParameters"
}
}
],
"responses": {
"200": {
"description": "The request was successful; the request was well-formed and received properly.",
"schema": {
"$ref": "#/definitions/Replication"
}
},
"201": {
"description": "The request was successful; the operation will complete asynchronously.",
"schema": {
"$ref": "#/definitions/Replication"
}
}
},
"x-ms-examples": {
"ReplicationUpdate": {
"$ref": "./examples/ReplicationUpdate.json"
}
},
"x-ms-long-running-operation": true
}
},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/replications": {
Expand Down Expand Up @@ -1377,6 +1437,18 @@
}
}
},
"ReplicationUpdateParameters": {
"description": "The parameters for updating a replication.",
"properties": {
"tags": {
"description": "The tags for the replication.",
"type": "object",
"additionalProperties": {
"type": "string"
}
}
}
},
"ReplicationListResult": {
"description": "The result of a request to list replications for a container registry.",
"properties": {
Expand Down Expand Up @@ -1876,7 +1948,11 @@
},
"location": {
"description": "The location of the resource. This cannot be changed after the resource is created.",
"type": "string"
"type": "string",
"x-ms-mutability": [
"read",
"create"
]
},
"tags": {
"description": "The tags of the resource.",
Expand Down Expand Up @@ -1964,4 +2040,4 @@
]
}
]
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,32 @@
"adminUserEnabled": true
}
}
},
"201": {
"body": {
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.ContainerRegistry/registries/myRegistry",
"name": "myRegistry",
"type": "Microsoft.ContainerRegistry/registries",
"location": "westus",
"tags": {
"key": "value"
},
"sku": {
"name": "Managed_Standard",
"tier": "Managed"
},
"properties": {
"loginServer": "myregistry.azurecr.io",
"creationDate": "2017-03-01T23:14:37.0707808Z",
"provisioningState": "Updating",
"status": {
"displayStatus": "Provisioning",
"message": "The registry is provisioning.",
"timestamp": "2017-03-01T23:15:37.0707808Z"
},
"adminUserEnabled": true
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
{
"parameters": {
"api-version": "2017-06-01-preview",
"subscriptionId": "00000000-0000-0000-0000-000000000000",
"resourceGroupName": "myResourceGroup",
"registryName": "myRegistry",
"replicationName": "myReplication",
"replicationUpdateParameters": {
"tags": {
"key": "value"
}
}
},
"responses": {
"200": {
"body": {
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.ContainerRegistry/registries/myRegistry/replications/myReplication",
"name": "myReplication",
"type": "Microsoft.ContainerRegistry/registries/replications",
"location": "eastus",
"tags": {
"key": "value"
},
"properties": {
"provisioningState": "Succeeded",
"status": {
"displayStatus": "Ready",
"message": "The replication is ready.",
"timestamp": "2017-03-01T23:15:37.0707808Z"
}
}
}
},
"201": {
"body": {
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.ContainerRegistry/registries/myRegistry/replications/myReplication",
"name": "myReplication",
"type": "Microsoft.ContainerRegistry/registries/replications",
"location": "eastus",
"tags": {
"key": "value"
},
"properties": {
"provisioningState": "Updating",
"status": {
"displayStatus": "Provisioning",
"message": "The replication is provisioning.",
"timestamp": "2017-03-01T23:15:37.0707808Z"
}
}
}
}
}
}

0 comments on commit 31d65bd

Please sign in to comment.