Skip to content

Multiple ACK controller shards watch resources conflictΒ #2632

@jas-nik

Description

@jas-nik

Describe the bug
Hi Team,

We have a use case where we deploy ack controllers shards with independent CARM and watch selectors configurations. First shard of ACK controllers is configured to use "team:role" CARM configuration, Cluster scoped (ACK_WATCH_NAMESPACE or ACK_WATCH_SELECTORS are not configured). Second shard of ack controllers using "service:account:role" CARM setup with watch selectors configured

Due to the "team:role" CARM config ACK controller shard running without watch selectors, all ACK resources on the cluster were being reconciled by this controller shard. This reconciliation conflicts with the second ACK controller shard with WATCH selectors.

We added WATCH SELECTOR to the first ACK controller shard running at cluster scope to prevent it from reconciling all resources on the cluster.

The issue now is that the second ACK controller shard which is supposed to reconcile/watch resources is ignoring them.

Restarting both the controllers or scaling down one set of the controllers did not help.

Resource: EC2 SecurityGroup

Steps to reproduce

  • Deploy and configure EC2 controller in two different namespaces one with team ID carm setup and the other with service:account:role CARM setup
  • Add WATCH SELECTOR to only the controller with service:account:role CARM setup
  • Create a set of resources(ec2:securitygroup) that match the selector from the previous step

Expected outcome

  • Both controller shards should be able to reconcile and dynamically manage resources depending on selectors configured.

Environment

  • Kubernetes version - 1.32
  • Using EKS (yes/no), if so version? v1.32.8-eks-e386d34
  • AWS service targeted (S3, RDS, etc.) EC2 - SecurityGroup Resource

Metadata

Metadata

Assignees

Labels

area/runtimeIssues or PRs as related to controller runtime, common reconciliation logic, etcneeds-investigationIndicates an issue needs some investigation.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions