Skip to content

[v0.15] Migrate events generation to new interface#4804

Merged
weyfonk merged 1 commit into
rancher:release/v0.15from
weyfonk:0.15-migrate-events
Mar 12, 2026
Merged

[v0.15] Migrate events generation to new interface#4804
weyfonk merged 1 commit into
rancher:release/v0.15from
weyfonk:0.15-migrate-events

Conversation

@weyfonk
Copy link
Copy Markdown
Contributor

@weyfonk weyfonk commented Mar 11, 2026

Backport of #4678 to v0.15.
Refers to #4765.

Additional Information

Checklist

- [ ] I have updated the documentation via a pull request in the
fleet-docs repository.

* Migrate events generation to new interface

With `GetEentRecorderFor` being deprecated, controllers now use the new
`GetEventRecorder` method, returning an `events.EventRecorder` instead
of a `record.EventRecorder` interface.

* Fix expectations on source component

When using the new event recorder interface, the recorder does not
populate the source component anymore; instead, the emitter can be
checked through `ReportingController`.
Besides, job creation and deletion actually happen _twice_ when
re-creating a job.

* Use formatting placeholders for errors in events

This should prevent events from containing malformed messages, if
error messages ever contain `%` symbols.
@weyfonk weyfonk requested a review from a team as a code owner March 11, 2026 17:23
@weyfonk weyfonk changed the title Migrate events generation to new interface [v0.15] Migrate events generation to new interface Mar 11, 2026
@weyfonk weyfonk merged commit a72317d into rancher:release/v0.15 Mar 12, 2026
22 checks passed
thardeck added a commit that referenced this pull request Mar 19, 2026
thardeck added a commit that referenced this pull request Mar 19, 2026
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