-
Notifications
You must be signed in to change notification settings - Fork 4
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
Implement EventBus
for RabbitMQ
#5
Labels
Type: enhancement
New feature or request.
Comments
derevnjuk
changed the title
Provide EventBus based on RabitMQ
Implement Mar 22, 2022
EventBus
for RabbitMQ
derevnjuk
added a commit
that referenced
this issue
Apr 13, 2022
derevnjuk
added a commit
that referenced
this issue
Apr 13, 2022
derevnjuk
added a commit
that referenced
this issue
Apr 13, 2022
) relates-to #5 Co-authored-by: Viachaslau <pmstss@gmail.com>
derevnjuk
added a commit
that referenced
this issue
Apr 13, 2022
derevnjuk
added a commit
that referenced
this issue
Apr 14, 2022
pmstss
pushed a commit
that referenced
this issue
Apr 14, 2022
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Provide an implementation based on RabbitMQ. Most communications between the service should be performed using the RPC and the Pub/Sub pattern.
Below you can find a simplified implementation of an event dispatcher for RabbitMQ:
It can be together with
RetryStrategy
to ensure robust and reliable API:We should also provide a simplified implementation of a command dispatcher:
Each event type has a related channel to get events from RabbitMQ. You can then have as many event handlers per channel and event type as needed.
The
register
method should accept a type ofEventHandler
, adding that event handler to the list of handlers that each event can have. If the bus is not subscribed to the event, it creates a new channel with a routing key using an event type so it can receive events when that event is published from any other service.The text was updated successfully, but these errors were encountered: