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

*: remove plugin minor/patch versions #1547

Conversation

estroz
Copy link
Contributor

@estroz estroz commented Jun 3, 2020

Plugin versions are now considered single numbers with optional "v" prefix and stability "alpha" or "beta" suffix, ex. "v2-alpha". Minor and patch version changes are poorly defined and may constitute breaking changes; having a single version number makes versioning simpler and permits breaking changes to be grouped into one "major" release for a plugin. See #1519 for more details.

  • *: remove references to minor and patch versions for plugins
  • pkg/plugin: implement a Version type returned by Base.Version() that is easily parsed and validated
  • pkg/cli: simplify plugin resolver given the minor/patch number drop

Note: This change will affect project configs with layout: go.kubebuilder.io/v2.0.0, but because this value was not scaffolded by a released version of kubebuilder we shouldn't have to migrate anyone.

/cc @DirectXMan12 @joelanford @camilamacedo86

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Jun 3, 2020
@estroz
Copy link
Contributor Author

estroz commented Jun 3, 2020

While this gets reviewed/discussed

/hold

@k8s-ci-robot k8s-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 3, 2020
@estroz estroz force-pushed the chore/remove-plugin-patch-version branch from c3fb531 to 8fa596c Compare June 4, 2020 08:10
@k8s-ci-robot k8s-ci-robot added size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Jun 4, 2020
@estroz
Copy link
Contributor Author

estroz commented Jun 4, 2020

/test pull-kubebuilder-test

@estroz estroz force-pushed the chore/remove-plugin-patch-version branch from 8fa596c to 1b4942a Compare June 4, 2020 08:23
@estroz
Copy link
Contributor Author

estroz commented Jun 4, 2020

Ready for review. It looks like there are a bunch of changes here, but most of them are removal of minor+patch version from comments/strings and centralizing plugin-related code where appropriate.

/hold cancel

@k8s-ci-robot k8s-ci-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 4, 2020
@@ -36,12 +36,13 @@ func TestCLI(t *testing.T) {

// Test plugin types and constructors.
type mockPlugin struct {
name, version string
name string
version plugin.Version
projectVersions []string
Copy link
Member

Choose a reason for hiding this comment

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

I think it is now beyond what we need. but I am ok with 👍

pkg/plugin/plugin.go Outdated Show resolved Hide resolved
pkg/plugin/plugin.go Outdated Show resolved Hide resolved
pkg/plugin/plugin.go Outdated Show resolved Hide resolved
pkg/plugin/plugin.go Outdated Show resolved Hide resolved
pkg/plugin/plugin.go Outdated Show resolved Hide resolved
pkg/plugin/plugin.go Outdated Show resolved Hide resolved
@estroz estroz changed the title *: remove plugin patch version *: remove plugin minor/patch versions Jun 4, 2020
@estroz estroz force-pushed the chore/remove-plugin-patch-version branch from 1b4942a to e689089 Compare June 4, 2020 15:33
@estroz estroz force-pushed the chore/remove-plugin-patch-version branch from e689089 to 7186525 Compare June 4, 2020 15:47
…refix

and stability "alpha" or "beta" suffix, ex. "v2-alpha". Minor and patch
version changes are poorly defined and may constitute breaking changes;
having a single version number makes versioning simpler and permits breaking
changes to be grouped into one "major" release for a plugin.

*: remove references to minor and patch versions for plugins

pkg/plugin: implement a Version type returned by Base.Version() that is
easily parsed and validated

pkg/cli: simplify plugin resolver given the minor/patch number drop
@estroz estroz force-pushed the chore/remove-plugin-patch-version branch from 7186525 to 4f890fc Compare June 4, 2020 16:01
Copy link
Member

@camilamacedo86 camilamacedo86 left a comment

Choose a reason for hiding this comment

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

terrific work @estroz 🥇

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jun 4, 2020
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: camilamacedo86, estroz

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 4, 2020
@k8s-ci-robot k8s-ci-robot merged commit 977eb88 into kubernetes-sigs:master Jun 4, 2020
@estroz estroz deleted the chore/remove-plugin-patch-version branch June 4, 2020 16:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants