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

CLI command naming consistency #794

Closed
joeshaw opened this issue Feb 6, 2023 · 2 comments · Fixed by #798
Closed

CLI command naming consistency #794

joeshaw opened this issue Feb 6, 2023 · 2 comments · Fixed by #798
Labels
bug Something isn't working clean-up Code clean-up or refactor

Comments

@joeshaw
Copy link
Member

joeshaw commented Feb 6, 2023

#792 restructured the object store commands, adding object-store-keys. I think we might want to take a step back and aim for consistency in naming. We now have

  • acl and acl-entry
  • dictionary and dictionary-item
  • object-store and object-store-keys
  • secret-store and secret-store-entry

Tough to do anything about acl-entry and dictionary-item at this point (unless we added an alias) but I think there's still time to settle on a convention for object and secret store.

@joeshaw joeshaw added bug Something isn't working clean-up Code clean-up or refactor labels Feb 6, 2023
@Integralist
Copy link
Collaborator

@joeshaw I'm looking to cut a new breaking 6.0.0 release (we already have multiple breaking interface changes merged) so we can totally change acl and dictionaries, as we'll document it as part of the release notes that those interfaces have changed also.

cc @fgsch

@Integralist
Copy link
Collaborator

@joeshaw

So in general, it's tricky trying to decide what to do because the API is so inconsistent.

For example, if you look at the OpenAPI specs for dictionaries it uses 'item' exclusively, but in the specs for config-store although you'll see it mainly uses 'item' it also uses the phrase 'entry' in multiple places. If we look at the specs for the object-store we'll see it uses 'keys' exclusively and for the secret-store it uses 'secret' exclusively.

I personally think 'item' isn't a great name, and that if anything we should lean towards 'entry' which is used more consistently in the CLI at the moment (that's also not a great name but it's a better choice IMHO).

All that said, I think they should all be consistent within the CLI because (and I've discussed this before with @fgsch) the CLI is a different interface to the API and users aren't thinking about (or even know about) the underlying API, so we shouldn't worry that dictionary-item (for example) becomes, let's say, dictionary-entry instead.

I believe we should have the following...

  • acl and acl-entry
  • config-store and config-store-entry (not actually implemented in the CLI yet)
  • dictionary and dictionary-entry
  • object-store and object-store-entry
  • secret-store and secret-store-entry

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working clean-up Code clean-up or refactor
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants