Failover Groups - Update
Updates a failover group.
PATCH https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/failoverGroups/{failoverGroupName}?api-version={api-version}
URI Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
|
databaseName
|
path | True |
|
The name of the database. |
|
subscriptionId
|
path | True |
|
The subscription ID that identifies an Azure subscription. |
|
resourceGroupName
|
path | True |
|
The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal. |
|
serverName
|
path | True |
|
The name of the server containing the failover group. |
|
failoverGroupName
|
path | True |
|
The name of the failover group. |
|
api-version
|
query | True |
|
The API version to use for the request. |
Request Body
| Name | Required | Type | Description |
|---|---|---|---|
| databases |
|
List of databases in the failover group. |
|
| readOnlyEndpoint |
Read-only endpoint of the failover group instance. |
||
| readWriteEndpoint |
Read-write endpoint of the failover group instance. |
||
| tags |
|
Resource tags. |
Responses
| Name | Type | Description |
|---|---|---|
| 200 OK |
Successfully updated the failover group. |
|
| Other Status Codes |
*** Error Responses: ***
|
|
| 202 Accepted |
Accepted |
Examples
Update failover group
Sample Request
PATCH https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default/providers/Microsoft.Sql/servers/failover-group-primary-server/failoverGroups/failover-group-test-1?api-version=2015-05-01-preview
{
"properties": {
"readWriteEndpoint": {
"failoverPolicy": "Automatic",
"failoverWithDataLossGracePeriodMinutes": 120
},
"databases": [
"/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default/providers/Microsoft.Sql/servers/failover-group-primary-server/databases/testdb-1"
]
}
}
Sample Response
{
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default/providers/Microsoft.Sql/servers/failover-group-primary-server/failoverGroups/failover-group-test-3",
"name": "failover-group-test-3",
"type": "Microsoft.Sql/servers/failoverGroups",
"location": "Japan East",
"properties": {
"readWriteEndpoint": {
"failoverPolicy": "Automatic",
"failoverWithDataLossGracePeriodMinutes": 120
},
"readOnlyEndpoint": {
"failoverPolicy": "Disabled"
},
"replicationRole": "Primary",
"replicationState": "CATCH_UP",
"partnerServers": [
{
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default/providers/Microsoft.Sql/servers/failover-group-secondary-server",
"location": "Japan West",
"replicationRole": "Secondary"
}
],
"databases": [
"/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default/providers/Microsoft.Sql/servers/failover-group-primary-server/databases/testdb-1"
]
}
}
Definitions
| FailoverGroup | |
| FailoverGroupReadOnlyEndpoint |
Read-only endpoint of the failover group instance. |
| FailoverGroupReadWriteEndpoint |
Read-write endpoint of the failover group instance. |
| PartnerInfo |
Partner server information for the failover group. |
| Name | Type | Description |
|---|---|---|
| databases |
|
List of databases in the failover group. |
| location |
|
Resource location. |
| partnerServers |
List of partner server information for the failover group. |
|
| readOnlyEndpoint |
Read-only endpoint of the failover group instance. |
|
| readWriteEndpoint |
Read-write endpoint of the failover group instance. |
|
| replicationRole |
|
Local replication role of the failover group instance. |
| replicationState |
|
Replication state of the failover group instance. |
| tags |
|
Resource tags. |
Read-only endpoint of the failover group instance.
| Name | Type | Description |
|---|---|---|
| failoverPolicy |
|
Failover policy of the read-only endpoint for the failover group. |
Read-write endpoint of the failover group instance.
| Name | Type | Description |
|---|---|---|
| failoverPolicy |
|
Failover policy of the read-write endpoint for the failover group. If failoverPolicy is Automatic then failoverWithDataLossGracePeriodMinutes is required. |
| failoverWithDataLossGracePeriodMinutes |
|
Grace period before failover with data loss is attempted for the read-write endpoint. If failoverPolicy is Automatic then failoverWithDataLossGracePeriodMinutes is required. |
Partner server information for the failover group.
| Name | Type | Description |
|---|---|---|
| id |
|
Resource identifier of the partner server. |
| location |
|
Geo location of the partner server. |
| replicationRole |
|
Replication role of the partner server. |