-
Notifications
You must be signed in to change notification settings - Fork 5.2k
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 for https://github.com/Azure/azure-rest-api-specs/issues/2907 #2910
Conversation
Automation for azure-sdk-for-pythonThe initial PR has been merged into your service PR: |
Automation for azure-sdk-for-goA PR has been created for you based on this PR content. Once this PR will be merged, content will be added to your service PR: |
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: AutoRest Linter Guidelines | AutoRest Linter Issues | Send feedback Thanks for your co-operation. |
Automation for azure-libraries-for-javaThe initial PR has been merged into your service PR: |
Automation for azure-sdk-for-nodeThe initial PR has been merged into your service PR: |
@dsgouda Please review code and merge. |
"$ref": "#/definitions/SiteSourceControl" | ||
} | ||
}, | ||
"201": { |
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.
Does "x-ms-long-running-operation: true" need to be added to this (and the other) operation?
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.
Hmm... not sure if we have long running get operations but in this case it does make sense to have one
@fearthecowboy can you take a look?
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.
Need some additional feedback
"$ref": "#/definitions/SiteSourceControl" | ||
} | ||
}, | ||
"201": { |
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.
Hmm... not sure if we have long running get operations but in this case it does make sense to have one
@fearthecowboy can you take a look?
Long running is only needed if the service isn't going to return right away -- And, this is a I didn't see a state in the model definition for Hey @ravbhatnagar -- Should they not be just adding some kind of provisioning state to the response object in this case (to support the scenario where the |
@suwatch (API owner) Can you please comment on the concerns here. |
This is a long running and could last for minutes/hours depending on user's deployment artifact. As part of our GET, we do return ProvisioningState to indicate InProgress/Success/Failed. Hope I answer the question about the api. |
Also, If I understand correctly the deployment (which is |
I understand your points. BTW, this long-running operation api works fine with ARM template engine since day one per https://docs.microsoft.com/en-us/azure/azure-resource-manager/resource-manager-async-operations. The GET may return 202 if not completed. I think the missing part is that if the GET were called by clients other than ARM template engine, we should not be returning 201 or 202, correct?
|
So, the current SDKs must be broken, for the GET operations. The question is, what should we do now? The Client Runtime doesn't have any support for GET with LRO. lemme go ping a couple people. |
I've talked with @ravbhatnagar over in ARM -- he agrees that we don't really want to fix the client SDK generation to support this pattern. This is not consistent with API guidelines at all. If this is what it's doing today; then fine -- write the swagger so that it's correct, and this behavior should be corrected in a subsequent API Version -- Since we're not going to change the client generation, marking the APIs as @dsgouda -- can you file a bug in the Linter to add a new ARM rule to that prohibits |
Approving this PR only as an accurate representation of the service today but this is against guidelines; will open an issue against this |
@fearthecowboy Thanks for the review. Please assign the new issue to @suwatch |
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
api-version
in the path should match theapi-version
in the spec).Quality of Swagger