-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
[Resources] Add deployment scripts resource type to the Resources SDK #8436
Conversation
@AlexGhiondea @kurtzeborn Hi, resources team met something like an autorest bug. Could you help investigate? Thanks |
@erich-wang could you help with this? |
Where is the spec that contains the schema that is called |
Here's the swagger that we use to generate our SDK. https://github.com/Azure/azure-rest-api-specs/blob/master/specification/resources/resource-manager/Microsoft.Resources/preview/2019-10-01-preview/deploymentScripts.json I believe the page.cs gets created by the autorest since we have a pagable list call:
|
Ok, I'm thoroughly confused here. Are you saying the generator is creating a third Where does the extra
The And given that no new work is going into that generator, it's not going to change. |
@isra-fel I have included the generated .txt file, updated versions, and tags. Could you see if I'm missing anything? I'm recording tests and will submit them soon. |
@fearthecowboy Sorry for the confusion. Let me try to elaborate. I think the root cause of my question is coming from the fact that there are two Page files in Models in the Microsoft.Resources SDK: Page.cs and Page1.cs. I'm curious to find out why that is and if autorest tool created these two separate Page files. Here're the Page files I am referring to: https://github.com/Azure/azure-sdk-for-net/tree/master/sdk/resources/Microsoft.Azure.Management.Resource/src/Generated/Models |
The C# generator did create both of those. I'm not entirely sure why it does that. It's not going to affect anything, there's not any reason to do anything with them. |
Submited the test recordings. Also updated the version number as per out discussion. Is there anything else missing from the PR? |
Looks good to me |
The new preview version of Resources SDK will support deployment scripts resource type. This new resource type is added to the Resources namespace.
Link to the swagger PR: Azure/azure-rest-api-specs#7486
Question for the reviewer
There was a name clash while generating the Page.cs - I renamed our Page.cs file temporarily. I see that there are already two separate page classes in the SDK (see Page.cs and Page1.cs) Should we rename our page class to Page2? If so, is there a automated way of doing it through Autorest(AFAIK there is none) or should we do it manually? I would think doing it manually will create extra work in the future if/when we re-generate the SDK since we need to rename the class again. It'd be good to know if this can be done through Autorest.
Another option would be using the class that is already in the project. Though this also might not be ideal since we'll be tying our code to a class that is being generated by some other swagger.
What would be a good way to solve this issue? Your help in this matter is appreciated.