-
Notifications
You must be signed in to change notification settings - Fork 5.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Swagger change for getting all availability sets in a subscription and StandardSSD #3302
Changes from 4 commits
474690a
c60eb5a
8ba6300
41175e4
e6bffd7
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
{ | ||
"parameters": { | ||
"subscriptionId": "{subscriptionId}", | ||
"api-version": "2016-04-30-preview" | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"value": [ | ||
{ | ||
"properties": { | ||
"platformUpdateDomainCount": 5, | ||
"platformFaultDomainCount": 2 | ||
}, | ||
"type": "Microsoft.Compute/availabilitySets", | ||
"location": "centralus", | ||
"tags": { | ||
"{tagName}": "{tagValue}" | ||
}, | ||
"id": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/availabilitySets/{availabilitySetName}", | ||
"name": "{availabilitySetName}", | ||
"sku": { | ||
"name": "Aligned" | ||
} | ||
}, | ||
{ | ||
"properties": { | ||
"platformUpdateDomainCount": 3, | ||
"platformFaultDomainCount": 2 | ||
}, | ||
"type": "Microsoft.Compute/availabilitySets", | ||
"location": "westus", | ||
"tags": { | ||
"{tagName}": "{tagValue}" | ||
}, | ||
"id": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/availabilitySets/{availabilitySetName}", | ||
"name": "{availabilitySetName}", | ||
"sku": { | ||
"name": "Classic" | ||
} | ||
} | ||
] | ||
} | ||
} | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
{ | ||
"parameters": { | ||
"subscriptionId": "{subscriptionId}", | ||
"api-version": "2017-03-30" | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"value": [ | ||
{ | ||
"properties": { | ||
"platformUpdateDomainCount": 5, | ||
"platformFaultDomainCount": 2 | ||
}, | ||
"type": "Microsoft.Compute/availabilitySets", | ||
"location": "centralus", | ||
"tags": { | ||
"{tagName}": "{tagValue}" | ||
}, | ||
"id": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/availabilitySets/{availabilitySetName}", | ||
"name": "{availabilitySetName}", | ||
"sku": { | ||
"name": "Aligned" | ||
} | ||
}, | ||
{ | ||
"properties": { | ||
"platformUpdateDomainCount": 3, | ||
"platformFaultDomainCount": 2 | ||
}, | ||
"type": "Microsoft.Compute/availabilitySets", | ||
"location": "westus", | ||
"tags": { | ||
"{tagName}": "{tagValue}" | ||
}, | ||
"id": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/availabilitySets/{availabilitySetName}", | ||
"name": "{availabilitySetName}", | ||
"sku": { | ||
"name": "Classic" | ||
} | ||
} | ||
] | ||
} | ||
} | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
{ | ||
"parameters": { | ||
"subscriptionId": "{subscriptionId}", | ||
"api-version": "2017-12-01" | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"value": [ | ||
{ | ||
"properties": { | ||
"platformUpdateDomainCount": 5, | ||
"platformFaultDomainCount": 2 | ||
}, | ||
"type": "Microsoft.Compute/availabilitySets", | ||
"location": "centralus", | ||
"tags": { | ||
"{tagName}": "{tagValue}" | ||
}, | ||
"id": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/availabilitySets/{availabilitySetName}", | ||
"name": "{availabilitySetName}", | ||
"sku": { | ||
"name": "Aligned" | ||
} | ||
}, | ||
{ | ||
"properties": { | ||
"platformUpdateDomainCount": 3, | ||
"platformFaultDomainCount": 2 | ||
}, | ||
"type": "Microsoft.Compute/availabilitySets", | ||
"location": "westus", | ||
"tags": { | ||
"{tagName}": "{tagValue}" | ||
}, | ||
"id": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/availabilitySets/{availabilitySetName}", | ||
"name": "{availabilitySetName}", | ||
"sku": { | ||
"name": "Classic" | ||
} | ||
} | ||
] | ||
} | ||
} | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -783,7 +783,8 @@ | |
"type": "string", | ||
"enum": [ | ||
"Standard_LRS", | ||
"Premium_LRS" | ||
"Premium_LRS", | ||
"StandardSSD_LRS" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This creates invaliad Swagger: There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I forgot to update 2018-04-01 compute.json. It is updated now. |
||
], | ||
"x-ms-enum": { | ||
"name": "StorageAccountTypes", | ||
|
@@ -798,7 +799,7 @@ | |
"description": "The sku tier." | ||
} | ||
}, | ||
"description": "The disks sku name. Can be Standard_LRS or Premium_LRS." | ||
"description": "The disks sku name. Can be Standard_LRS, Premium_LRS, or StandardSSD_LRS." | ||
}, | ||
"SnapshotSku": { | ||
"properties": { | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The provided example creates a linter error:
Could you either:
Whatever you do, do NOT remove "x-ms-pageable", that's the right thing to do since it's a method that has the semantic of a list.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you please check again? I think the issue is not that nextLink is missing in the example, but that nextLink is missing AvailabilitySetListResult in compute.json.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, I see what you mean, you re-used
AvailabilitySetListResult
as it was defined. Let me check what should be the correct way to remove this warning then.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dochung4 I made an actual call to the endpoint, and didn't get a nextLink back in the JSON. But maybe I didn't have enough resource to trigger the nextLink. But if it's the truth and the endpoint always returns a unique page whatever the number of AS, then the correct definition is to use
null
.Could you confirm the actual server behavior:
null
nextLink
Swagger must described accurately the server, and since I don't own the server implementation I don't know which one is the truth. Your last commit changed a lot of
null
tonextLink
and that concerns me a bit.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For which call did you not get a nextLink back? Currently we have nextLink for listing all availability sets in a subscription, but not for listing all resource groups in a resource group. But I discussed this with my team and I added nextLink to the latter too, because it will be enabled very soon.
Please let me know if you have other thoughts.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I checked listing AS in a RG indeed. So if I understand you correctly:
Is this accurate?
If this is accurate, I'm good with the PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes that's correct.