Thank you Andy.
I have tried your program.it is no problem.The problem is :
Is your code a XA Transaction?
I tried my codes just from:
http://opensource2.atlassian.com/con...A+++JOTM+usage
Is there error in my code?
Thank you Andy.
I have tried your program.it is no problem.The problem is :
Is your code a XA Transaction?
I tried my codes just from:
http://opensource2.atlassian.com/con...A+++JOTM+usage
Is there error in my code?
I'm not sure I understand your question... my code above uses Spring's TransactionTemplate to surround the JMS code in a transaction. In this example, the TransactionTemplate uses Spring's JtaTransactionManager, which in turn uses JOTM, which provides XA transaction services. So, my code drives the transaction using Spring abstractions, which then use JOTM to provide the actual underlying transaction. Since JOTM is XA, then I think the answer to your question is, "yes, my code is using an XA transaction". As I mention in the message above, it looks like you must be sure that you always call that JmsTemplate within a transaction.Originally Posted by zjnbshifox
If I want make some Database operation in the same XA transaction,I must give these codes in the tt.execute{......} . Is that right??
That's right, you must put the database operation in the same "execute" (or use Spring's declarative transaction ability).Originally Posted by zjnbshifox
- Andy