-
Notifications
You must be signed in to change notification settings - Fork 62
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
databricks update groups command is unnecessarily destructive #1942
Comments
This issue has not received a response in a while. If you want to keep this issue open, please leave a comment below and auto-close will be canceled. |
@shreyas-goenka do you have an opinion on this? |
@tim-sparq Thanks for reporting this discrepancy. Regarding documentation, It is documented in the help for the command itself:
I agree with you that the name I'll keep this issue open for now, with the intention of picking up the standardization work sometime in the future. |
@shreyas-goenka I don't have a problem with the use of the name I only have a problem with the command emptying a group of all its members when no configuration is supplied. It's an unnecessarily destructive behaviour. Of course, it should be possible for a user to remove all members of a group using this command. But I would argue that that command should be:
And that this command:
Should simply return an error along the lines of |
@tim-sparq Yeah your feedback makes sense to me. Any such change, though, should be consistent across all commands and thus would have to be looked into a bit. Just FYI there's a different command available that does partial non-destructive updates, which seems more suitable for your use case.
Ideally, the |
Again, I would even argue that
Should (if it existed) throw an error, because the replacement group configuration has not been supplied. |
Describe the issue
Running the
databricks groups update [group id]
command without the--json
flag deletes all of the specified group's configuration, including all members, potentially with destructive impact.Recently this caused a production incident in our environment when all users were silently removed from our workspace's
admins
group, causing pipelines to break and locking us out of our workspace.This behaviour - which is undocumented - is unnecessarily destructive. If no configuration is supplied, the command should arguably throw an error, instead of silently removing all users from the specified group. Compare to other major clis (such as
az
/gcloud
) where such a destructive behavior is not possible.Steps to reproduce the behavior
Please list the steps required to reproduce the issue, for example:
databricks groups update [group id]
, omitting the--json
flagExpected Behavior
The command should return an error notifying the user that no configuration was supplied
Actual Behavior
The command silently deletes all of the specified group's configuration, including all members, potentially with destructive impact
OS and CLI version
macos, Databricks CLI v0.219.0,
Is this a regression?
No
Debug Logs
N/A
The text was updated successfully, but these errors were encountered: