Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Auto Acknowledge 
  • Duplicates Allowed
  • Client Acknowledge
  • Transacted Acknowledgement

Excerpt
hiddentrue

Only for MB 3.2.0. Therefore, this section will be valid for EI 6.1.0.

Configuring per-message acknowledgment

With Per Message Acknowledge we can acknowledge each message as per requirement. Any message that is not acknowledged will go through the same process as when client acknowledged such as the message getting rejected.

Following is a sequence diagram on how an example scenario will work:

 Screen Shot 2016-07-21 at 12.00.00 PM.pngImage Modified

Use the enum org.wso2.andes.jms.Session.PER_MESSAGE_ACKNOWLEDGE available in the andes-client jar or the value 259 when creating the session.

Code Block
import org.wso2.andes.jms.Session;
QueueSession queueSession = queueConnection.createQueueSession(false, Session.PER_MESSAGE_ACKNOWLEDGE);

or,

Code Block
QueueSession queueSession = queueConnection.createQueueSession(false, 259);