Class ForeachAwaitPublisher
- Namespace
- Caesar.NotificationPublishers
- Assembly
- Caesar.dll
Default strategy: awaits each handler one after another in registration order. The first exception stops the publish and propagates to the caller.
public sealed class ForeachAwaitPublisher : INotificationPublisher
- Inheritance
-
ForeachAwaitPublisher
- Implements
- Inherited Members
Constructors
ForeachAwaitPublisher()
public ForeachAwaitPublisher()
Methods
Publish(IEnumerable<NotificationHandlerExecutor>, INotification, CancellationToken)
Invokes the handler executors for notification.
public Task Publish(IEnumerable<NotificationHandlerExecutor> handlerExecutors, INotification notification, CancellationToken cancellationToken)
Parameters
handlerExecutorsIEnumerable<NotificationHandlerExecutor>One executor per resolved handler, in registration order.
notificationINotificationThe notification being published.
cancellationTokenCancellationTokenCancellation token.