Named DiagnosticSettings#1641
Conversation
|
@ravbhatnagar please, have a look. It's a new API version. |
ravbhatnagar
left a comment
There was a problem hiding this comment.
@vcanaa - please take a look
| "DiagnosticSettingsCategories" | ||
| ], | ||
| "operationId": "DiagnosticSettingsCategory_Get", | ||
| "description": "Gets the diagnostic settings category for the specified resource.", |
There was a problem hiding this comment.
Please indicate some of the typical values resourceUri could take to help customers understand this.
There was a problem hiding this comment.
This is explicit in the example with a logic app.
There was a problem hiding this comment.
Is it too difficult to add it to the description? SDK users rely on description, API docs rely on description.
There was a problem hiding this comment.
Any change in the description breaks the generation, so it requires more work that touches all our classes. I created a task on us to fix that.
| }, | ||
| "DiagnosticSettingsCategory": { | ||
| "properties": { | ||
| "categoryType": { |
There was a problem hiding this comment.
I consider Enum bad practice when serialization is involved. If we introduce a new type, customers will be forced to update the sdk or the serialization will break.
There was a problem hiding this comment.
Yes and that is the recommendation. Enum will make your API more usable. Else how will someone know when you support new types? When you support new types, you add the enum value and increment the APi version
There was a problem hiding this comment.
I don't like enums in serialization, but I am taking this feedback since more people seem to like them.
| "readOnly": true, | ||
| "description": "Azure resource type" | ||
| }, | ||
| "location": { |
There was a problem hiding this comment.
I don't think there should be location or tags here. Isnt this a proxy resource.
There was a problem hiding this comment.
It is a proxy resource, but these are populated anyway when the request comes back. Also the resource class is shared by everything. It has been that way for a long time.
I believe we could have another class for proxy resource, but I prefer addressing that in a different release.
There was a problem hiding this comment.
Can we get an ACK in email with a workitem that this will be addressed in the next release? Apologies, but this is the only way to get the APIs cleaned up across Azure plat. I wont remember this comment in a few months and no one else on your team will :). So it will most likely be missed in the next rev also.
There was a problem hiding this comment.
Created a task for this
|
Discussed over email and there are workitems created to address the feedback. Approving for now. |
| "tags" : null, | ||
| "properties" : { | ||
| "storageAccountId" : "/subscriptions/df602c9c-7aa0-407d-a6fb-eb20c8bd1192/resourceGroups/apptest/providers/Microsoft.Storage/storageAccounts/appteststorage1", | ||
| "serviceBusRuleId" : "/subscriptions/b67f7fec-69fc-4974-9099-a26bd6ffeda3/resourceGroups/andy1101/providers/Microsoft.EventHub/namespaces/andy1101/authorizationrules/RootManageSharedAccessKey", |
There was a problem hiding this comment.
The response model DiagnosticSettings doesn't have ServiceBusRuleId property and no additional properties are accepted.
| "parameters": { | ||
| "resourceUri": "/subscriptions/1a66ce04-b633-4a0b-b2bc-a912ec8986a6/resourcegroups/viruela1/providers/microsoft.logic/workflows/viruela6", | ||
| "api-version": "2017-05-01-preview", | ||
| "parameters": { |
There was a problem hiding this comment.
Error: parameter name is missing.
| @@ -0,0 +1,271 @@ | |||
| { | |||
There was a problem hiding this comment.
Operations API should be implemented.
| @@ -0,0 +1,499 @@ | |||
| { | |||
There was a problem hiding this comment.
Operations API should be implemented.
|
@ravbhatnagar a new commit has a new file |
sergey-shandar
left a comment
There was a problem hiding this comment.
Preliminary comments. I haven't looked the new operation api file yet, I'm waiting for ARM review.
|
Looks good. @sergey-shandar @veronicagg - FYI that the operations API and the response could be converted to a linter rule since its standard. |
|
@vcanaa let me know when it's ready for review. It's hard to review a moving target :-) |
|
This is ready for review. |
|
@vcanaa thank you :-) I'm reviewing the code. It will take a while since it's big and we have a lot of other PRs for Ignite. |
|
I was not sure if you were waiting for the sdk PR or not until a saw a new tag ReadyForSdkReview. So I sent a new PR for the sdk now. |
|
I renamed the spec to: So it is more informative. |
|
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: File: AutoRest Linter Guidelines | AutoRest Linter Issues Send feedback and make AutoRest Linter Azure Bot smarter day by day! Thanks for your co-operation. |
|
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: File: AutoRest Linter Guidelines | AutoRest Linter Issues Send feedback and make AutoRest Linter Azure Bot smarter day by day! Thanks for your co-operation. |
| "operation":"Operations read", | ||
| "description":"Reading operations" | ||
| }, | ||
| "properties":{ |
There was a problem hiding this comment.
The "properties" property is not allowed according to "Operation" definition.
| @@ -0,0 +1,22 @@ | |||
| { | |||
| "parameters" : { | |||
| "resourceUri" : "/subscriptions/1a66ce04-b633-4a0b-b2bc-a912ec8986a6/resourcegroups/viruela1/providers/microsoft.logic/workflows/viruela6", | |||
There was a problem hiding this comment.
The parameter resourceUri starts with a forward slash and the path template: /{resourceUri}/providers/microsoft.insights/diagnosticSettingsCategories/{name} contains a forward slash before the parameter starts. This will cause double forward slashes in the request url. Thus making it incorrect. Please rectify the example.'
| "name":"WorkflowRuntime", | ||
| "location":"eastus", | ||
| "tags":null, | ||
| "properties": { |
There was a problem hiding this comment.
tag and location aren't allowed in #/definitions/DiagnosticSettingsCategoryResource
| "value": [ | ||
| { | ||
| "id":"/subscriptions/1a66ce04-b633-4a0b-b2bc-a912ec8986a6/resourcegroups/viruela1/providers/microsoft.logic/workflows/viruela6/diagnosticSettings/mysetting", | ||
| "type":"microsoft.logic/workflows", |
There was a problem hiding this comment.
The parameter resourceUri starts with a forward slash and the path template: /{resourceUri}/providers/microsoft.insights/diagnosticSettingsCategories/{name} contains a forward slash before the parameter starts. This will cause double forward slashes in the request url. Thus making it incorrect. Please rectify the example.'
| "type":"microsoft.logic/workflows", | ||
| "name":"mysetting", | ||
| "location":"eastus", | ||
| "tags":null, |
There was a problem hiding this comment.
tag and location aren't allowed in #/definitions/DiagnosticSettingsCategoryResource.
| "type":"microsoft.insights/diagnosticSettingsCategories", | ||
| "name":"WorkflowRuntime", | ||
| "location":"eastus", | ||
| "tags":null, |
There was a problem hiding this comment.
tag and location aren't allowed in #/definitions/DiagnosticSettingsCategoryResource.
| "name":"mysetting", | ||
| "location":"", | ||
| "tags":null, | ||
| "properties": { |
There was a problem hiding this comment.
tag and location shouldn't be in response, according to model definition.
| "name":"mysetting", | ||
| "location":"eastus", | ||
| "tags":null, | ||
| "properties": { |
There was a problem hiding this comment.
tag and location shouldn't be in the response according to DiagnosticSettingsResource
| } | ||
| ], | ||
| "properties": { | ||
| "properties": { |
sergey-shandar
left a comment
There was a problem hiding this comment.
Currently, the main problem is models which don't have tag and location as properties but examples do have them.
|
No modification for AutorestCI/azure-sdk-for-node |
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-versionin the path should match theapi-versionin the spec).Quality of Swagger