Skip to content

Commit

Permalink
Failover Database Readable Secondary (#7405)
Browse files Browse the repository at this point in the history
* Add swagger changes for failover databases and failover elastic pools

* Fixed api version for FailoverDatabases

* Add examples

* Add to read me

* Add swagger files for failover database readable secondaries

* Remove FailoverDatabaseReadableSecondary.json and include the extra parameter in FailoverDatabase.json instead
  • Loading branch information
emgu-ms authored and sergey-shandar committed Oct 29, 2019
1 parent b60da39 commit 5349a57
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,21 @@
"required": true,
"type": "string"
},
{
"name": "replicaType",
"in": "query",
"description": "The type of replica to be failed over.",
"required": false,
"type": "string",
"enum": [
"Primary",
"ReadableSecondary"
],
"x-ms-enum": {
"name": "ReplicaType",
"modelAsString": true
}
},
{
"$ref": "#/parameters/SubscriptionIdParameter"
},
Expand All @@ -49,7 +64,7 @@
"description": "Successfully completed database failover."
},
"default": {
"description": "*** Error Responses: ***\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 400 DatabaseFailoverThrottled - There was a recent failover on the database or pool if database belongs in an elastic pool.\n\n * 400 DatabaseFailoverNotSupported - This database type does not support customer initiated failovers.\n\n * 409 ManagementServiceDatabaseBusy - Database '{0}' is busy with another operation. Please try your operation later.\n\n * 409 DatabaseNotInStateToFailover - The database is currently in a state such that failover cannot be issued."
"description": "*** Error Responses: ***\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 400 DatabaseFailoverThrottled - There was a recent failover on the database or pool if database belongs in an elastic pool.\n\n * 400 DatabaseFailoverNotSupportedOnSKU - This type of customer initiated failover is not supported on the given SKU.\n\n * 409 ManagementServiceDatabaseBusy - Database '{0}' is busy with another operation. Please try your operation later.\n\n * 409 DatabaseNotInStateToFailover - The database is currently in a state such that failover cannot be issued."
},
"202": {
"description": "Database failover is in progress."
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
"description": "Successfully completed elastic pool failover."
},
"default": {
"description": "*** Error Responses: ***\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 400 ElasticPoolFailoverThrottled - There was a recent failover on the elastic pool.\n\n * 400 ElasticPoolFailoverNotSupported - This elastic pool type or a database type within the elastic pool does not support customer initiated failovers.\n\n * 409 ManagementServiceDatabaseBusy - Database '{0}' is busy with another operation. Please try your operation later.\n\n * 409 ElasticPoolNotInStateToFailover - The elastic pool or a database within the elastic pool is currently in a state such that failover cannot be issued."
"description": "*** Error Responses: ***\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 400 ElasticPoolFailoverThrottled - There was a recent failover on the elastic pool.\n\n * 400 ElasticPoolFailoverNotSupportedOnSKU - This type of customer initiated failover is not supported on the given SKU.\n\n * 409 ManagementServiceDatabaseBusy - Database '{0}' is busy with another operation. Please try your operation later.\n\n * 409 ElasticPoolNotInStateToFailover - The elastic pool or a database within the elastic pool is currently in a state such that failover cannot be issued."
},
"202": {
"description": "Elastic pool failover is in progress."
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"resourceGroupName": "group1",
"serverName": "testServer",
"databaseName": "testDatabase",
"replicaType": "Primary",
"api-version": "2018-06-01-preview"
},
"responses": {
Expand Down

0 comments on commit 5349a57

Please sign in to comment.