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

ApiServerSource stored version v1 and migration tool #4655

Merged
merged 1 commit into from
Jan 6, 2021

Conversation

pierDipi
Copy link
Member

@pierDipi pierDipi commented Dec 15, 2020

Fixes #4189

Proposed Changes

  • ApiServerSource stored version v1
  • Add migration tool

Release Note

Action Required: You need to run the storage migration tool after the upgrade to migrate from v1beta1 to v1 `apiserversources.sources.knative.dev` resources.

@knative-prow-robot knative-prow-robot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Dec 15, 2020
@google-cla google-cla bot added the cla: yes Indicates the PR's author has signed the CLA. label Dec 15, 2020
@knative-prow-robot knative-prow-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Dec 15, 2020
@knative-prow-robot knative-prow-robot added the area/test-and-release Test infrastructure, tests or release label Dec 15, 2020
@knative-prow-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: pierDipi

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

@knative-prow-robot knative-prow-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Dec 15, 2020
@codecov
Copy link

codecov bot commented Dec 15, 2020

Codecov Report

Merging #4655 (5783852) into master (ca2def5) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #4655   +/-   ##
=======================================
  Coverage   81.31%   81.31%           
=======================================
  Files         290      290           
  Lines        8176     8176           
=======================================
  Hits         6648     6648           
  Misses       1128     1128           
  Partials      400      400           
Impacted Files Coverage Δ
pkg/apis/duck/v1/channelable_types.go 97.95% <ø> (ø)
pkg/apis/duck/v1/register.go 100.00% <ø> (ø)
pkg/apis/duck/v1alpha1/register.go 100.00% <ø> (ø)
pkg/apis/eventing/v1/broker_lifecycle_mt.go 100.00% <ø> (ø)
pkg/apis/eventing/v1/broker_types.go 66.66% <ø> (ø)
pkg/apis/eventing/v1/register.go 80.00% <ø> (ø)
pkg/apis/eventing/v1/test_helper.go 83.33% <ø> (ø)
pkg/apis/eventing/v1/trigger_defaults.go 100.00% <ø> (ø)
pkg/apis/eventing/v1/trigger_lifecycle.go 45.00% <ø> (ø)
pkg/apis/eventing/v1/trigger_types.go 100.00% <ø> (ø)
... and 52 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ca2def5...7b18c9b. Read the comment docs.

@pierDipi pierDipi changed the title [WIP] ApiServerSource stored version v1 and migration tool ApiServerSource stored version v1 and migration tool Dec 15, 2020
@knative-prow-robot knative-prow-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Dec 15, 2020
@zhongduo
Copy link
Contributor

Having the postinstall package makes sense to me, how did we work around this before?

@pierDipi
Copy link
Member Author

We did the same thing, we use this everywhere: https://github.com/knative/eventing/blob/master/config/core/placeholder.go#L17

@zhongduo
Copy link
Contributor

We did the same thing, we use this everywhere: https://github.com/knative/eventing/blob/master/config/core/placeholder.go#L17

oh, sorry, I means how do we work around other cases that requires post install in upgrade test. I am guessing this is not the first time we need this for upgrade.

Signed-off-by: Pierangelo Di Pilato <pierangelodipilato@gmail.com>
@pierDipi
Copy link
Member Author

/retest

@lionelvillard
Copy link
Member

Pinging operation: @houshengbo @Cynocracy

LGTM

@zhongduo for final LGTM since you've been looking at this one.

Comment on lines +98 to +106
if [ -d "${YAML_REPO_ROOT}/config/post-install" ]; then

readonly EVENTING_POST_INSTALL_YAML=${YAML_OUTPUT_DIR}/"eventing-post-install.yaml"

echo "Resolving post install manifests"

ko resolve ${KO_FLAGS} -f config/post-install/ | "${LABEL_YAML_CMD[@]}" > "${EVENTING_POST_INSTALL_YAML}"
all_yamls+=(${EVENTING_POST_INSTALL_YAML})
fi
Copy link
Contributor

Choose a reason for hiding this comment

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

This will not use our previous naming styple vX.Y.Z, which makes sense to me but might have some implication of the release tool. So I would like to have someone familiar with the release process to take a look. @n3wscott

Copy link
Member Author

Choose a reason for hiding this comment

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

@lionelvillard is familiar with the release tool and I tested it before submitting the PR, so we're good to go. :)
(A dir vx.y.z in a VCS doesn't make any sense to me)

Copy link
Contributor

Choose a reason for hiding this comment

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

I have to say I totally agree with you! :)

@zhongduo
Copy link
Contributor

zhongduo commented Jan 6, 2021

All LGTM other than the change in the hack. I am not familiar wth the tool, so if someone can confirm we want to use it this way and it works with the release bot, I will lgtm.

@zhongduo
Copy link
Contributor

zhongduo commented Jan 6, 2021

/lgtm

@knative-prow-robot knative-prow-robot added the lgtm Indicates that a PR is ready to be merged. label Jan 6, 2021
@knative-prow-robot knative-prow-robot merged commit 653febd into knative:master Jan 6, 2021
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. area/test-and-release Test infrastructure, tests or release cla: yes Indicates the PR's author has signed the CLA. lgtm Indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Make ApiServerSource v1 the stored version and add a migration tool
4 participants