Skip to content

Conversation

@mclasmeier
Copy link
Contributor

@mclasmeier mclasmeier commented Nov 19, 2025

This PR adds support for custom predicates to filter reconciliation events, which is critical for multi-controller scenarios where status-only updates should not trigger expensive helm dry-runs.

Changes:

  • Add customPredicates []predicate.Predicate field to Reconciler
  • Add WithPredicate() option to configure custom predicates
  • Update setupWatches() to include custom predicates in watch configuration

Example usage:
reconciler.WithPredicate(predicate.GenerationChangedPredicate{})

This allows operators to skip reconciliation when only status/metadata changes, preventing unnecessary helm dry-runs that can cause significant load in environments with many CRs.

This PR has been mostly written by AI.

This adds support for custom predicates to filter reconciliation events,
which is critical for multi-controller scenarios where status-only updates
should not trigger expensive helm dry-runs.

Changes:
- Add customPredicates []predicate.Predicate field to Reconciler
- Add WithPredicate() option to configure custom predicates
- Update setupWatches() to include custom predicates in watch configuration

Example usage:
  reconciler.WithPredicate(predicate.GenerationChangedPredicate{})

This allows operators to skip reconciliation when only status/metadata
changes, preventing unnecessary helm dry-runs that can cause significant
load in environments with many CRs.
@mclasmeier mclasmeier marked this pull request as ready for review November 19, 2025 08:12
@mclasmeier mclasmeier requested a review from porridge November 19, 2025 08:13
@mclasmeier mclasmeier merged commit ab3c1f4 into main Nov 19, 2025
6 of 8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants