Skip to content

Commit 0b33b0b

Browse files
jaredmoomarstr
authored andcommitted
Use common Resource & Sku definitions in all Sql specs (#3134)
* Use common Resource & Sku definitions * Don't use common Sku definition * Just use common SQL definitions * Fixed syntax error * Fixed another syntax error * Fixed sku ref error * Fixed syntax error in example
1 parent a4385b9 commit 0b33b0b

File tree

61 files changed

+240
-2542
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

61 files changed

+240
-2542
lines changed

specification/sql/resource-manager/Microsoft.Sql/preview/2015-05-01-preview/advisors.json

Lines changed: 2 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -486,38 +486,6 @@
486486
}
487487
},
488488
"definitions": {
489-
"Resource": {
490-
"description": "ARM resource.",
491-
"type": "object",
492-
"properties": {
493-
"id": {
494-
"description": "Resource ID.",
495-
"type": "string",
496-
"readOnly": true
497-
},
498-
"name": {
499-
"description": "Resource name.",
500-
"type": "string",
501-
"readOnly": true
502-
},
503-
"type": {
504-
"description": "Resource type.",
505-
"type": "string",
506-
"readOnly": true
507-
}
508-
},
509-
"x-ms-azure-resource": true
510-
},
511-
"ProxyResource": {
512-
"description": "ARM proxy resource.",
513-
"type": "object",
514-
"allOf": [
515-
{
516-
"$ref": "#/definitions/Resource"
517-
}
518-
],
519-
"properties": {}
520-
},
521489
"AdvisorProperties": {
522490
"description": "Properties for a Database, Server or Elastic Pool Advisor.",
523491
"required": [
@@ -923,7 +891,7 @@
923891
"type": "object",
924892
"allOf": [
925893
{
926-
"$ref": "#/definitions/ProxyResource"
894+
"$ref": "../../../common/v1/types.json#/definitions/ProxyResource"
927895
}
928896
],
929897
"properties": {
@@ -949,7 +917,7 @@
949917
"type": "object",
950918
"allOf": [
951919
{
952-
"$ref": "#/definitions/ProxyResource"
920+
"$ref": "../../../common/v1/types.json#/definitions/ProxyResource"
953921
}
954922
],
955923
"properties": {

specification/sql/resource-manager/Microsoft.Sql/preview/2015-05-01-preview/blobAuditingPolicies.json

Lines changed: 1 addition & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -208,44 +208,12 @@
208208
}
209209
}
210210
},
211-
"Resource": {
212-
"description": "ARM resource.",
213-
"type": "object",
214-
"properties": {
215-
"id": {
216-
"description": "Resource ID.",
217-
"type": "string",
218-
"readOnly": true
219-
},
220-
"name": {
221-
"description": "Resource name.",
222-
"type": "string",
223-
"readOnly": true
224-
},
225-
"type": {
226-
"description": "Resource type.",
227-
"type": "string",
228-
"readOnly": true
229-
}
230-
},
231-
"x-ms-azure-resource": true
232-
},
233-
"ProxyResource": {
234-
"description": "ARM proxy resource.",
235-
"type": "object",
236-
"allOf": [
237-
{
238-
"$ref": "#/definitions/Resource"
239-
}
240-
],
241-
"properties": {}
242-
},
243211
"DatabaseBlobAuditingPolicy": {
244212
"description": "A database blob auditing policy.",
245213
"type": "object",
246214
"allOf": [
247215
{
248-
"$ref": "#/definitions/ProxyResource"
216+
"$ref": "../../../common/v1/types.json#/definitions/ProxyResource"
249217
}
250218
],
251219
"properties": {

specification/sql/resource-manager/Microsoft.Sql/preview/2015-05-01-preview/databaseAutomaticTuning.json

Lines changed: 1 addition & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -210,44 +210,12 @@
210210
}
211211
}
212212
},
213-
"Resource": {
214-
"description": "ARM resource.",
215-
"type": "object",
216-
"properties": {
217-
"id": {
218-
"description": "Resource ID.",
219-
"type": "string",
220-
"readOnly": true
221-
},
222-
"name": {
223-
"description": "Resource name.",
224-
"type": "string",
225-
"readOnly": true
226-
},
227-
"type": {
228-
"description": "Resource type.",
229-
"type": "string",
230-
"readOnly": true
231-
}
232-
},
233-
"x-ms-azure-resource": true
234-
},
235-
"ProxyResource": {
236-
"description": "ARM proxy resource.",
237-
"type": "object",
238-
"allOf": [
239-
{
240-
"$ref": "#/definitions/Resource"
241-
}
242-
],
243-
"properties": {}
244-
},
245213
"DatabaseAutomaticTuning": {
246214
"description": "Database-level Automatic Tuning.",
247215
"type": "object",
248216
"allOf": [
249217
{
250-
"$ref": "#/definitions/ProxyResource"
218+
"$ref": "../../../common/v1/types.json#/definitions/ProxyResource"
251219
}
252220
],
253221
"properties": {

specification/sql/resource-manager/Microsoft.Sql/preview/2015-05-01-preview/encryptionProtectors.json

Lines changed: 1 addition & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -239,44 +239,12 @@
239239
}
240240
}
241241
},
242-
"Resource": {
243-
"description": "ARM resource.",
244-
"type": "object",
245-
"properties": {
246-
"id": {
247-
"description": "Resource ID.",
248-
"type": "string",
249-
"readOnly": true
250-
},
251-
"name": {
252-
"description": "Resource name.",
253-
"type": "string",
254-
"readOnly": true
255-
},
256-
"type": {
257-
"description": "Resource type.",
258-
"type": "string",
259-
"readOnly": true
260-
}
261-
},
262-
"x-ms-azure-resource": true
263-
},
264-
"ProxyResource": {
265-
"description": "ARM proxy resource.",
266-
"type": "object",
267-
"allOf": [
268-
{
269-
"$ref": "#/definitions/Resource"
270-
}
271-
],
272-
"properties": {}
273-
},
274242
"EncryptionProtector": {
275243
"description": "The server encryption protector.",
276244
"type": "object",
277245
"allOf": [
278246
{
279-
"$ref": "#/definitions/ProxyResource"
247+
"$ref": "../../../common/v1/types.json#/definitions/ProxyResource"
280248
}
281249
],
282250
"properties": {

specification/sql/resource-manager/Microsoft.Sql/preview/2015-05-01-preview/failoverGroups.json

Lines changed: 1 addition & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -531,44 +531,12 @@
531531
}
532532
}
533533
},
534-
"Resource": {
535-
"description": "ARM resource.",
536-
"type": "object",
537-
"properties": {
538-
"id": {
539-
"description": "Resource ID.",
540-
"type": "string",
541-
"readOnly": true
542-
},
543-
"name": {
544-
"description": "Resource name.",
545-
"type": "string",
546-
"readOnly": true
547-
},
548-
"type": {
549-
"description": "Resource type.",
550-
"type": "string",
551-
"readOnly": true
552-
}
553-
},
554-
"x-ms-azure-resource": true
555-
},
556-
"ProxyResource": {
557-
"description": "ARM proxy resource.",
558-
"type": "object",
559-
"allOf": [
560-
{
561-
"$ref": "#/definitions/Resource"
562-
}
563-
],
564-
"properties": {}
565-
},
566534
"FailoverGroup": {
567535
"description": "A failover group.",
568536
"type": "object",
569537
"allOf": [
570538
{
571-
"$ref": "#/definitions/ProxyResource"
539+
"$ref": "../../../common/v1/types.json#/definitions/ProxyResource"
572540
}
573541
],
574542
"properties": {

specification/sql/resource-manager/Microsoft.Sql/preview/2015-05-01-preview/managedInstances.json

Lines changed: 4 additions & 114 deletions
Original file line numberDiff line numberDiff line change
@@ -304,65 +304,6 @@
304304
}
305305
}
306306
},
307-
"ResourceIdentity": {
308-
"description": "Azure Active Directory identity configuration for a resource.",
309-
"type": "object",
310-
"properties": {
311-
"principalId": {
312-
"format": "uuid",
313-
"description": "The Azure Active Directory principal id.",
314-
"type": "string",
315-
"readOnly": true
316-
},
317-
"type": {
318-
"description": "The identity type. Set this to 'SystemAssigned' in order to automatically create and assign an Azure Active Directory principal for the resource.",
319-
"enum": [
320-
"SystemAssigned"
321-
],
322-
"type": "string",
323-
"x-ms-enum": {
324-
"name": "IdentityType",
325-
"modelAsString": true
326-
}
327-
},
328-
"tenantId": {
329-
"format": "uuid",
330-
"description": "The Azure Active Directory tenant id.",
331-
"type": "string",
332-
"readOnly": true
333-
}
334-
}
335-
},
336-
"Sku": {
337-
"description": "An ARM Resource SKU.",
338-
"required": [
339-
"name"
340-
],
341-
"type": "object",
342-
"properties": {
343-
"name": {
344-
"description": "The name of the SKU, typically, a letter + Number code, e.g. P3.",
345-
"type": "string"
346-
},
347-
"tier": {
348-
"description": "The tier of the particular SKU, e.g. Basic, Premium.",
349-
"type": "string"
350-
},
351-
"size": {
352-
"description": "Size of the particular SKU",
353-
"type": "string"
354-
},
355-
"family": {
356-
"description": "If the service has different generations of hardware, for the same SKU, then that can be captured here.",
357-
"type": "string"
358-
},
359-
"capacity": {
360-
"format": "int32",
361-
"description": "Capacity of the particular SKU.",
362-
"type": "integer"
363-
}
364-
}
365-
},
366307
"ManagedInstanceProperties": {
367308
"description": "The properties of a managed instance.",
368309
"type": "object",
@@ -413,57 +354,6 @@
413354
}
414355
}
415356
},
416-
"Resource": {
417-
"description": "ARM resource.",
418-
"type": "object",
419-
"properties": {
420-
"id": {
421-
"description": "Resource ID.",
422-
"type": "string",
423-
"readOnly": true
424-
},
425-
"name": {
426-
"description": "Resource name.",
427-
"type": "string",
428-
"readOnly": true
429-
},
430-
"type": {
431-
"description": "Resource type.",
432-
"type": "string",
433-
"readOnly": true
434-
}
435-
},
436-
"x-ms-azure-resource": true
437-
},
438-
"TrackedResource": {
439-
"description": "ARM tracked top level resource.",
440-
"required": [
441-
"location"
442-
],
443-
"type": "object",
444-
"allOf": [
445-
{
446-
"$ref": "#/definitions/Resource"
447-
}
448-
],
449-
"properties": {
450-
"location": {
451-
"description": "Resource location.",
452-
"type": "string",
453-
"x-ms-mutability": [
454-
"read",
455-
"create"
456-
]
457-
},
458-
"tags": {
459-
"description": "Resource tags.",
460-
"type": "object",
461-
"additionalProperties": {
462-
"type": "string"
463-
}
464-
}
465-
}
466-
},
467357
"ManagedInstance": {
468358
"description": "An Azure SQL managed instance.",
469359
"required": [
@@ -472,20 +362,20 @@
472362
"type": "object",
473363
"allOf": [
474364
{
475-
"$ref": "#/definitions/TrackedResource"
365+
"$ref": "../../../common/v1/types.json#/definitions/TrackedResource"
476366
}
477367
],
478368
"properties": {
479369
"identity": {
480-
"$ref": "#/definitions/ResourceIdentity",
370+
"$ref": "../../../common/v1/types.json#/definitions/ResourceIdentity",
481371
"description": "The Azure Active Directory identity of the managed instance.",
482372
"x-ms-mutability": [
483373
"read",
484374
"create"
485375
]
486376
},
487377
"sku": {
488-
"$ref": "#/definitions/Sku",
378+
"$ref": "../../../common/v1/types.json#/definitions/Sku",
489379
"description": "Managed instance sku"
490380
},
491381
"properties": {
@@ -500,7 +390,7 @@
500390
"type": "object",
501391
"properties": {
502392
"sku": {
503-
"$ref": "#/definitions/Sku",
393+
"$ref": "../../../common/v1/types.json#/definitions/Sku",
504394
"description": "Managed instance sku"
505395
},
506396
"properties": {

0 commit comments

Comments
 (0)