forked from MicrosoftDocs/azure-rest-api-specs
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add examples for SQL Swagger (Azure#954)
* Added examples, minor changes based on examples validation * Added missing point in time restore related db properties and added pitr example. * updated descriptions of existing restore related db properties. * Specify x-ms-mutability for Server & DB properties * Add operations API to swagger docs
- Loading branch information
1 parent
78f08e4
commit 229323f
Showing
43 changed files
with
2,534 additions
and
70 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
{ | ||
"parameters": { | ||
"subscriptionId": "00000000-1111-2222-3333-444444444444", | ||
"resourceGroupName": "sqlcrudtest-4799", | ||
"serverName": "sqlcrudtest-6440", | ||
"databaseName": "testdb", | ||
"api-version": "2014-04-01", | ||
"parameters": { | ||
"location": "Japan East", | ||
"properties": { | ||
"createMode": "Copy", | ||
"sourceDatabaseId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/sqlcrudtest-4799/providers/Microsoft.Sql/servers/sqlcrudtest-3782/databases/testdb" | ||
} | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/sqlcrudtest-4799/providers/Microsoft.Sql/servers/sqlcrudtest-6440/databases/testdb", | ||
"name": "testdb", | ||
"type": "Microsoft.Sql/servers/databases", | ||
"location": "Japan East", | ||
"kind": "v12.0,user", | ||
"properties": { | ||
"edition": "Standard", | ||
"status": "Online", | ||
"serviceLevelObjective": "S0", | ||
"collation": "SQL_Latin1_General_CP1_CI_AS", | ||
"maxSizeBytes": "268435456000", | ||
"currentServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveName": "S0", | ||
"sampleName": null, | ||
"defaultSecondaryLocation": "Japan West", | ||
"earliestRestoreDate": "2017-02-10T01:52:52.923Z", | ||
"elasticPoolName": null, | ||
"containmentState": 2, | ||
"readScale": "Disabled", | ||
"failoverGroupId": null | ||
} | ||
} | ||
}, | ||
"201": { | ||
"body": { | ||
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/sqlcrudtest-4799/providers/Microsoft.Sql/servers/sqlcrudtest-6440/databases/testdb", | ||
"name": "testdb", | ||
"type": "Microsoft.Sql/servers/databases", | ||
"location": "Japan East", | ||
"kind": "v12.0,user", | ||
"properties": { | ||
"edition": "Standard", | ||
"status": "Online", | ||
"serviceLevelObjective": "S0", | ||
"collation": "SQL_Latin1_General_CP1_CI_AS", | ||
"maxSizeBytes": "268435456000", | ||
"currentServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveName": "S0", | ||
"sampleName": null, | ||
"defaultSecondaryLocation": "Japan West", | ||
"earliestRestoreDate": "2017-02-10T01:52:52.923Z", | ||
"elasticPoolName": null, | ||
"containmentState": 2, | ||
"readScale": "Disabled", | ||
"failoverGroupId": null | ||
} | ||
} | ||
}, | ||
"202": {} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
{ | ||
"parameters": { | ||
"subscriptionId": "00000000-1111-2222-3333-444444444444", | ||
"resourceGroupName": "sqlcrudtest-4799", | ||
"serverName": "sqlcrudtest-6440", | ||
"databaseName": "testdb", | ||
"api-version": "2014-04-01", | ||
"parameters": { | ||
"location": "Japan East", | ||
"properties": { | ||
"databaseId": "816c5f7e-0e36-4eec-9c51-eee7a276c14c", | ||
"edition": "Standard", | ||
"status": "Online", | ||
"createMode": "Default", | ||
"serviceLevelObjective": "S0", | ||
"collation": "SQL_Latin1_General_CP1_CI_AS", | ||
"maxSizeBytes": "268435456000", | ||
"creationDate": "2017-02-10T01:37:18.847Z", | ||
"currentServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveName": "S0", | ||
"defaultSecondaryLocation": "Japan West", | ||
"earliestRestoreDate": "2017-02-10T01:48:08.237Z", | ||
"containmentState": 2, | ||
"readScale": "Disabled", | ||
"sampleName": "AdventureWorksLT" | ||
} | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/sqlcrudtest-8931/providers/Microsoft.Sql/servers/sqlcrudtest-1932/databases/testdb", | ||
"name": "testdb", | ||
"type": "Microsoft.Sql/servers/databases", | ||
"location": "Japan East", | ||
"kind": "v12.0,user", | ||
"properties": { | ||
"databaseId": "816c5f7e-0e36-4eec-9c51-eee7a276c14c", | ||
"edition": "Standard", | ||
"status": "Online", | ||
"createMode": "Default", | ||
"serviceLevelObjective": "S0", | ||
"collation": "SQL_Latin1_General_CP1_CI_AS", | ||
"maxSizeBytes": "268435456000", | ||
"creationDate": "2017-02-10T01:37:18.847Z", | ||
"currentServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveName": "S0", | ||
"sampleName": null, | ||
"sourceDatabaseId": null, | ||
"defaultSecondaryLocation": "Japan West", | ||
"earliestRestoreDate": "2017-02-10T01:48:08.237Z", | ||
"elasticPoolName": null, | ||
"containmentState": 2, | ||
"readScale": "Disabled", | ||
"failoverGroupId": null | ||
} | ||
} | ||
}, | ||
"201": { | ||
"body": { | ||
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/sqlcrudtest-8931/providers/Microsoft.Sql/servers/sqlcrudtest-1932/databases/testdb", | ||
"name": "testdb", | ||
"type": "Microsoft.Sql/servers/databases", | ||
"location": "Japan East", | ||
"kind": "v12.0,user", | ||
"properties": { | ||
"databaseId": "816c5f7e-0e36-4eec-9c51-eee7a276c14c", | ||
"edition": "Standard", | ||
"status": "Online", | ||
"createMode": "Default", | ||
"serviceLevelObjective": "S0", | ||
"collation": "SQL_Latin1_General_CP1_CI_AS", | ||
"maxSizeBytes": "268435456000", | ||
"creationDate": "2017-02-10T01:37:18.847Z", | ||
"currentServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveName": "S0", | ||
"sampleName": null, | ||
"sourceDatabaseId": null, | ||
"defaultSecondaryLocation": "Japan West", | ||
"earliestRestoreDate": "2017-02-10T01:48:08.237Z", | ||
"elasticPoolName": null, | ||
"containmentState": 2, | ||
"readScale": "Disabled", | ||
"failoverGroupId": null | ||
} | ||
} | ||
}, | ||
"202": {} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
{ | ||
"parameters": { | ||
"subscriptionId": "00000000-1111-2222-3333-444444444444", | ||
"resourceGroupName": "sqlcrudtest-4799", | ||
"serverName": "sqlcrudtest-5961", | ||
"databaseName": "testdb", | ||
"api-version": "2014-04-01", | ||
"parameters": { | ||
"location": "Japan East" | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/sqlcrudtest-4799/providers/Microsoft.Sql/servers/sqlcrudtest-5961/databases/testdb", | ||
"name": "testdb", | ||
"type": "Microsoft.Sql/servers/databases", | ||
"location": "Japan East", | ||
"kind": "v12.0,user", | ||
"properties": { | ||
"edition": "Standard", | ||
"status": "Online", | ||
"serviceLevelObjective": "S0", | ||
"collation": "SQL_Latin1_General_CP1_CI_AS", | ||
"maxSizeBytes": "268435456000", | ||
"currentServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveName": "S0", | ||
"sampleName": null, | ||
"defaultSecondaryLocation": "Japan West", | ||
"earliestRestoreDate": "2017-02-10T01:52:52.923Z", | ||
"elasticPoolName": null, | ||
"containmentState": 2, | ||
"readScale": "Disabled", | ||
"failoverGroupId": null | ||
} | ||
} | ||
}, | ||
"201": { | ||
"body": { | ||
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/sqlcrudtest-4799/providers/Microsoft.Sql/servers/sqlcrudtest-5961/databases/testdb", | ||
"name": "testdb", | ||
"type": "Microsoft.Sql/servers/databases", | ||
"location": "Japan East", | ||
"kind": "v12.0,user", | ||
"properties": { | ||
"edition": "Standard", | ||
"status": "Online", | ||
"serviceLevelObjective": "S0", | ||
"collation": "SQL_Latin1_General_CP1_CI_AS", | ||
"maxSizeBytes": "268435456000", | ||
"currentServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveName": "S0", | ||
"sampleName": null, | ||
"defaultSecondaryLocation": "Japan West", | ||
"earliestRestoreDate": "2017-02-10T01:52:52.923Z", | ||
"elasticPoolName": null, | ||
"containmentState": 2, | ||
"readScale": "Disabled", | ||
"failoverGroupId": null | ||
} | ||
} | ||
}, | ||
"202": {} | ||
} | ||
} |
71 changes: 71 additions & 0 deletions
71
arm-sql/2014-04-01/examples/DatabaseCreateNonReadableSecondary.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
{ | ||
"parameters": { | ||
"subscriptionId": "00000000-1111-2222-3333-444444444444", | ||
"resourceGroupName": "sqlcrudtest-4799", | ||
"serverName": "sqlcrudtest-6440", | ||
"databaseName": "testdb", | ||
"api-version": "2014-04-01", | ||
"parameters": { | ||
"location": "Japan East", | ||
"properties": { | ||
"createMode": "NonReadableSecondary", | ||
"sourceDatabaseId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/sqlcrudtest-4799/providers/Microsoft.Sql/servers/sqlcrudtest-3782/databases/testdb" | ||
} | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/sqlcrudtest-4799/providers/Microsoft.Sql/servers/sqlcrudtest-6440/databases/testdb", | ||
"name": "testdb", | ||
"type": "Microsoft.Sql/servers/databases", | ||
"location": "Japan East", | ||
"kind": "v12.0,user", | ||
"properties": { | ||
"edition": "Standard", | ||
"status": "Online", | ||
"serviceLevelObjective": "S0", | ||
"collation": "SQL_Latin1_General_CP1_CI_AS", | ||
"maxSizeBytes": "268435456000", | ||
"currentServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveName": "S0", | ||
"sampleName": null, | ||
"defaultSecondaryLocation": "Japan West", | ||
"earliestRestoreDate": "2017-02-10T01:52:52.923Z", | ||
"elasticPoolName": null, | ||
"containmentState": 2, | ||
"readScale": "Disabled", | ||
"failoverGroupId": null | ||
} | ||
} | ||
}, | ||
"201": { | ||
"body": { | ||
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/sqlcrudtest-4799/providers/Microsoft.Sql/servers/sqlcrudtest-6440/databases/testdb", | ||
"name": "testdb", | ||
"type": "Microsoft.Sql/servers/databases", | ||
"location": "Japan East", | ||
"kind": "v12.0,user", | ||
"properties": { | ||
"edition": "Standard", | ||
"status": "Online", | ||
"serviceLevelObjective": "S0", | ||
"collation": "SQL_Latin1_General_CP1_CI_AS", | ||
"maxSizeBytes": "268435456000", | ||
"currentServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveName": "S0", | ||
"sampleName": null, | ||
"defaultSecondaryLocation": "Japan West", | ||
"earliestRestoreDate": "2017-02-10T01:52:52.923Z", | ||
"elasticPoolName": null, | ||
"containmentState": 2, | ||
"readScale": "Disabled", | ||
"failoverGroupId": null | ||
} | ||
} | ||
}, | ||
"202": {} | ||
} | ||
} |
71 changes: 71 additions & 0 deletions
71
arm-sql/2014-04-01/examples/DatabaseCreateOnlineSecondary.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
{ | ||
"parameters": { | ||
"subscriptionId": "00000000-1111-2222-3333-444444444444", | ||
"resourceGroupName": "sqlcrudtest-4799", | ||
"serverName": "sqlcrudtest-6440", | ||
"databaseName": "testdb", | ||
"api-version": "2014-04-01", | ||
"parameters": { | ||
"location": "Japan East", | ||
"properties": { | ||
"createMode": "OnlineSecondary", | ||
"sourceDatabaseId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/sqlcrudtest-4799/providers/Microsoft.Sql/servers/sqlcrudtest-3782/databases/testdb" | ||
} | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/sqlcrudtest-4799/providers/Microsoft.Sql/servers/sqlcrudtest-3782/databases/testdb", | ||
"name": "testdb", | ||
"type": "Microsoft.Sql/servers/databases", | ||
"location": "Japan East", | ||
"kind": "v12.0,user", | ||
"properties": { | ||
"edition": "Standard", | ||
"status": "Online", | ||
"serviceLevelObjective": "S0", | ||
"collation": "SQL_Latin1_General_CP1_CI_AS", | ||
"maxSizeBytes": "268435456000", | ||
"currentServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveName": "S0", | ||
"sampleName": null, | ||
"defaultSecondaryLocation": "Japan West", | ||
"earliestRestoreDate": "2017-02-10T01:52:52.923Z", | ||
"elasticPoolName": null, | ||
"containmentState": 2, | ||
"readScale": "Disabled", | ||
"failoverGroupId": null | ||
} | ||
} | ||
}, | ||
"201": { | ||
"body": { | ||
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/sqlcrudtest-4799/providers/Microsoft.Sql/servers/sqlcrudtest-3782/databases/testdb", | ||
"name": "testdb", | ||
"type": "Microsoft.Sql/servers/databases", | ||
"location": "Japan East", | ||
"kind": "v12.0,user", | ||
"properties": { | ||
"edition": "Standard", | ||
"status": "Online", | ||
"serviceLevelObjective": "S0", | ||
"collation": "SQL_Latin1_General_CP1_CI_AS", | ||
"maxSizeBytes": "268435456000", | ||
"currentServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveId": "f1173c43-91bd-4aaa-973c-54e79e15235b", | ||
"requestedServiceObjectiveName": "S0", | ||
"sampleName": null, | ||
"defaultSecondaryLocation": "Japan West", | ||
"earliestRestoreDate": "2017-02-10T01:52:52.923Z", | ||
"elasticPoolName": null, | ||
"containmentState": 2, | ||
"readScale": "Disabled", | ||
"failoverGroupId": null | ||
} | ||
} | ||
}, | ||
"202": {} | ||
} | ||
} |
Oops, something went wrong.