Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

event stream: refactor to use Eventer interface #24738

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

tgross
Copy link
Member

@tgross tgross commented Dec 19, 2024

Experimental

Add an Eventer interface to the core structs so they can emit their own events, and use this to refactor the eventFromChange function at the core of the event stream.

Ref: #24721 (comment)

Add an `Eventer` interface to the core structs so they can emit their own
events, and use this to refactor the `eventFromChange` function at the core of
the event stream.
@tgross
Copy link
Member Author

tgross commented Dec 19, 2024

Leaving a note here that I don't love this approach. I suspect (but haven't yet checked) that none of these functions will get inlined across packages. This drags the event construction away from the nomad/state package. But maybe that doesn't matter given the FooEvent structs are already defined there.

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.

1 participant