Configure Pre-Acknolwedgement
29.1. Using PRE_ACKNOWLEDGE This can be configured in the hornetq-jms.xml file on the connection factory like this: true Alternatively, to use pre-acknowledgement mode using the JMS API, create a JMS Session with the HornetQSession.PRE_ACKNOWLEDGE constant. // messages will be acknowledge on the server *before* being delivered to the client Session session = connection.createSession(false, HornetQSession.PRE_ACKNOWLEDGE); Or you can set pre-acknowledge directly on the HornetQConnectionFactory instance using the setter method. To use pre-acknowledgement mode using the core API you can set it directly on the ClientSessionFactory instance using the setter method.