Skip to content

fix: keep comparableResourceVersions when copying a dependent resource's informer configuration - #3625

Open
afalhambra-hivemq wants to merge 1 commit into
operator-framework:nextfrom
afalhambra-hivemq:fix/comparable-resource-versions-3624
Open

afalhambra-hivemq wants to merge 1 commit into
operator-framework:nextfrom
afalhambra-hivemq:fix/comparable-resource-versions-3624

Conversation

@afalhambra-hivemq

@afalhambra-hivemq afalhambra-hivemq commented Sep 17, 2026

Copy link
Copy Markdown
Contributor

updateFrom wasn't copying comparableResourceVersions, so it fell back to the default and setting it on a dependent resource had no effect. One line, plus a test that fails without it.

Worth noting it's a real behaviour change for anyone who set it to false on a dependent: they now actually get the temporary resource cache disabled, so read-your-own-write is off for that secondary. That's what they asked for, but they haven't been getting it.

Fixes #3624

Copilot AI lite review requested due to automatic review settings September 17, 2026 15:32
@coderabbitai

coderabbitai Bot commented Sep 17, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Advanced

Run ID: c4a71291-895d-467d-a51e-96d42da6014d

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@openshift-ci
openshift-ci Bot requested review from metacosm and xstefank September 17, 2026 15:32

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Warning

Copilot couldn't run its full agentic review because it didn't start before the timeout. Make sure your repository has a runner available, or add a copilot-code-review.yml file specifying one with the runs-on attribute. See the docs for more details.

Pull request overview

Fixes propagation of comparableResourceVersions when copying informer configuration to dependent resources, ensuring the explicitly configured value is preserved.

Changes:

  • Copy comparableResourceVersions in InformerEventSourceConfiguration#updateFrom(...).
  • Add a regression test verifying updateFrom preserves comparableResourceVersions instead of falling back to defaults.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
operator-framework-core/src/main/java/io/javaoperatorsdk/operator/api/config/informer/InformerEventSourceConfiguration.java Ensures updateFrom copies comparableResourceVersions from the source informer config.
operator-framework-core/src/test/java/io/javaoperatorsdk/operator/api/config/InformerEventSourceConfigurationTest.java Adds a regression test that fails without the new copy behavior.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

…e's informer configuration

Signed-off-by: Antonio Fernandez Alhambra <antonio.alhambra@hivemq.com>
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