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 controller-runtime to latest, remove the controller engine and GVK routed cache #689

Merged
merged 4 commits into from
May 20, 2024

Conversation

negz
Copy link
Member

@negz negz commented May 6, 2024

Description of your changes

This PR does two things:

  • It updates controller-runtime and the Kubernetes dependencies to the latest versions
  • It removes most of pkg/controller - I plan to move this (back) into c/c

I'd like to upgrade controller-runtime, because the latest versions have some promising functionality that may help with realtime compositions. You can now stop an informer within a cache, and stop an informer's event handlers. I believe this could eliminate the need for us to create a cache per controller, thus eliminating the need for the GVK routed cache etc.

Unfortunately there are some breaking changes around the source.Source interface in the latest version of controller-runtime. They break the engine and GVK routed cache implementations.

Rather than refactor things here and in c/c to accommodate the breaking changes, I'd like to move everything into c/c. As far as I know c/c is the only consumer of pkg/controller (except for the Options struct that isn't moving). It's a pain to have to update them in c/cr and then bump c/c. (My bad - I moved the engine here in the first place.)

I'll open a c/c PR that copies pkg/controller.

Deleting these is a breaking change, but I don't think it will affect anyone in practice. Based on the below search, no-one but c/c is actually using these types.

https://github.com/search?q=%22github.com%2Fcrossplane%2Fcrossplane-runtime%2Fpkg%2Fcontroller%22&type=code&p=5

I have:

  • Read and followed Crossplane's contribution process.
  • Run make reviewable test to ensure this PR is ready for review.

How has this code been tested

It's been covered pretty extensively by unit and E2E tests in crossplane/crossplane#5651.

@negz negz added the release/breaking-api-change This PR will include a breaking change to the API when released. label May 6, 2024
negz added a commit to negz/crossplane that referenced this pull request May 6, 2024
This bumps crossplane-runtime, controller-runtime, and k8s.io
dependencies to latest.

Depends on crossplane/crossplane-runtime#689

Signed-off-by: Nic Cope <[email protected]>
negz added a commit to negz/crossplane that referenced this pull request May 7, 2024
This bumps crossplane-runtime, controller-runtime, and k8s.io
dependencies to latest.

Depends on crossplane/crossplane-runtime#689

Signed-off-by: Nic Cope <[email protected]>
negz added a commit to negz/crossplane that referenced this pull request May 7, 2024
This bumps crossplane-runtime, controller-runtime, and k8s.io
dependencies to latest.

Depends on crossplane/crossplane-runtime#689

Signed-off-by: Nic Cope <[email protected]>
negz added a commit to negz/crossplane that referenced this pull request May 7, 2024
This bumps crossplane-runtime, controller-runtime, and k8s.io
dependencies to latest.

Depends on crossplane/crossplane-runtime#689

Signed-off-by: Nic Cope <[email protected]>
negz added a commit to negz/crossplane that referenced this pull request May 9, 2024
This bumps crossplane-runtime, controller-runtime, and k8s.io
dependencies to latest.

Depends on crossplane/crossplane-runtime#689

Signed-off-by: Nic Cope <[email protected]>
negz added a commit to negz/crossplane that referenced this pull request May 10, 2024
This bumps crossplane-runtime, controller-runtime, and k8s.io
dependencies to latest.

Depends on crossplane/crossplane-runtime#689

Signed-off-by: Nic Cope <[email protected]>
negz added a commit to negz/crossplane that referenced this pull request May 11, 2024
This bumps crossplane-runtime, controller-runtime, and k8s.io
dependencies to latest.

Depends on crossplane/crossplane-runtime#689

Signed-off-by: Nic Cope <[email protected]>
negz added a commit to negz/crossplane that referenced this pull request May 14, 2024
This bumps crossplane-runtime, controller-runtime, and k8s.io
dependencies to latest.

Depends on crossplane/crossplane-runtime#689

Signed-off-by: Nic Cope <[email protected]>
@negz negz marked this pull request as ready for review May 14, 2024 01:04
@negz negz requested review from a team as code owners May 14, 2024 01:04
@negz negz requested review from phisco and MisterMX May 14, 2024 01:04
negz added 4 commits May 17, 2024 12:21
It's breaking the dependencies of this module, and its only consumer is
the c/c repo. It should live there instead.

Signed-off-by: Nic Cope <[email protected]>
It requires a newer cel-go dependency than the Kubernetes dependencies,
which makes updating them difficult.

Signed-off-by: Nic Cope <[email protected]>
negz added a commit to negz/crossplane that referenced this pull request May 17, 2024
This bumps crossplane-runtime, controller-runtime, and k8s.io
dependencies to latest.

Depends on crossplane/crossplane-runtime#689

Signed-off-by: Nic Cope <[email protected]>
@negz negz merged commit fc03661 into crossplane:master May 20, 2024
9 checks passed
@negz negz deleted the engine-swap branch May 20, 2024 20:34
negz added a commit to negz/crossplane that referenced this pull request May 20, 2024
This bumps crossplane-runtime, controller-runtime, and k8s.io
dependencies to latest.

Per the below PR, the latest crossplane-runtime doesn't have the
controller engine anymore. It moved into c/c.

crossplane/crossplane-runtime#689

Signed-off-by: Nic Cope <[email protected]>
negz added a commit to negz/crossplane that referenced this pull request May 20, 2024
This bumps crossplane-runtime, controller-runtime, and k8s.io
dependencies to latest.

Per the below PR, the latest crossplane-runtime doesn't have the
controller engine anymore. It moved into c/c.

crossplane/crossplane-runtime#689

Signed-off-by: Nic Cope <[email protected]>
cychiang pushed a commit to cychiang/crossplane that referenced this pull request May 22, 2024
This bumps crossplane-runtime, controller-runtime, and k8s.io
dependencies to latest.

Per the below PR, the latest crossplane-runtime doesn't have the
controller engine anymore. It moved into c/c.

crossplane/crossplane-runtime#689

Signed-off-by: Nic Cope <[email protected]>
Signed-off-by: Chuan-Yen Chiang <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release/breaking-api-change This PR will include a breaking change to the API when released.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants