Table of Contents

Interface IBatchConfigurator<TMessage>

Namespace
MassTransit
Assembly
MassTransit.Abstractions.dll

Batching is an experimental feature, and may be changed at any time in the future.

public interface IBatchConfigurator<TMessage> : IConsumeConfigurator where TMessage : class

Type Parameters

TMessage

Properties

ConcurrencyLimit

Set the maximum number of concurrent batches which can execute at the same time

int ConcurrencyLimit { set; }

Property Value

int

MessageLimit

Set the maximum number of messages which can be added to a single batch

int MessageLimit { set; }

Property Value

int

TimeLimit

Set the maximum time to wait for messages before the batch is automatically completed

TimeSpan TimeLimit { set; }

Property Value

TimeSpan

TimeLimitStart

Sets the starting point for the TimeLimit

BatchTimeLimitStart TimeLimitStart { set; }

Property Value

BatchTimeLimitStart

Methods

Consumer<TConsumer>(IConsumerFactory<TConsumer>, Action<IConsumerMessageConfigurator<TConsumer, Batch<TMessage>>>?)

Specify the consumer factory for the batch message consumer

void Consumer<TConsumer>(IConsumerFactory<TConsumer> consumerFactory, Action<IConsumerMessageConfigurator<TConsumer, Batch<TMessage>>>? configure = null) where TConsumer : class, IConsumer<Batch<TMessage>>

Parameters

consumerFactory IConsumerFactory<TConsumer>
configure Action<IConsumerMessageConfigurator<TConsumer, Batch<TMessage>>>

Configure the consumer pipe

Type Parameters

TConsumer