Table of Contents

Interface IEventPublisher

Namespace
Integrations.Application.Common
Assembly
Integrations.Application.dll

Publishes integration events. Messages are written to the transactional outbox and delivered only when SaveChangesAsync(CancellationToken) commits, so state changes and events never diverge.

public interface IEventPublisher

Methods

PublishAsync<T>(T, CancellationToken)

Queues an event in the outbox; it is sent when the surrounding SaveChangesAsync commits.

Task PublishAsync<T>(T message, CancellationToken cancellationToken) where T : class

Parameters

message T
cancellationToken CancellationToken

Returns

Task

Type Parameters

T