About Question enthuware.oce-ejbd.v6.2.418 :

Moderator: admin

Post Reply
supergiu
Posts: 8
Joined: Thu Sep 25, 2014 2:48 pm
Contact:

About Question enthuware.oce-ejbd.v6.2.418 :

Post by supergiu »

Hi,
about this sentence:
To achieve this you also need to set appropriate message retention policy at the destination. A message is guaranteed to be delivered once and only once by a JMS provider if the delivery mode of the message is PERSISTENT and if the destination has a sufficient message retention policy.
Sorry I didn't quite understand what means "sufficient message retention policy".

Thank you very much.

admin
Site Admin
Posts: 10046
Joined: Fri Sep 10, 2010 9:26 pm
Contact:

Re: About Question enthuware.oce-ejbd.v6.2.418 :

Post by admin »

Message retention means for how long is a message retained by the container for delivery if the receiver is not available at that time. See that @Retention annotation here: http://docs.oracle.com/javaee/6/api/jav ... riven.html

HTH,
Paul.
If you like our products and services, please help us by posting your review here.

n4noman
Posts: 4
Joined: Thu Apr 09, 2015 8:44 am
Contact:

Re: About Question enthuware.oce-ejbd.v6.2.418 :

Post by n4noman »

What is the behavior if exception is thrown from onMessage()? Doesn't it redelivers the message?

admin
Site Admin
Posts: 10046
Joined: Fri Sep 10, 2010 9:26 pm
Contact:

Re: About Question enthuware.oce-ejbd.v6.2.418 :

Post by admin »

As per Section 5.4.18, if a message-driven bean uses bean-managed transaction demarcation and throws a , the container should not acknowledge the message. Therefore the message will be redelivered.

Or you can use container managed transactions with transaction attribute of REQUIRED. In this case also the message will be redelivered.

But both of the above assume that the receiver is up. They may not work if the receiver is not present.
If you like our products and services, please help us by posting your review here.

Post Reply

Who is online

Users browsing this forum: No registered users and 31 guests