Skip to content

Commit

Permalink
Handlers in this controller fire every Role or RoleBinding change, which
Browse files Browse the repository at this point in the history
can be very often (>1.5 million times in a few hours on 2.7.5 with 1000
RestrictedAdmin users and 3 downstream clusters).

This code existed to correct wrong onerRefs created before Rancher 2.4.7:

https://github.com/rancher/rancher/pull/29184/files#diff-aba184f9956e344293abcd7df23de73e81e0ede82a219e15a3c426afb171cc9dR1-R12

Given that support statements require:

1) upgrading to the latest patch version before a minor version:

https://www.suse.com/support/kb/doc/?id=000020727

"All upgrades should go from the latest to the latest. For instance, if
you are on 2.5.3, you should go to 2.5.latest and then to 2.6.latest.
The stop on 2.5.latest should be about a week to ensure you can catch
any issues before moving forward."

2) not skipping minor versions:

https://www.suse.com/support/kb/doc/?id=000020061

"Avoid skipping minor versions when upgrading. For example: when
upgrading from v2.4.x -> v2.6.x we encourage upgrading v2.4.x ->
v2.5.x -> v2.6.x"

this patch assumes no user will upgrade from 2.4.6 or earlier to 2.7.7
or later without any version in between.
  • Loading branch information
moio committed Nov 14, 2024
1 parent da175ce commit ecd50b6
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 216 deletions.
2 changes: 0 additions & 2 deletions pkg/controllers/management/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ import (
"github.com/rancher/rancher/pkg/controllers/management/node"
"github.com/rancher/rancher/pkg/controllers/management/nodepool"
"github.com/rancher/rancher/pkg/controllers/management/nodetemplate"
"github.com/rancher/rancher/pkg/controllers/management/rbac"
"github.com/rancher/rancher/pkg/controllers/management/restrictedadminrbac"
"github.com/rancher/rancher/pkg/controllers/management/rkeworkerupgrader"
"github.com/rancher/rancher/pkg/controllers/management/secretmigrator"
Expand Down Expand Up @@ -57,7 +56,6 @@ func Register(ctx context.Context, management *config.ManagementContext, manager
clustertemplate.Register(ctx, management)
nodetemplate.Register(ctx, management)
rkeworkerupgrader.Register(ctx, management, manager.ScaledContext)
rbac.Register(ctx, management)
restrictedadminrbac.Register(ctx, management, wrangler)
secretmigrator.Register(ctx, management)
settings.Register(ctx, management)
Expand Down
214 changes: 0 additions & 214 deletions pkg/controllers/management/rbac/legacy_ownerrefs_cleaner.go

This file was deleted.

0 comments on commit ecd50b6

Please sign in to comment.