-
Notifications
You must be signed in to change notification settings - Fork 32
Batch processing
elliotritchie edited this page Jul 9, 2012
·
8 revisions
NserviceBus allows for messages to be sent as a batch. Essentially this wraps all of your messages into a single TransportMessage and puts that physical message at the end of a particular queue. NES handles processing of the batch for you automatically by implementing its own unit of work and only committing your changes once the entire batch has been processed. The advantage of doing this is that all your messages will be handled in-order and, if all messages are for the same aggregate, as a single transaction.
Here's how you can send a batch of messages with NServiceBus:
Bus.Send(message1, message2, message3);