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

Add built in policy definition/set definition paths #1788

Merged
merged 10 commits into from
Oct 4, 2017

Conversation

vivsriaus
Copy link
Contributor

@vivsriaus vivsriaus commented Oct 3, 2017

This checklist is used to make sure that common issues in a pull request are addressed. This will expedite the process of getting your pull request merged and avoid extra work on your part to fix issues discovered during the review process.

PR information

  • The title of the PR is clear and informative.
  • There are a small number of commits, each of which have an informative message. This means that previously merged commits do not appear in the history of the PR. For information on cleaning up the commits in your pull request, see this page.
  • Except for special cases involving multiple contributors, the PR is started from a fork of the main repository, not a branch.
  • If applicable, the PR references the bug/issue that it fixes.
  • Swagger files are correctly named (e.g. the api-version in the path should match the api-version in the spec).

Quality of Swagger

}
],
"responses": {
"200": {
Copy link
Contributor

Choose a reason for hiding this comment

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

404 should be valid response correct?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yep

"description": "Gets all the built in policy definitions.",
"parameters": [
{
"name": "$filter",
Copy link
Contributor

Choose a reason for hiding this comment

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

policyDefinition collection requests don't support odata fliters. Only policyAssignments have filters

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks

],
"responses": {
"200": {
"description": "OK - Returns ana array of built in policy definitions.",
Copy link
Contributor

Choose a reason for hiding this comment

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

"Returns an"

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixed

@vivsriaus vivsriaus changed the title Add built in policy definition paths Add built in policy definition/set definition paths Oct 3, 2017
@@ -256,13 +279,6 @@
"description": "Gets all the policy definitions for a subscription.",
"parameters": [
{
"name": "$filter",
Copy link
Member

Choose a reason for hiding this comment

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

So this was not supported and here by mistake?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, apparently, only policy assignment list supports filter. Not policy definitions and set definitions

Copy link
Member

Choose a reason for hiding this comment

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

ok, this was exposed in the CLI, I create an issue for that

Copy link
Member

Choose a reason for hiding this comment

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

@@ -292,19 +332,9 @@
"description": "Gets all the policy definitions for a subscription at management group level.",
"parameters": [
{
"name": "$filter",
Copy link
Member

Choose a reason for hiding this comment

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

Same question, not supported?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes, not supported

@veronicagg veronicagg added potential-sdk-breaking-change WaitForARMFeedback <valid label in PR review process> add this label when ARM review is required labels Oct 3, 2017
@veronicagg
Copy link
Contributor

@ravbhatnagar few apis added to existing api versions, some properties removed. Can you please review from ARM side? thanks!

@vivsriaus
Copy link
Contributor Author

@veronicagg Adding @cyl3392207, the PM for policy related ARM apis

Copy link
Contributor

@veronicagg veronicagg left a comment

Choose a reason for hiding this comment

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

Are the added apis new to the existing api versions or were there missing in the specs?
Please take a look at model validation results at https://travis-ci.org/Azure/azure-rest-api-specs/jobs/282957464#L577
Have you taken a look at linter results https://travis-ci.org/Azure/azure-rest-api-specs/jobs/282957459#L579 ?

@@ -137,6 +137,38 @@
}
}
},
"/providers/Microsoft.Authorization/policydefinitions/{policyDefinitionName}": {
Copy link
Contributor

Choose a reason for hiding this comment

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

was this api missing from the spec? or is it newly added to the existing api version?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

this was missing from the spec

}
}
},
"/providers/Microsoft.Authorization/policydefinitions": {
Copy link
Contributor

Choose a reason for hiding this comment

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

was this api missing from the spec before but existed in the service?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes, we never added this to spec

Copy link

@perseusCode perseusCode left a comment

Choose a reason for hiding this comment

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

:shipit:

@vivsriaus
Copy link
Contributor Author

@veronicagg The model validation results are because of missing example for 404 response, which I think is redundant here, and doesn't add any value. The linter result errors are also because of missing examples.

@azuresdkciprbot
Copy link

Hi There,

I am the AutoRest Linter Azure bot. I am here to help. My task is to analyze the situation from the AutoRest linter perspective. Please review the below analysis result:

💡 Please review potentially introduced Error(s)/Warning(s): Analysis Report 💡

File: specification/resources/resource-manager/readme.md
Before the PR: Warning(s): 0 Error(s): 69
After the PR: Warning(s): 0 Error(s): 71

AutoRest Linter Guidelines | AutoRest Linter Issues | Send feedback

Thanks for your co-operation.

@cyl33922072
Copy link

Approve from my side.

Copy link
Contributor

@ravbhatnagar ravbhatnagar left a comment

Choose a reason for hiding this comment

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

@vivsriaus @veronicagg looks good. one minor thing.

@@ -137,6 +137,38 @@
}
}
},
"/providers/Microsoft.Authorization/policydefinitions/{policyDefinitionName}": {
Copy link
Contributor

Choose a reason for hiding this comment

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

camel case ->policyDefinitions

@ravbhatnagar ravbhatnagar added ARMSignedOff <valid label in PR review process>add this label when ARM approve updates after review and removed WaitForARMFeedback <valid label in PR review process> add this label when ARM review is required labels Oct 4, 2017
@azuresdkciprbot
Copy link

Hi There,

I am the AutoRest Linter Azure bot. I am here to help. My task is to analyze the situation from the AutoRest linter perspective. Please review the below analysis result:

💡 Please review potentially introduced Error(s)/Warning(s): Analysis Report 💡

File: specification/resources/resource-manager/readme.md
Before the PR: Warning(s): 0 Error(s): 69
After the PR: Warning(s): 0 Error(s): 71

AutoRest Linter Guidelines | AutoRest Linter Issues | Send feedback

Thanks for your co-operation.

Copy link
Contributor

@veronicagg veronicagg left a comment

Choose a reason for hiding this comment

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

Looks good, some missing examples that based on offline conversation will be added in a later PR.

@veronicagg veronicagg merged commit 9f0f02a into Azure:current Oct 4, 2017
@AutorestCI
Copy link

No modification for AutorestCI/azure-sdk-for-node

@AutorestCI
Copy link

@AutorestCI
Copy link

@cyl33922072
Copy link

Approve

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ARMSignedOff <valid label in PR review process>add this label when ARM approve updates after review potential-sdk-breaking-change
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants