Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
OperationalInsights: DataCollectorLogs new api support. #10365
OperationalInsights: DataCollectorLogs new api support. #10365
Changes from 8 commits
91ed7bd
893d1f9
a90be91
b3e9da6
0fcbe21
ad1c14b
77fcfcd
22c1e5c
e082399
2e2ec27
bfd7663
5fef998
a87bd3d
c7021ee
cb67a6d
ba891b7
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
From description it seems like this POST action is used to delete a log table. what is the need to expose deletion operation through the control plane on something (tables) which is not exposed on the control plane. Its wierd and can cause of sorts of issues like permission check, inconsistent state/confusion for customer where i am assuming same thing can be from the dataplane api as well etc.
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.
and if we agree that this is the only way to go about it and its required, i will ask you, at the very least to change the name of this action. This POST action from the name seems very harmless but it ends up deleting something. So name should indicate what this operation does. may be call it deleteDataCollectorLogsTable. But lets answer the above question first.
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.
it all derives from the fact this is not a typical CRUD, so post is multi purpose, in this case being used for delete.
i have no problem changing the post to delete, but there will be no put. is that sounds reasonable?
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.
yes, better to switch to GET and DELETE
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.
what is the response of this post action?
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.
please add the response schema.
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.
no schema, just 200 since its basically a delete.
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.
how is the POST different from this GET? the API signature is same.
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.
so the scenario is user lists the tables and then you want to give them the option to delete them. In that case, your POST should be changed to a DELETE, and they can provide the tableName that they want to delete. Much cleaner approach. POST for delete is ugly.
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.
we do not support full CRUD, is it fine if i will supply delete and get and no put? this is why we used post instead.
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.
yes, it will be ok to have GET and DELETE