Table of Contents

Interface IOutboxWriter

Namespace
Silverback.Messaging.Producing.TransactionalOutbox
Assembly
Silverback.Integration.dll

Exposes the methods to write to the outbox.

public interface IOutboxWriter

Remarks

Used by the OutboxProduceStrategy.

Methods

AddAsync(OutboxMessage, ISilverbackContext?, CancellationToken)

Adds the message contained in the specified envelope to the outbox.

Task AddAsync(OutboxMessage outboxMessage, ISilverbackContext? context = null, CancellationToken cancellationToken = default)

Parameters

outboxMessage OutboxMessage

The message to be stored in the outbox.

context ISilverbackContext

The ISilverbackContext in the current scope.

cancellationToken CancellationToken

The cancellation token that can be used to cancel the operation.

Returns

Task

A Task representing the asynchronous operation.

AddAsync(IAsyncEnumerable<OutboxMessage>, ISilverbackContext?, CancellationToken)

Adds the message contained in the specified envelope to the outbox.

Task AddAsync(IAsyncEnumerable<OutboxMessage> outboxMessages, ISilverbackContext? context = null, CancellationToken cancellationToken = default)

Parameters

outboxMessages IAsyncEnumerable<OutboxMessage>

The messages to be stored in the outbox.

context ISilverbackContext

The ISilverbackContext in the current scope.

cancellationToken CancellationToken

The cancellation token that can be used to cancel the operation.

Returns

Task

A Task representing the asynchronous operation.

AddAsync(IEnumerable<OutboxMessage>, ISilverbackContext?, CancellationToken)

Adds the message contained in the specified envelope to the outbox.

Task AddAsync(IEnumerable<OutboxMessage> outboxMessages, ISilverbackContext? context = null, CancellationToken cancellationToken = default)

Parameters

outboxMessages IEnumerable<OutboxMessage>

The messages to be stored in the outbox.

context ISilverbackContext

The ISilverbackContext in the current scope.

cancellationToken CancellationToken

The cancellation token that can be used to cancel the operation.

Returns

Task

A Task representing the asynchronous operation.