You are concerned with messages being received systematically. You designed Message-Driven beans (MDB) to guarantee the most reliable way to consume messages.
In which three scenarios would JMS always redeliver a message? (Choose three.)
An MDB pool processes each message at least once. Potentially, a message can be process more than once:
* If an application fails, a transaction rolls back, or the hosting server instance fail during or after the onMessage() method completes but before the message is acknowledged or committed, the message will be redelivered and processed again.
* Non-persistent messages are also redelivered in the case of failure, except for the case where the message's host JMS server shuts down or crashes, in which case the messages are destroyed.
To ensure that a message is processed exactly once, use container-managed transactions so that failures cause transactional MDB work to rollback and force the message to be redelivered.
Currently there are no comments in this discussion, be the first to comment!