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

Initial implementation of the event bus service #976

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from

Conversation

Tharylia
Copy link
Contributor

@Tharylia Tharylia commented Jul 24, 2024

This PR aims to provide an event bus communication channel for cross module interaction within blish core.
Each event identifier is based on the modules namespace and an event id (string) which can be freely choosen.

The content is typed as an object to allow module devs to accept any kind of data.

The actions which are executed for subscribers are designed with async tasks in mind.
Upon dispatching an event, all subscribers are executed in parallel.

If the registering module is dispatching an event but there are no subscribers no exception is thrown.
If the calling module is trying to dispatch an event to the registering module an exception is thrown if there are no subscribers. (Registering module is disabled or the event simple does not exist)

Discussion Reference

All new features must be discussed prior to code review. This is to ensure that the implementation aligns with other design considerations. Please link to the Discord discussion:

https://discord.com/channels/531175899588984842/599270434642460753/1265237773019779142

Is this a breaking change?

Breaking changes require additional review prior to merging. If you answer yes, please explain what breaking changes have been made.

No

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