Make a plan for consolidating events #85

Open
opened 2 months ago by kimimaru · 1 comments
Owner

Currently, the project is using native C# events accessible to only application code (only TRBot), and with the introduction of the WIP event dispatcher, there are other events accessible to only external application code (not TRBot).

It would be great to consolidate the event system so both TRBot application code and external applications can listen and react to the same events. This would also help solve problems with client services, as the provided events cannot possibly scale for all services. Some examples of issues with the latter include Twitch-specific events, such as bits, and additional data with each message from each service, including Twitch subscription status for a particular user.

This would also greatly clean up the code and help it scale. Every event would be accessible to external applications as well, greatly increasing the robustness of TRBot as a whole.

Currently, the project is using native C# events accessible to **only application code** (only TRBot), and with the introduction of the WIP [event dispatcher](https://codeberg.org/kimimaru/TRBot/issues/72), there are other events accessible to **only external application code** (not TRBot). It would be great to consolidate the event system so both TRBot application code and external applications can listen and react to the same events. This would also help solve problems with client services, as [the provided events cannot possibly scale for all services](https://codeberg.org/kimimaru/TRBot/src/branch/master/TRBot/TRBot.Connection/EventDelegates.cs). Some examples of issues with the latter include Twitch-specific events, such as bits, and additional data with each message from each service, including Twitch subscription status for a particular user. This would also greatly clean up the code and help it scale. Every event would be accessible to external applications as well, greatly increasing the robustness of TRBot as a whole.
Poster
Owner

I like how the matrix-js-sdk handles their events. It's possible to listen to specific events, or any event, by passing in the event name.

I like how the matrix-js-sdk [handles their events](https://matrix.org/docs/guides/usage-of-the-matrix-js-sdk#sync-and-listen). It's possible to listen to specific events, or any event, by passing in the event name.
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date

No due date set.

Dependencies

This issue currently doesn't have any dependencies.

Loading…
There is no content yet.