Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Spring Transaction Management

 
Manoj Raghuwanshi
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I have a message driven bean created using Spring. Transaction attribute in ejb-jar.xml is 'NotSupported' now if any method in the bean throws RunTimeException then what wil happen? By default if transaction is there spring will rollback the transaction. In this case transaction is not present then how spring will be behave?

Thanks in advance.

Regards,
Manoj
 
Vivek K Singh
Ranch Hand
Posts: 85
Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Spring will manage transactions only if you ask spring to... You will have to create transaction manager and write transaction advice on the method, then on a RuntimeExec the transaction will be rolled back.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic