Skip to content

Commit 2032fd0

Browse files
YobretawYouke Shen
andauthored
[Hub Generated] Review request for Microsoft.ResourceGraph to add version preview/2020-04-01-preview (Azure#11070)
* Add missing subscriptionId and resourceGroup * Update 2020-04-01-preview * Split 2020-04-01-preview * Reverting changes for subscriptionId/resourceGroup; Fix casing for etag field. * Adding missing ResourcesHistory API to swagger * Fix API definition; Add an example * Fix multiple issues 1) Rename PropertyChangeType to ChangeType; 2) Add resourceId ResourceChangeData; 3) Add snapshotId to ResourceSnapshotData; 4) Fix model name in resourceshistory.json * Fix linter/model issues * Fix etag casing more places * Fix ErrorResponse modeling in resourcechanges.json and resourcehistory.json * Add default response for Operations API * Revert renaming of PropertyChangeType * Add changeType to swagger * Revert "Add changeType to swagger" This reverts commit 5bfd7fbd9492abc96076a459f7ca914e44bffc9a. * Fix swagger for resourcesHistory Co-authored-by: Youke Shen <[email protected]>
1 parent d88bf13 commit 2032fd0

File tree

15 files changed

+719
-314
lines changed

15 files changed

+719
-314
lines changed

