forked from Azure/azure-rest-api-specs
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rest API changes for SymsSync service (Azure#15695)
* Rest API changes for SymsSync service * fixing ci failures * correcting api version * addressing PR comments * addressing PR comments * fixing test failures * correcting the example file * changing description from resource to database * addressing PR comment for response type * Leave SymsSync only * Minor change * Add an empty line Co-authored-by: Kalyan Raman <kalyanr@microsoft.com> Co-authored-by: Dongwei Wang <dongwwa@microsoft.com>
- Loading branch information
1 parent
b49af80
commit a3787ca
Showing
7 changed files
with
396 additions
and
0 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
18 changes: 18 additions & 0 deletions
18
...se/data-plane/Microsoft.Synapse/preview/2021-07-01-preview/examples/Metastore_Delete.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,18 @@ | ||
{ | ||
"parameters": { | ||
"endpoint": "exampleWorkspace.dev.azuresynapse.net", | ||
"api-version": "2021-07-01-preview", | ||
"id": "testdatabase" | ||
}, | ||
"responses": { | ||
"204": {}, | ||
"default": { | ||
"body": { | ||
"error": { | ||
"code": "Error code", | ||
"message": "Error message" | ||
} | ||
} | ||
} | ||
} | ||
} |
22 changes: 22 additions & 0 deletions
22
...ne/Microsoft.Synapse/preview/2021-07-01-preview/examples/Metastore_GetResourceStatus.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,22 @@ | ||
{ | ||
"parameters": { | ||
"endpoint": "exampleWorkspace.dev.azuresynapse.net", | ||
"api-version": "2021-07-01-preview", | ||
"id": "testdatabase" | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"status": "Completed" | ||
} | ||
}, | ||
"default": { | ||
"body": { | ||
"error": { | ||
"code": "Error code", | ||
"message": "Error message" | ||
} | ||
} | ||
} | ||
} | ||
} |
25 changes: 25 additions & 0 deletions
25
.../data-plane/Microsoft.Synapse/preview/2021-07-01-preview/examples/Metastore_Register.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,25 @@ | ||
{ | ||
"parameters": { | ||
"endpoint": "exampleWorkspace.dev.azuresynapse.net", | ||
"api-version": "2021-07-01-preview", | ||
"id": "testdatabase", | ||
"registerBody": { | ||
"inputFolder": "https://testsymsstorage.dfs.core.windows.net/testsymscontainer/CDM/" | ||
} | ||
}, | ||
"responses": { | ||
"201": { | ||
"body": { | ||
"status": "Running" | ||
} | ||
}, | ||
"default": { | ||
"body": { | ||
"error": { | ||
"code": "Error code", | ||
"message": "Error message" | ||
} | ||
} | ||
} | ||
} | ||
} |
25 changes: 25 additions & 0 deletions
25
...se/data-plane/Microsoft.Synapse/preview/2021-07-01-preview/examples/Metastore_Update.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,25 @@ | ||
{ | ||
"parameters": { | ||
"endpoint": "exampleWorkspace.dev.azuresynapse.net", | ||
"api-version": "2021-07-01-preview", | ||
"id": "testdatabase", | ||
"updateBody": { | ||
"inputFolder": "https://testsymsstorage.dfs.core.windows.net/testsymscontainer/CDM/" | ||
} | ||
}, | ||
"responses": { | ||
"201": { | ||
"body": { | ||
"status": "Running" | ||
} | ||
}, | ||
"default": { | ||
"body": { | ||
"error": { | ||
"code": "Error code", | ||
"message": "Error message" | ||
} | ||
} | ||
} | ||
} | ||
} |
294 changes: 294 additions & 0 deletions
294
specification/synapse/data-plane/Microsoft.Synapse/preview/2021-07-01-preview/symsSync.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,294 @@ | ||
{ | ||
"swagger": "2.0", | ||
"info": { | ||
"version": "2021-07-01-preview", | ||
"title": "ArtifactsClient" | ||
}, | ||
"x-ms-parameterized-host": { | ||
"hostTemplate": "{endpoint}", | ||
"useSchemePrefix": false, | ||
"parameters": [ | ||
{ | ||
"$ref": "#/parameters/Endpoint" | ||
} | ||
] | ||
}, | ||
"schemes": [ | ||
"https" | ||
], | ||
"consumes": [ | ||
"application/json" | ||
], | ||
"produces": [ | ||
"application/json" | ||
], | ||
"paths": { | ||
"/metastore/create-database-operations/{id}": { | ||
"put": { | ||
"tags": [ | ||
"metastore" | ||
], | ||
"operationId": "Metastore_Register", | ||
"description": "Register files in Syms", | ||
"x-ms-examples": { | ||
"Register files in Syms": { | ||
"$ref": "./examples/Metastore_Register.json" | ||
} | ||
}, | ||
"parameters": [ | ||
{ | ||
"$ref": "#/parameters/ApiVersionParameter" | ||
}, | ||
{ | ||
"name": "id", | ||
"in": "path", | ||
"required": true, | ||
"type": "string", | ||
"description": "The name of the database to be created. The name can contain only alphanumeric characters and should not exceed 24 characters" | ||
}, | ||
{ | ||
"in": "body", | ||
"name": "registerBody", | ||
"required": true, | ||
"description": "The body for the register request", | ||
"schema": { | ||
"$ref": "#/definitions/metastoreRegisterObject" | ||
} | ||
} | ||
], | ||
"responses": { | ||
"201": { | ||
"description": "The Job created for the resource creation/updation request", | ||
"schema": { | ||
"$ref": "#/definitions/metastoreRegistrationResponse" | ||
} | ||
}, | ||
"default": { | ||
"description": "Error response describing why the operation failed.", | ||
"schema": { | ||
"$ref": "../../../../common/v1/types.json#/definitions/ErrorContract" | ||
} | ||
} | ||
} | ||
}, | ||
"get": { | ||
"tags": [ | ||
"metastore" | ||
], | ||
"operationId": "Metastore_GetDatabaseOperations", | ||
"description": "Gets status of the database", | ||
"x-ms-examples": { | ||
"Register files in Syms": { | ||
"$ref": "./examples/Metastore_GetResourceStatus.json" | ||
} | ||
}, | ||
"parameters": [ | ||
{ | ||
"$ref": "#/parameters/ApiVersionParameter" | ||
}, | ||
{ | ||
"in": "path", | ||
"name": "id", | ||
"required": true, | ||
"type": "string" | ||
} | ||
], | ||
"responses": { | ||
"200": { | ||
"description": "Request Success Response.", | ||
"schema": { | ||
"$ref": "#/definitions/metastoreRequestSuccessResponse" | ||
} | ||
}, | ||
"default": { | ||
"description": "Error response describing why the operation failed.", | ||
"schema": { | ||
"$ref": "../../../../common/v1/types.json#/definitions/ErrorContract" | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"/metastore/update-database-operations/{id}": { | ||
"put": { | ||
"tags": [ | ||
"metastore" | ||
], | ||
"operationId": "Metastore_Update", | ||
"description": "Update files in Syms", | ||
"x-ms-examples": { | ||
"Register files in Syms": { | ||
"$ref": "./examples/Metastore_Update.json" | ||
} | ||
}, | ||
"parameters": [ | ||
{ | ||
"$ref": "#/parameters/ApiVersionParameter" | ||
}, | ||
{ | ||
"name": "id", | ||
"in": "path", | ||
"required": true, | ||
"type": "string", | ||
"description": "The name of the database to be updated" | ||
}, | ||
{ | ||
"in": "body", | ||
"name": "updateBody", | ||
"required": true, | ||
"description": "The body for the update request", | ||
"schema": { | ||
"$ref": "#/definitions/metastoreUpdateObject" | ||
} | ||
} | ||
], | ||
"responses": { | ||
"201": { | ||
"description": "The Job created for the resource creation/updation request", | ||
"schema": { | ||
"$ref": "#/definitions/metastoreUpdationResponse" | ||
} | ||
}, | ||
"default": { | ||
"description": "Error response describing why the operation failed.", | ||
"schema": { | ||
"$ref": "../../../../common/v1/types.json#/definitions/ErrorContract" | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"/metastore/databases/{id}": { | ||
"delete": { | ||
"tags": [ | ||
"metastore" | ||
], | ||
"operationId": "Metastore_Delete", | ||
"description": "Remove files in Syms", | ||
"x-ms-examples": { | ||
"Register files in Syms": { | ||
"$ref": "./examples/Metastore_Delete.json" | ||
} | ||
}, | ||
"parameters": [ | ||
{ | ||
"$ref": "#/parameters/ApiVersionParameter" | ||
}, | ||
{ | ||
"in": "path", | ||
"name": "id", | ||
"required": true, | ||
"type": "string" | ||
} | ||
], | ||
"responses": { | ||
"204": { | ||
"description": "The Job created for the resource Deletion request" | ||
}, | ||
"default": { | ||
"description": "Error response describing why the operation failed.", | ||
"schema": { | ||
"$ref": "../../../../common/v1/types.json#/definitions/ErrorContract" | ||
} | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"definitions": { | ||
"metastoreRegistrationResponse": { | ||
"type": "object", | ||
"properties": { | ||
"status": { | ||
"$ref": "#/definitions/RequestStatus" | ||
} | ||
} | ||
}, | ||
"metastoreUpdationResponse": { | ||
"type": "object", | ||
"properties": { | ||
"status": { | ||
"$ref": "#/definitions/RequestStatus" | ||
} | ||
} | ||
}, | ||
"metastoreRequestSuccessResponse": { | ||
"type": "object", | ||
"properties": { | ||
"status": { | ||
"$ref": "#/definitions/ResourceStatus" | ||
} | ||
} | ||
}, | ||
"ResourceStatus": { | ||
"description": "Enumerates possible Status of the resource.", | ||
"type": "string", | ||
"enum": [ | ||
"Creating", | ||
"Created", | ||
"Failed" | ||
], | ||
"x-ms-enum": { | ||
"name": "ResourceStatus", | ||
"modelAsString": true | ||
} | ||
}, | ||
"RequestStatus": { | ||
"description": "Enumerates possible request statuses.", | ||
"type": "string", | ||
"enum": [ | ||
"Running", | ||
"Completed", | ||
"Failed" | ||
], | ||
"x-ms-enum": { | ||
"name": "RequestStatus", | ||
"modelAsString": true | ||
} | ||
}, | ||
"metastoreRegisterObject": { | ||
"type": "object", | ||
"required": [ | ||
"inputFolder" | ||
], | ||
"properties": { | ||
"inputFolder": { | ||
"type": "string", | ||
"example": "https://testsymsstorage.blob.core.windows.net/testsymsstoragefilesystem/CDM/", | ||
"description": "The input folder containing CDM files." | ||
} | ||
} | ||
}, | ||
"metastoreUpdateObject": { | ||
"type": "object", | ||
"required": [ | ||
"inputFolder" | ||
], | ||
"properties": { | ||
"inputFolder": { | ||
"type": "string", | ||
"example": "https://testsymsstorage.blob.core.windows.net/testsymsstoragefilesystem/CDM/", | ||
"description": "The input folder containing CDM files." | ||
} | ||
} | ||
} | ||
}, | ||
"parameters": { | ||
"ApiVersionParameter": { | ||
"name": "api-version", | ||
"in": "query", | ||
"required": true, | ||
"type": "string", | ||
"description": "The Synapse client API Version." | ||
}, | ||
"Endpoint": { | ||
"name": "endpoint", | ||
"description": "The workspace development endpoint, for example https://myworkspace.dev.azuresynapse.net.", | ||
"required": true, | ||
"type": "string", | ||
"in": "path", | ||
"x-ms-skip-url-encoding": true, | ||
"x-ms-parameter-location": "client" | ||
} | ||
} | ||
} |
Oops, something went wrong.