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

Bump CAPI to v1.5.0 #3707

Merged
merged 1 commit into from
Aug 14, 2023
Merged

Conversation

mboersma
Copy link
Contributor

@mboersma mboersma commented Jul 11, 2023

What type of PR is this?

/kind cleanup

What this PR does / why we need it:

Updates CAPI to v1.5.0 and all that entails.

Which issue(s) this PR fixes:

Fixes #3680
Closes #3751
Closes #3773

Special notes for your reviewer:

  • cherry-pick candidate

TODOs:

  • squashed commits
  • includes documentation
  • adds unit tests

Release note:

Bump CAPI to v1.5.0

@k8s-ci-robot k8s-ci-robot added release-note Denotes a PR that will be considered when it comes time to generate release notes. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Jul 11, 2023
@k8s-ci-robot k8s-ci-robot added the size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. label Jul 11, 2023
@mboersma
Copy link
Contributor Author

/retitle [WIP] Bump CAPI to v1.5.0-rc.0

@k8s-ci-robot k8s-ci-robot changed the title Bump CAPI to v1.5.0 [WIP] Bump CAPI to v1.5.0-rc.0 Jul 11, 2023
@k8s-ci-robot k8s-ci-robot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jul 11, 2023
@mboersma
Copy link
Contributor Author

I have a handle on fixing the remaining errors related to controller-runtime, except for this one:

# github.com/Azure/azure-service-operator/v2/api/resources/v1api20200601
../../../pkg/mod/github.com/!azure/azure-service-operator/v2@v2.1.0/api/resources/v1api20200601/resource_group_types_gen.go:178:29: cannot use &ResourceGroup{} (value of type *ResourceGroup) as admission.Validator value in variable declaration: *ResourceGroup does not implement admission.Validator (wrong type for method ValidateCreate)
		have ValidateCreate() error
		want ValidateCreate() (admission.Warnings, error)
make: *** [Makefile:198: manager] Error 1

@nojnhuh does this imply we need a new release of ASO?

@nojnhuh
Copy link
Contributor

nojnhuh commented Jul 11, 2023

I have a handle on fixing the remaining errors related to controller-runtime, except for this one:

# github.com/Azure/azure-service-operator/v2/api/resources/v1api20200601
../../../pkg/mod/github.com/!azure/azure-service-operator/v2@v2.1.0/api/resources/v1api20200601/resource_group_types_gen.go:178:29: cannot use &ResourceGroup{} (value of type *ResourceGroup) as admission.Validator value in variable declaration: *ResourceGroup does not implement admission.Validator (wrong type for method ValidateCreate)
		have ValidateCreate() error
		want ValidateCreate() (admission.Warnings, error)
make: *** [Makefile:198: manager] Error 1

@nojnhuh does this imply we need a new release of ASO?

Yes, that's what it looks like to me. ASO is currently on controller-runtime 0.13:
https://github.com/Azure/azure-service-operator/blob/7131774f3f7eb7cc65e431a30eafcb1ab363921f/v2/go.mod#L42

@nojnhuh
Copy link
Contributor

nojnhuh commented Jul 11, 2023

A temporary alternative to waiting for an ASO release would be ripping out all of our ASO resource group stuff.

@mboersma
Copy link
Contributor Author

I opened a request for controller-runtime v0.15.0 support at Azure/azure-service-operator#3137. Hopefully they're ok with upgrading–it is a breaking change.

@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jul 11, 2023
@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jul 11, 2023
@Jont828
Copy link
Contributor

Jont828 commented Jul 14, 2023

@mboersma Yeah that's unfortunate that the versions of controller runtime don't line up. Is there anything we can do for that besides wait for them to release a new version after upgrading to v0.15.0?

Copy link
Contributor

@Jont828 Jont828 left a comment

Choose a reason for hiding this comment

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

LGTM pending the ASO issue

@mboersma
Copy link
Contributor Author

mboersma commented Jul 14, 2023

Is there anything we can do for that besides wait...?

We could back out the current ASO implementation for resource groups if need be, but that wouldn't really change anything, just buy some more time.

Maybe we could make an adaptor-type struct that would override ValidateCreate and the other methods and just return an empty admission.Warnings to satisfy the new func signatures. I've been looking around though and it's difficult to see where that code would go.

@Jont828
Copy link
Contributor

Jont828 commented Jul 17, 2023

