Skip to content

Add beta registry plugin command (remove alpha plugin)#2137

Merged
mfridman merged 7 commits intomainfrom
buf-beta-plugin-push-2
May 31, 2023
Merged

Add beta registry plugin command (remove alpha plugin)#2137
mfridman merged 7 commits intomainfrom
buf-beta-plugin-push-2

Conversation

@mfridman
Copy link
Member

@mfridman mfridman commented May 30, 2023

This PR removes the old buf alpha plugin {push,delete} commands and moves them to buf beta registry plugin {push, delete}.

Notable changes:

  1. The host is now the remote address, like buf.build, instead of plugins.buf.build (drop subdomain)
  2. The plugin visibility is now mandatory, similar to buf beta registry repository create command

We might want to nest the buf beta plugin command under registry, like buf beta registry plugin {push,delete} .. but this is less an API command and more like buf push, so there's an argument to keep it under buf beta plugin push and eventually promote it to just buf plugin push. Updated in 8622c06

Furthermore, the plugin push command calls docker under the hood, so it's not strictly a registry API command.

  • Add changelog

Copy link
Member

@bufdev bufdev left a comment

Choose a reason for hiding this comment

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

Assuming moved to registry, LGTM

stats.NewCommand("stats", builder),
migratev1beta1.NewCommand("migrate-v1beta1", builder),
studioagent.NewCommand("studio-agent", noTimeoutBuilder),
{
Copy link
Member

Choose a reason for hiding this comment

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

Yea I think id still argue to put this under registry...other commands may be bsr-API-specific, but we call the registry command the subcommand to manage BSR assets

Copy link
Member Author

Choose a reason for hiding this comment

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

Ye that's fair, we'll first need to remove the existing buf beta registry plugin (now deprecated) set of commands to avoid confusion.

Available Commands:
  create      Create a Protobuf plugin
  delete      Delete a Protobuf plugin
  list        List plugins on the specified BSR
  version     Manage Protobuf plugin versions

Copy link
Member

Choose a reason for hiding this comment

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

You can do this in the same PR - beta commands are inherently unstable

Copy link
Member Author

Choose a reason for hiding this comment

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

Done. 8622c06

@mfridman mfridman requested a review from bufdev May 31, 2023 18:50
"github.com/bufbuild/buf/private/buf/cmd/buf/command/alpha/registry/token/tokenlist"
"github.com/bufbuild/buf/private/buf/cmd/buf/command/alpha/workspace/workspacepush"
"github.com/bufbuild/buf/private/buf/cmd/buf/command/beta/migratev1beta1"
"github.com/bufbuild/buf/private/buf/cmd/buf/command/beta/plugin/plugindelete"
Copy link
Member Author

Choose a reason for hiding this comment

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

Oops, we'll also want to move this under /beta/registry/ for consistency

CHANGELOG.md Outdated

- No changes yet.
- Remove `buf beta registry template` commands.
- Move `buf alpha plugin` commands to `buf beta registry plugin` and remove old plugin implementation.
Copy link
Member

@pkwarren pkwarren May 31, 2023

Choose a reason for hiding this comment

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

Maybe be more specific and state that the following old plugin commands are removed:

  • buf beta registry plugin <create|deprecate|list|undeprecate|version>

and that these commands now work with remote plugins:

  • buf beta registry plugin <delete|push>

Is it worth also linking to docs somewhere re: custom plugins or the alpha -> remote plugins/packages migration pages?

@mfridman mfridman changed the title Add beta plugin command (remove alpha plugin) Add beta registry plugin command (remove alpha plugin) May 31, 2023
@mfridman mfridman merged commit aaf2c68 into main May 31, 2023
@mfridman mfridman deleted the buf-beta-plugin-push-2 branch May 31, 2023 19:36
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.

3 participants