Skip to content

Support new event recorder#675

Merged
scothis merged 2 commits intoreconcilerio:mainfrom
scothis:recorder
Feb 3, 2026
Merged

Support new event recorder#675
scothis merged 2 commits intoreconcilerio:mainfrom
scothis:recorder

Conversation

@scothis
Copy link
Member

@scothis scothis commented Jan 29, 2026

controller-runtime is transition to a new event recorder based on the events.k8s.io Event kind rather the the core Event kind. The previous API is now deprecated, but remains available.

The Config type now exposes both interfaces with the previous version also deprecated as the upstream API it depends on is deprecated in controller-runtime.

To use to the new API users must add events.k8s.io Event to their RBAC permissions for the controller. Test expectations combine both the previous and new API for comparing actual and expected behavior.

The new API allows referencing a related object for an event in addition to an optional human readable notes field. Both are optional.

Changes to provided reconcilers to use the updated API are forthcoming.

controller-runtime is transition to a new event recorder based on the
events.k8s.io Event kind rather the the core Event kind. The previous
API is now deprecated, but remains available.

The Config type now exposes both interfaces with the previous version
also deprecated as the upstream API it depends on is deprecated in
controller-runtime.

To use to the new API users must add events.k8s.io Event to their RBAC
permissions for the controller. Test expectations combine both the
previous and new API for comparing actual and expected behavior.

The new API allows referencing a related object for an event in addition
to an optional human readable notes field. Both are optional.

Changes to provided reconcilers to use the updated API are forthcoming.

Signed-off-by: Scott Andrews <scott@andrews.me>
@codecov
Copy link

codecov bot commented Jan 29, 2026

Codecov Report

❌ Patch coverage is 64.00000% with 18 lines in your changes missing coverage. Please review.
✅ Project coverage is 60.25%. Comparing base (fec6acb) to head (428d313).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
reconcilers/config.go 0.00% 12 Missing ⚠️
testing/recorder.go 81.81% 4 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #675      +/-   ##
==========================================
+ Coverage   60.04%   60.25%   +0.20%     
==========================================
  Files          39       39              
  Lines        3594     3628      +34     
==========================================
+ Hits         2158     2186      +28     
- Misses       1325     1329       +4     
- Partials      111      113       +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Signed-off-by: Scott Andrews <scott@andrews.me>
@scothis scothis marked this pull request as ready for review February 2, 2026 14:53
@scothis scothis requested a review from mamachanko February 2, 2026 14:54
@scothis scothis merged commit 5c1e9d9 into reconcilerio:main Feb 3, 2026
4 checks passed
@scothis scothis deleted the recorder branch February 3, 2026 17:53
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