Skip to content
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

Fix swagger correctness #4

Merged
merged 4 commits into from
Jul 28, 2021
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -4762,7 +4762,7 @@
"additionalProperties": {
"type": "string"
},
"maxItems": 1000
"maxItems": 50

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we have validation on key/value lengths as well, like ARM does? We need to make sure that we scale properly when someone creates the largest possible invoice section entities, many times.

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes we have validation on key/value lengths as well.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should describe the validation in the description of this property so people can look this up

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added

},
"state": {
"description": "Identifies the state of an invoice section.",
Expand All @@ -4782,6 +4782,14 @@
"type": "string",
"readOnly": true
},
"tags": {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the difference between tags and labels?

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They are the same. Plan was to eliminate one, but now both are being returned and this is causing s360 to flag this. So to fix this issue in GA, i am adding tags also to the swagger spec.

"type": "object",
"description": "Dictionary of metadata associated with the invoice section.",
"additionalProperties": {
"type": "string"
},
"maxItems": 50
},
"targetCloud": {
"description": "Identifies the cloud environments that are associated with an invoice section. This is a system managed optional field and gets updated as the invoice section gets associated with accounts in various clouds.",
"$ref": "#/definitions/TargetCloud",
Expand Down Expand Up @@ -5332,6 +5340,12 @@
"$ref": "#/definitions/Product"
}
},
"totalCount": {
"description": "Total number of records.",
"type": "number",
"format": "int32",
"readOnly": true
},
"nextLink": {
"description": "The link (url) to the next page of results.",
"type": "string",
Expand Down Expand Up @@ -5679,6 +5693,14 @@
"description": "The sku description of the Azure plan for the subscription.",
"type": "string",
"readOnly": true
},
"suspensionReasons": {
"description": "The suspension reason for a subscription. Applies only to subscriptions in Microsoft Online Services Program (MOSP) billing accounts.",
"type": "array",
"readOnly": true,
"items": {
"type": "string"
}
}
}
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,11 @@
"costCategory": "Support"
},
"state": "Active",
"systemId": "XX1X-XXAA-XXX-ZZZ"
"systemId": "XX1X-XXAA-XXX-ZZZ",
"tags": {
"pcCode": "A123456",
"costCategory": "Support"
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,11 @@
"costCategory": "Support"
},
"state": "Active",
"systemId": "XX1X-XXAA-XXX-ZZZ"
"systemId": "XX1X-XXAA-XXX-ZZZ",
"tags": {
"pcCode": "A123456",
"costCategory": "Support"
}
}
},
{
Expand All @@ -34,6 +38,10 @@
},
"state": "Restricted",
"systemId": "YY1X-BBAA-XXX-ZZZ",
"tags": {
"pcCode": "Z223456",
"costCategory": "Marketing"
},
"targetCloud": "USSec"
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@
"billingProfileDisplayName": "Contoso operations billing"
}
}
]
],
"totalCount": 2
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,8 @@
"billingProfileDisplayName": "Contoso operations billing"
}
}
]
],
"totalCount": 2
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,8 @@
"billingProfileDisplayName": "Contoso operations billing"
}
}
]
],
"totalCount": 2
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,8 @@
"billingProfileDisplayName": "Contoso operations billing"
}
}
]
],
"totalCount": 2
}
}
}
Expand Down