splicemachine / splicectl

GNU Affero General Public License v3.0
2 stars 2 forks source link

K8s: splicectl - refactor structure of cmd package into multiple packages based on subcommands. #19

Closed RileyMcCuen closed 3 years ago

RileyMcCuen commented 3 years ago

Description

Refactored splicectl to make code drier, easier to maintain, and easier to extend with future features.

Most changes were focused on making small packages that focused on one common task and reducing global namespace pollution. This was achieved by:

Motivation and Context

This was done in anticipation of adding several new commands and sub commands which will now be easier to organize, discover preexisting functionality that already exists, and keeping the global namespace smaller so development is more focused.

No user facing changes have been made, but many maintenance focused improvements have been made.

See DBAAS-5756

Dependencies

How Has This Been Tested?

I carried out regression testing manually, verifying that the tool still worked as expected and compared output to a pre-refactored version of the tool. I noticed no degradation of service, although I cannot be sure that I performed every possible combination of commands, so small bugs could have possibly made their way into the tool. I kept these changes in review for ~2 weeks and continued using the refactored version of splicectl during that time period and still have not found any errors.

Screenshots (if appropriate)

Checklist

If the pull request includes user-facing changes, extra documentation is required:

Changelog Inclusions

Additions

Changes

Fixes

Deprecated

Removed

Breaking Changes

splicemaahs commented 3 years ago

With as busy as everyone is with OCI this week, I'm going to go ahead and merge this, as this PR unblocks other PRs that rely upon the code refactor.