About Question com.enthuware.ets.scbcd.v5.2.221 :

Moderator: admin

Post Reply
ETS User

About Question com.enthuware.ets.scbcd.v5.2.221 :

Post by ETS User »

java.io.IOException, javax.name.NamingException, javax.ejb.CreateException are checked exceptions. So, how it is possible to be thrown by the message listener method?

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

Re: About Question com.enthuware.ets.scbcd.v5.2.221 :

Post by admin »

You are right. Since the onMessage() method of javax.jms.MessageListener interface does not have any throws clause, a JMS MDB's onMessage() method cannot throw checked exceptions. This has now been fixed.

Thanks a lot for your feedback.
If you like our products and services, please help us by posting your review here.

Przemek

Re: About Question com.enthuware.ets.scbcd.v5.2.221 :

Post by Przemek »

Now the answer is also wrong, because javax.ejb.EJBException is a RuntimeException and it can be thrown from the onMessage() method.

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

Re: About Question com.enthuware.ets.scbcd.v5.2.221 :

Post by admin »

Fixed. Thanks again!
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 34 guests