Skip to content
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

[#6136] refactor: move check for enable and disable within validate #6163

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

VigneshSK17
Copy link
Contributor

What changes were proposed in this pull request?

The check for enable and disable was within GravitinoCommandLine.java, not inside the validate() logic as it should be.

Why are the changes needed?

To keep consistency within the codebase and making sure the validate() method for a command is being used effectively

Fix: #6136

Does this PR introduce any user-facing change?

No

How was this patch tested?

Updated tests and ran local test suite successfully.

@VigneshSK17
Copy link
Contributor Author

@justinmclean Is this what you envisioned when creating the issue? I was a bit confused by the wording.

@VigneshSK17
Copy link
Contributor Author

Had to modify to support the newly-refactored commands, but now should be ready for review @justinmclean

spy(
new GravitinoCommandLine(
mockCommandLine, mockOptions, CommandEntities.CATALOG, CommandActions.UPDATE));
new CatalogEnable(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be GravitinoCommandLine not CatalogEnable

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated test to use GravitinoCommandLine.

spy(
new GravitinoCommandLine(
mockCommandLine, mockOptions, CommandEntities.METALAKE, CommandActions.UPDATE));
new MetalakeEnable(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This needs to be GravitinoCommandLine not MetalakeEnable

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated test to use GravitinoCommandLine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Improvement] Move check for enable and disable command in Gravitino CLI to command
2 participants