0 Replies Latest reply: Aug 4, 2012 10:40 AM by bansi lal RSS

JBOSS ActiveMQ results in frequent Production Outages

bansi lal Newbie

I found in the Inbound flow the PatientRegistrationRequestHandler.java class has

method processObjects()  which has  following code snippet:

 

// Persist activity

activity = persistChange(serviceXml, basechange, integration);

// Send Message to Queue

sendMessageToQueue(activity, IJNDIConstants.SM_INBOUND_QUEUE);

 

Please note neither of these methods have Transaction demarcation defined:

Caller method :  processObjects()

Called methods : persistChange() and sendMessageToQueue()

So I am thinking of following annotations:

 

@TransactionAttribute(TransactionAttributeType.REQUIRES_NEW)

protected PracticePartnerIntegrationActivity persistChange

 

@TransactionAttribute(TransactionAttributeType.REQUIRES_NEW)

protectedvoid sendMessageToQueue(Serializable activity, String queueName)

 

 

Please note I couldn't find either declarative or annotate transaction demarcation except persistence.xml as  enclosed

I am planning to these transaction annotation. Please let me know your thoughts