-
1. Re: how to stop MDB on Exception after desired number of message re-delivery
mnovak May 4, 2016 8:12 AM (in response to sonyjop)Looks like you need to call start-delivery/stop-delivery operation on MDB deployment programmatically. This should be handled by some controller entity and not by your MDB itself. In case that something happens with database then you would notify this controller which would call stop-delivery on your MDB - take a look at Creaper library which allows to programmatically call management operations for EAP 6 - GitHub - wildfly-extras/creaper: Small library for JBoss AS 7 and WildFly management with a slight bias towards testing
Simple solution could be to have special controller EJB which would periodically check database health and stop/start your MDB. You could also call this EJB to stop delivery from catch block of your MDB.
Just an idea, not sure if there a better tooling for this.
-
2. Re: how to stop MDB on Exception after desired number of message re-delivery
sonyjop May 4, 2016 10:48 AM (in response to mnovak)thanks for replying.. . I will try to consider this opinion too. But my intend is to avoid any complexity and to have this DLQ processing as a manual job where the messages will be verified and decision made to be posted back to the original Q.