Sounds good. Do you have an idea of when we want to get this PR in? We would need to get this in order to merge #3736 as it requires bumping to v1.5 as well.

@mboersma
Copy link
Contributor Author

when we want to get this PR in?

As soon as we can after the CAPI release, as always (planned for July 25), but we will also need to get a new ASO release and we don't control that timeline. The good news is that team pounced on our request and already have a PR in review that upgrades controller-runtime to match CAPI 1.5, so hopefully an ASO release isn't far away.

@mboersma mboersma added this to the v1.11 milestone Jul 18, 2023
@nojnhuh
Copy link
Contributor

nojnhuh commented Jul 20, 2023

@mboersma Here are the changes to include ASO v2.2.0 which includes controller-runtime 0.15: 28b88459

It looks like ASO's CRD manifest and docker image for the new release aren't out yet, but I've asked about that in Slack and did a quick smoke test with locally-built versions and I expect everything to work once things are published.

@nojnhuh
Copy link
Contributor

nojnhuh commented Jul 20, 2023

It looks like ASO's CRD manifest and docker image for the new release aren't out yet, but I've asked about that in Slack and did a quick smoke test with locally-built versions and I expect everything to work once things are published.

ASO release kinks appear to have been worked out.

@mboersma mboersma changed the title [WIP] Bump CAPI to v1.5.0-rc.0 [WIP] Bump CAPI to v1.5.0-rc.1 Jul 21, 2023
@mboersma
Copy link
Contributor Author

/retest

@mboersma
Copy link
Contributor Author

@Jont828 AFAICT it's ready to go, but we've had several flakes in the main e2e test, including the one I noted above. That test hasn't been that reliable, and the flakes seem to be similar to ones on other PRs.

My only concern is that perhaps v1.5.0 is introducing some further instability there, but it's really hard to discern. I haven't been able to reproduce any of these failures, nor track down any specifics through the logs. They don't seem to be related to this PR, but I can't say so for sure.

@Jont828
Copy link
Contributor

Jont828 commented Aug 14, 2023

Sounds good, I'm comfortable moving this forward if we're seeing similar flakes in other PRs.

@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Aug 14, 2023
@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Aug 14, 2023
@mboersma
Copy link
Contributor Author

Rebased due to a collision in test code from #3826.

@CecileRobertMichon
Copy link
Contributor

I looked at the e2e test history and I don't see a pattern in the failures

@mboersma
Copy link
Contributor Author

Rebased again due to collision in go.sum with #3827.

@willie-yao
Copy link
Contributor

/lgtm

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

LGTM label has been added.

Git tree hash: 93fa01bf8fc44fc51c13bc358dfa977ef4f6e75b

@mboersma
Copy link
Contributor Author

/test pull-cluster-api-provider-azure-e2e
/test pull-cluster-api-provider-azure-e2e-optional

@mboersma
Copy link
Contributor Author

/test pull-cluster-api-provider-azure-e2e-optional

@@ -68,15 +69,15 @@ var (
)

// validateCluster validates a cluster.
func (c *AzureCluster) validateCluster(old *AzureCluster) error {
func (c *AzureCluster) validateCluster(old *AzureCluster) (admission.Warnings, error) {
Copy link
Contributor

Choose a reason for hiding this comment

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

this is really cool! we should use those, there are a few places where I'm sure they'd be useful

Copy link
Contributor

@CecileRobertMichon CecileRobertMichon left a comment

Choose a reason for hiding this comment

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

/lgtm
/approve
/hold

feel free to remove hold when optional tests have passed

@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 Aug 14, 2023
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: CecileRobertMichon

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 Aug 14, 2023
@mboersma
Copy link
Contributor Author

/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 Aug 14, 2023
@mboersma
Copy link
Contributor Author

/override pull-cluster-api-provider-azure-apidiff

@k8s-ci-robot
Copy link
Contributor

@mboersma: Overrode contexts on behalf of mboersma: pull-cluster-api-provider-azure-apidiff

In response to this:

/override pull-cluster-api-provider-azure-apidiff

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot k8s-ci-robot merged commit bf6453e into kubernetes-sigs:main Aug 14, 2023
27 checks passed
@mboersma mboersma deleted the capi-one-five-zero branch August 14, 2023 23:11
@Jont828
Copy link
Contributor

Jont828 commented Aug 14, 2023

We made it!

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. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files.
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

CAPI v1.5.0-beta.0 has been released and is ready for testing
8 participants