-
Notifications
You must be signed in to change notification settings - Fork 46
Description
I've been wondering whether or not the messages are sent as batch, when using a transaction and ended up here
Rebus.RabbitMq/Rebus.RabbitMq/RabbitMq/RabbitMqTransport.cs
Lines 729 to 735 in 2320f64
| model.BasicPublish( | |
| exchange: exchange, | |
| routingKey: routingKey.RoutingKey, | |
| mandatory: mandatory, | |
| basicProperties: props, | |
| body: message.Body | |
| ); |
From what I understand is, that even though the acknowledges are batched (model.ConfirmSelect()), the messages itself aren't batched, right?
In my research I at least found out that some transport may support that and RabbitMQ is one of them according to this PR rabbitmq/rabbitmq-dotnet-client#368
I wonder if we could have that in RabbitMQ Transport too, preferably as opt-in feature. It's not purely for performance, its more that'd I'd prefer to have either all or none messages being accepted by RabbitMQ rather than having half of them submitted/confirmed and the other half failing when the connection drops or similar.
It doesn't necessary need a public API for batching, just adding it to the transport and using it if the feature been enabled when confirming the message scope