Reprocess messages which are not Ack-back by consumer

@Anton, I tried some variations on local transacted sessions. If I understand correctly, here’s your sequence of receive messages:

  1. Received, commit
  2. Received, commit
  3. Received, rollback
    What happens then? Do you receive messages 4 and 5, or do you close the flow after getting 3? How are you receiving the messages, usings IFlow.ReceiveMsg()?

Regarding MaxUnackedMessages, messages on a flow are sent using a windowing scheme. This window size of messages can be sent to the application before the broker stops sending messages and waits for an ack to be received. It only applies if you are setting the Flow Property AckMode to ClientAck and manually acknowledging the messages. If you’re using Ackmode AutoAck, the acknowledgement of the message will be sent as soon as the Delegate returns.

So, in your case, if you’re using ClientAck, you’ll have MaxUnackedMessages waiting for your application to process. If you receive and don’t call .ack() on the message, when you close the flow the message will be marked as undelivered, just as if you’d called .rollback()