From d93f5ba7f828a56136ed9a540ee9e40d4949e106 Mon Sep 17 00:00:00 2001 From: pjohari-ms <84465928+pjohari-ms@users.noreply.github.com> Date: Tue, 16 Apr 2024 00:17:58 +0000 Subject: [PATCH 1/4] Distributed Query changes --- ...mosDBSqlDedicatedGatewayServiceCreate.json | 4 ++- ...mosDBSqlDedicatedGatewayServiceDelete.json | 0 ...CosmosDBSqlDedicatedGatewayServiceGet.json | 1 + .../stable/2024-05-15/services.json | 32 +++++++++++++++++-- 4 files changed, 33 insertions(+), 4 deletions(-) rename specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/{ => services/sqldedicatedgateway}/CosmosDBSqlDedicatedGatewayServiceCreate.json (89%) rename specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/{ => services/sqldedicatedgateway}/CosmosDBSqlDedicatedGatewayServiceDelete.json (100%) rename specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/{ => services/sqldedicatedgateway}/CosmosDBSqlDedicatedGatewayServiceGet.json (95%) diff --git a/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/CosmosDBSqlDedicatedGatewayServiceCreate.json b/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/services/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceCreate.json similarity index 89% rename from specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/CosmosDBSqlDedicatedGatewayServiceCreate.json rename to specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/services/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceCreate.json index 0e925a7c7f81..991d9639c3bd 100644 --- a/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/CosmosDBSqlDedicatedGatewayServiceCreate.json +++ b/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/services/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceCreate.json @@ -9,7 +9,8 @@ "properties": { "instanceSize": "Cosmos.D4s", "instanceCount": 1, - "serviceType": "SqlDedicatedGateway" + "serviceType": "SqlDedicatedGateway", + "dedicatedGatewayType": "IntegratedCache" } } }, @@ -26,6 +27,7 @@ "instanceSize": "Cosmos.D4s", "instanceCount": 1, "serviceType": "SqlDedicatedGateway", + "dedicatedGatewayType": "IntegratedCache", "sqlDedicatedGatewayEndpoint": "https://sqlDedicatedGateway.sqlx.cosmos.windows-int.net/", "locations": [ { diff --git a/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/CosmosDBSqlDedicatedGatewayServiceDelete.json b/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/services/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceDelete.json similarity index 100% rename from specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/CosmosDBSqlDedicatedGatewayServiceDelete.json rename to specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/services/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceDelete.json diff --git a/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/CosmosDBSqlDedicatedGatewayServiceGet.json b/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/services/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceGet.json similarity index 95% rename from specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/CosmosDBSqlDedicatedGatewayServiceGet.json rename to specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/services/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceGet.json index be559fb5a18f..9d5d1bff0ebd 100644 --- a/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/CosmosDBSqlDedicatedGatewayServiceGet.json +++ b/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/examples/services/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceGet.json @@ -18,6 +18,7 @@ "instanceSize": "Cosmos.D4s", "instanceCount": 1, "serviceType": "SqlDedicatedGateway", + "dedicatedGatewayType": "IntegratedCache", "sqlDedicatedGatewayEndpoint": "https://sqlDedicatedGateway.sqlx.cosmos.windows-int.net/", "locations": [ { diff --git a/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json b/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json index 2002f2c19659..aa16bfc516f8 100644 --- a/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json +++ b/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json @@ -89,7 +89,7 @@ "$ref": "./examples/CosmosDBDataTransferServiceCreate.json" }, "SqlDedicatedGatewayServiceCreate": { - "$ref": "./examples/CosmosDBSqlDedicatedGatewayServiceCreate.json" + "$ref": "./examples/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceCreate.json" }, "GraphAPIComputeServiceCreate": { "$ref": "./examples/CosmosDBGraphAPIComputeServiceCreate.json" @@ -170,7 +170,7 @@ "$ref": "./examples/CosmosDBGraphAPIComputeServiceGet.json" }, "SqlDedicatedGatewayServiceGet": { - "$ref": "./examples/CosmosDBSqlDedicatedGatewayServiceGet.json" + "$ref": "./examples/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceGet.json" }, "MaterializedViewsBuilderServiceGet": { "$ref": "./examples/CosmosDBMaterializedViewsBuilderServiceGet.json" @@ -222,7 +222,7 @@ "$ref": "./examples/CosmosDBDataTransferServiceDelete.json" }, "SqlDedicatedGatewayServiceDelete": { - "$ref": "./examples/CosmosDBSqlDedicatedGatewayServiceDelete.json" + "$ref": "./examples/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceDelete.json" }, "GraphAPIComputeServiceDelete": { "$ref": "./examples/CosmosDBGraphAPIComputeServiceDelete.json" @@ -402,6 +402,32 @@ } } }, + "SqlServiceResourceCreateUpdateParameters": { + "description": "Parameters for Create or Update Request for SqlDedicatedGatewayServiceResource", + "type": "object", + "allOf": [ + { + "$ref": "#/definitions/ServiceResourceProperties" + } + ], + "properties": { + "dedicatedGatewayType": { + "$ref": "#/definitions/SqlDedicatedGatewayType" + } + } + }, + "SqlDedicatedGatewayType": { + "type": "string", + "enum": [ + "IntegratedCache", + "DistributedQuery" + ], + "description": "DedicatedGatewayType for the service.", + "x-ms-enum": { + "modelAsString": true, + "name": "DedicatedGatewayType" + } + }, "SqlDedicatedGatewayServiceResource": { "description": "Describes the service response property for SqlDedicatedGateway.", "type": "object", From ac2a748c7ddf1cc0197887b55c071b87b8c951e1 Mon Sep 17 00:00:00 2001 From: pjohari-ms <84465928+pjohari-ms@users.noreply.github.com> Date: Tue, 16 Apr 2024 00:32:39 +0000 Subject: [PATCH 2/4] Nits --- .../Microsoft.DocumentDB/stable/2024-05-15/services.json | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json b/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json index aa16bfc516f8..12b55ba053d4 100644 --- a/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json +++ b/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json @@ -89,7 +89,7 @@ "$ref": "./examples/CosmosDBDataTransferServiceCreate.json" }, "SqlDedicatedGatewayServiceCreate": { - "$ref": "./examples/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceCreate.json" + "$ref": "./examples/services/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceCreate.json" }, "GraphAPIComputeServiceCreate": { "$ref": "./examples/CosmosDBGraphAPIComputeServiceCreate.json" @@ -170,7 +170,7 @@ "$ref": "./examples/CosmosDBGraphAPIComputeServiceGet.json" }, "SqlDedicatedGatewayServiceGet": { - "$ref": "./examples/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceGet.json" + "$ref": "./examples/services/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceGet.json" }, "MaterializedViewsBuilderServiceGet": { "$ref": "./examples/CosmosDBMaterializedViewsBuilderServiceGet.json" @@ -222,7 +222,7 @@ "$ref": "./examples/CosmosDBDataTransferServiceDelete.json" }, "SqlDedicatedGatewayServiceDelete": { - "$ref": "./examples/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceDelete.json" + "$ref": "./examples/services/sqldedicatedgateway/CosmosDBSqlDedicatedGatewayServiceDelete.json" }, "GraphAPIComputeServiceDelete": { "$ref": "./examples/CosmosDBGraphAPIComputeServiceDelete.json" @@ -412,7 +412,7 @@ ], "properties": { "dedicatedGatewayType": { - "$ref": "#/definitions/SqlDedicatedGatewayType" + "$ref": "#/definitions/SqlDedicatedGatewayType" } } }, From 14fcc9682a988e8b5f804f295c6502990e581a92 Mon Sep 17 00:00:00 2001 From: pjohari-ms <84465928+pjohari-ms@users.noreply.github.com> Date: Thu, 18 Apr 2024 20:59:02 +0000 Subject: [PATCH 3/4] Fixed model validation --- .../Microsoft.DocumentDB/stable/2024-05-15/services.json | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json b/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json index 12b55ba053d4..69e377bc4f22 100644 --- a/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json +++ b/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json @@ -328,6 +328,7 @@ "ServiceResourceCreateUpdateProperties": { "description": "Properties in ServiceResourceCreateUpdateParameters.", "type": "object", + "discriminator": "serviceType", "properties": { "instanceSize": { "$ref": "#/definitions/ServiceResourceInstanceSize" @@ -341,7 +342,10 @@ "serviceType": { "$ref": "#/definitions/ServiceType" } - } + }, + "required": [ + "serviceType" + ] }, "ServiceResource": { "description": "Properties for the database account.", @@ -405,6 +409,7 @@ "SqlServiceResourceCreateUpdateParameters": { "description": "Parameters for Create or Update Request for SqlDedicatedGatewayServiceResource", "type": "object", + "x-ms-discriminator-value": "SqlDedicatedGateway", "allOf": [ { "$ref": "#/definitions/ServiceResourceProperties" From e342e30f21f9985f7a995e97b8fc01373765d0d2 Mon Sep 17 00:00:00 2001 From: pjohari-ms <84465928+pjohari-ms@users.noreply.github.com> Date: Thu, 18 Apr 2024 21:14:15 +0000 Subject: [PATCH 4/4] More fixes --- .../stable/2024-05-15/services.json | 37 ++++++++++++++++++- 1 file changed, 35 insertions(+), 2 deletions(-) diff --git a/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json b/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json index 69e377bc4f22..fbea4e6d7370 100644 --- a/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json +++ b/specification/cosmos-db/resource-manager/Microsoft.DocumentDB/stable/2024-05-15/services.json @@ -406,13 +406,23 @@ } } }, - "SqlServiceResourceCreateUpdateParameters": { + "DataTransferServiceResourceCreateUpdateParameters": { + "description": "Parameters for Create or Update Request for SqlDedicatedGatewayServiceResource", + "type": "object", + "x-ms-discriminator-value": "DataTransfer", + "allOf": [ + { + "$ref": "#/definitions/ServiceResourceCreateUpdateProperties" + } + ] + }, + "SqlDedicatedGatewayServiceResourceCreateUpdateParameters": { "description": "Parameters for Create or Update Request for SqlDedicatedGatewayServiceResource", "type": "object", "x-ms-discriminator-value": "SqlDedicatedGateway", "allOf": [ { - "$ref": "#/definitions/ServiceResourceProperties" + "$ref": "#/definitions/ServiceResourceCreateUpdateProperties" } ], "properties": { @@ -457,6 +467,9 @@ "type": "string", "description": "SqlDedicatedGateway endpoint for the service." }, + "dedicatedGatewayType": { + "$ref": "#/definitions/SqlDedicatedGatewayType" + }, "locations": { "type": "array", "readOnly": true, @@ -501,6 +514,16 @@ } } }, + "GraphAPIComputeServiceResourceCreateUpdateParameters": { + "description": "Parameters for Create or Update Request for SqlDedicatedGatewayServiceResource", + "type": "object", + "x-ms-discriminator-value": "GraphAPICompute", + "allOf": [ + { + "$ref": "#/definitions/ServiceResourceCreateUpdateProperties" + } + ] + }, "MaterializedViewsBuilderServiceResource": { "description": "Describes the service response property for MaterializedViewsBuilder.", "type": "object", @@ -531,6 +554,16 @@ } } }, + "MaterializedViewsBuilderServiceResourceCreateUpdateParameters": { + "description": "Parameters for Create or Update Request for SqlDedicatedGatewayServiceResource", + "type": "object", + "x-ms-discriminator-value": "MaterializedViewsBuilder", + "allOf": [ + { + "$ref": "#/definitions/ServiceResourceCreateUpdateProperties" + } + ] + }, "RegionalServiceResource": { "description": "Resource for a regional service location.", "type": "object",