specification/resourcegraph/resource-manager/Microsoft.ResourceGraph/preview/2018-09-01-preview/examples/GraphQueryAdd.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
"id": " /subscriptions/024e2271-06fa-46b6-9079-f1ed3c7b070e/resources/my-resource-group/providers/Microsoft.ResourceGraph/queries/MyDockerVMs",
2121
"name": "MyDockerVMs",
2222
"type": "Microsoft.ResourceGraph/queries",
23-
"eTag": "5d64408e-4ca3-41f7-b725-6914f3012afa",
23+
"etag": "5d64408e-4ca3-41f7-b725-6914f3012afa",
2424
"tags": {},
2525
"properties": {
2626
"description": "Docker VMs in PROD",

specification/resourcegraph/resource-manager/Microsoft.ResourceGraph/preview/2018-09-01-preview/examples/GraphQueryGet.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"id": " /subscriptions/024e2271-06fa-46b6-9079-f1ed3c7b070e/resources/my-resource-group/providers/Microsoft.ResourceGraph/queries/MyDockerVMs",
1414
"name": "MyDockerVMs",
1515
"type": "Microsoft.ResourceGraph/queries",
16-
"eTag": "5d64408e-4ca3-41f7-b725-6914f3012afa",
16+
"etag": "5d64408e-4ca3-41f7-b725-6914f3012afa",
1717
"tags": null,
1818
"properties": {
1919
"description": "Docker VMs in PROD",

specification/resourcegraph/resource-manager/Microsoft.ResourceGraph/preview/2018-09-01-preview/examples/GraphQueryList.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
"name": "MyDockerVMs",
1717
"type": "Microsoft.ResourceGraph/queries",
1818
"tags": {},
19-
"eTag": "5d64408e-4ca3-41f7-b725-6914f3012afa",
19+
"etag": "5d64408e-4ca3-41f7-b725-6914f3012afa",
2020
"properties": {
2121
"description": "Docker VMs in PROD",
2222
"query": "where isnotnull(tags['Prod']) and properties.extensions[0].Name == 'docker'",
@@ -29,7 +29,7 @@
2929
"name": "MyTestVMs",
3030
"type": "Microsoft.ResourceGraph/queries",
3131
"tags": {},
32-
"eTag": "b0809832-ca62-4133-8f13-0c46580f9db1",
32+
"etag": "b0809832-ca62-4133-8f13-0c46580f9db1",
3333
"properties": {
3434
"description": "Test VMs in PROD",
3535
"query": "where isnotnull(tags['Prod']) and properties.extensions[0].Name == 'test'",

specification/resourcegraph/resource-manager/Microsoft.ResourceGraph/preview/2018-09-01-preview/examples/GraphQueryUpdate.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"api-version": "2018-09-01-preview",
99
"body": {
1010
"tags": null,
11-
"eTag": "b0809832-ca62-4133-8f13-0c46580f9db1",
11+
"etag": "b0809832-ca62-4133-8f13-0c46580f9db1",
1212
"properties": {
1313
"description": "Modified description",
1414
"query": "where isnotnull(tags['Prod']) and properties.extensions[0].Name == 'docker'"
@@ -21,7 +21,7 @@
2121
"id": " /subscriptions/024e2271-06fa-46b6-9079-f1ed3c7b070e/resources/my-resource-group/providers/Microsoft.ResourceGraph/queries/MyDockerVMs",
2222
"name": "MyDockerVMs",
2323
"type": "Microsoft.ResourceGraph/queries",
24-
"eTag": "73811091-6188-4523-97b7-b5e7134e7fd9",
24+
"etag": "73811091-6188-4523-97b7-b5e7134e7fd9",
2525
"tags": null,
2626
"properties": {
2727
"description": "Modified description",

specification/resourcegraph/resource-manager/Microsoft.ResourceGraph/preview/2018-09-01-preview/graphquery.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,7 @@
277277
"readOnly": true,
278278
"description": "Azure resource type"
279279
},
280-
"eTag": {
280+
"etag": {
281281
"type": "string",
282282
"description": "This will be used to handle Optimistic Concurrency. If not present, it will always overwrite the existing resource without checking conflict."
283283
},
@@ -367,7 +367,7 @@
367367
},
368368
"description": "Resource tags"
369369
},
370-
"eTag": {
370+
"etag": {
371371
"type": "string",
372372
"description": "This will be used to handle Optimistic Concurrency. If not present, it will always overwrite the existing resource without checking conflict."
373373
},

specification/resourcegraph/resource-manager/Microsoft.ResourceGraph/preview/2020-04-01-preview/examples/GraphQueryAdd.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
"id": " /subscriptions/024e2271-06fa-46b6-9079-f1ed3c7b070e/resources/my-resource-group/providers/Microsoft.ResourceGraph/queries/MyDockerVMs",
2121
"name": "MyDockerVMs",
2222
"type": "Microsoft.ResourceGraph/queries",
23-
"eTag": "5d64408e-4ca3-41f7-b725-6914f3012afa",
23+
"etag": "5d64408e-4ca3-41f7-b725-6914f3012afa",
2424
"tags": {},
2525
"properties": {
2626
"description": "Docker VMs in PROD",

specification/resourcegraph/resource-manager/Microsoft.ResourceGraph/preview/2020-04-01-preview/examples/GraphQueryGet.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"id": " /subscriptions/024e2271-06fa-46b6-9079-f1ed3c7b070e/resources/my-resource-group/providers/Microsoft.ResourceGraph/queries/MyDockerVMs",
1414
"name": "MyDockerVMs",
1515
"type": "Microsoft.ResourceGraph/queries",
16-
"eTag": "5d64408e-4ca3-41f7-b725-6914f3012afa",
16+
"etag": "5d64408e-4ca3-41f7-b725-6914f3012afa",
1717
"tags": null,
1818
"properties": {
1919
"description": "Docker VMs in PROD",

specification/resourcegraph/resource-manager/Microsoft.ResourceGraph/preview/2020-04-01-preview/examples/GraphQueryList.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
"name": "MyDockerVMs",
1717
"type": "Microsoft.ResourceGraph/queries",
1818
"tags": {},
19-
"eTag": "5d64408e-4ca3-41f7-b725-6914f3012afa",
19+
"etag": "5d64408e-4ca3-41f7-b725-6914f3012afa",
2020
"properties": {
2121
"description": "Docker VMs in PROD",
2222
"query": "where isnotnull(tags['Prod']) and properties.extensions[0].Name == 'docker'",
@@ -37,7 +37,7 @@
3737
"name": "MyTestVMs",
3838
"type": "Microsoft.ResourceGraph/queries",
3939
"tags": {},
40-
"eTag": "b0809832-ca62-4133-8f13-0c46580f9db1",
40+
"etag": "b0809832-ca62-4133-8f13-0c46580f9db1",
4141
"properties": {
4242
"description": "Test VMs in PROD",
4343
"query": "where isnotnull(tags['Prod']) and properties.extensions[0].Name == 'test'",

specification/resourcegraph/resource-manager/Microsoft.ResourceGraph/preview/2020-04-01-preview/examples/GraphQueryUpdate.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"api-version": "2020-04-01-preview",
99
"body": {
1010
"tags": null,
11-
"eTag": "b0809832-ca62-4133-8f13-0c46580f9db1",
11+
"etag": "b0809832-ca62-4133-8f13-0c46580f9db1",
1212
"properties": {
1313
"description": "Modified description",
1414
"query": "where isnotnull(tags['Prod']) and properties.extensions[0].Name == 'docker'"
@@ -21,7 +21,7 @@
2121
"id": " /subscriptions/024e2271-06fa-46b6-9079-f1ed3c7b070e/resources/my-resource-group/providers/Microsoft.ResourceGraph/queries/MyDockerVMs",
2222
"name": "MyDockerVMs",
2323
"type": "Microsoft.ResourceGraph/queries",
24-
"eTag": "73811091-6188-4523-97b7-b5e7134e7fd9",
24+
"etag": "73811091-6188-4523-97b7-b5e7134e7fd9",
2525
"tags": null,
2626
"properties": {
2727
"description": "Modified description",
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
{
2+
"title": "Resource History Query",
3+
"description": "A resource history query.",
4+
"parameters": {
5+
"api-version": "2020-04-01-preview",
6+
"request": {
7+
"subscriptions": [
8+
"a7f33fdb-e646-4f15-89aa-3a360210861e"
9+
],
10+
"query": "where name =~ 'cpu-utilization' | project id, name, properties",
11+
"options": {
12+
"interval": {
13+
"start": "2020-11-12T01:00:00.0000000Z",
14+
"end": "2020-11-12T01:25:00.0000000Z"
15+
}
16+
}
17+
}
18+
},
19+
"responses": {
20+
"200": {
21+
"body": {
22+
"count": 2,
23+
"snapshots": {
24+
"columns": [
25+
{
26+
"name": "id",
27+
"type": "string"
28+
},
29+
{
30+
"name": "name",
31+
"type": "string"
32+
},
33+
{
34+
"name": "properties",
35+
"type": "object"
36+
}
37+
],
38+
"rows": [
39+
[
40+
"/subscriptions/a7f33fdb-e646-4f15-89aa-3a360210861e/resourceGroups/meya-test-rg/providers/Microsoft.Compute/virtualMachines/meya-win-eus/providers/Microsoft.WorkloadMonitor/monitors/cpu-utilization",
41+
"cpu-utilization",
42+
{
43+
"monitorName": "",
44+
"currentStateFirstObservedTimestamp": ""
45+
}
46+
],
47+
[
48+
"/subscriptions/a7f33fdb-e646-4f15-89aa-3a360210861e/resourceGroups/meya-test-rg/providers/Microsoft.Compute/virtualMachines/meya-win-eus/providers/Microsoft.WorkloadMonitor/monitors/cpu-utilization",
49+
"cpu-utilization",
50+
{
51+
"monitorName": "test",
52+
"currentStateFirstObservedTimestamp": ""
53+
}
54+
]
55+
]
56+
}
57+
}
58+
}
59+
}
60+
}

0 commit comments

Comments
 (0)