Skip to content

Conversation

@embik
Copy link
Member

@embik embik commented Oct 8, 2025

Summary

It looks like an unmanaged controller (in controller-rutime? or multicluster-runtime?) doesn't log its reconciler errors unless you pass a logger into it. Thus, tons of errors are swallowed without any indication why.

The "lore" behind this is that in api-syncagent's 0.3 release series, this was working. It was working because the code in controller-runtime 0.19 derived the logger for unmanaged controllers from the passed manager:

https://github.com/kubernetes-sigs/controller-runtime/blob/b901db121e1f53c47ec9f9683fad90a546688c3e/pkg/controller/controller.go#L160

This changed since then (as we are using upstream controller-runtime now, we've bumped dependencies, including controller-runtime), to be specific in this commit.

Thus, we need to pass in a logger now.

What Type of PR Is This?

/kind bug

Related Issue(s)

Fixes #

Release Notes

Correctly log reconciler errors for object sync

@embik embik requested a review from xrstf October 8, 2025 08:37
@kcp-ci-bot kcp-ci-bot added release-note Denotes a PR that will be considered when it comes time to generate release notes. kind/bug Categorizes issue or PR as related to a bug. dco-signoff: yes Indicates the PR's author has signed the DCO. labels Oct 8, 2025
@embik
Copy link
Member Author

embik commented Oct 8, 2025

/cherry-pick release-0.4

@kcp-ci-bot
Copy link
Contributor

@embik: once the present PR merges, I will cherry-pick it on top of release-0.4 in a new PR and assign it to you.

In response to this:

/cherry-pick release-0.4

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@kcp-ci-bot kcp-ci-bot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Oct 8, 2025
@xrstf
Copy link
Contributor

xrstf commented Oct 8, 2025

/approve
/lgtm

@kcp-ci-bot kcp-ci-bot added the lgtm Indicates that a PR is ready to be merged. label Oct 8, 2025
@kcp-ci-bot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 42ae252572dcf9aa7a20360a24ceb60f97568ad1

@kcp-ci-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: xrstf

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kcp-ci-bot kcp-ci-bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Oct 8, 2025
@kcp-ci-bot kcp-ci-bot merged commit 22c6ff2 into kcp-dev:main Oct 8, 2025
10 checks passed
@kcp-ci-bot
Copy link
Contributor

@embik: new pull request created: #105

In response to this:

/cherry-pick release-0.4

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. dco-signoff: yes Indicates the PR's author has signed the DCO. kind/bug Categorizes issue or PR as related to a bug. lgtm Indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants