| Author |
Does EJB Container rollbacks the Transaction in case of a RuntimeException??
|
Ravi Kiran Va
Ranch Hand
Joined: Apr 18, 2009
Posts: 2234
|
|
Hi ,
I am having a query in understanding rollback of the Transactions in case of a RuntimeException .
Please let me know this
While executing a Method in case of a Runtime Exception , will the container will automatically rollback the Transaction ??
Thanks in advance .
|
Save India From Corruption - Anna Hazare.
|
 |
Paul Sturrock
Bartender
Joined: Apr 14, 2004
Posts: 10336
|
|
|
It depends on the transaction attributes of the method.
|
JavaRanch FAQ HowToAskQuestionsOnJavaRanch
|
 |
Ravi Kiran Va
Ranch Hand
Joined: Apr 18, 2009
Posts: 2234
|
|
I have set it to NOT SUPPOURTED , will the rollback of the Transaction will happen in case of a RuntimeException ??
Thanks in advance .
|
 |
Joe Harry
Ranch Hand
Joined: Sep 26, 2006
Posts: 8795
|
|
Ravi Kiran V wrote:I have set it to NOT SUPPOURTED , will the rollback of the Transaction will happen in case of a RuntimeException ??
Thanks in advance .
When you set it to NOT_SUPPORTED, then there is no transaction at all. So RuntimeException won't do anything!
|
SCJP 1.4, SCWCD 1.4 - Hints for you, SCBCD Hints - Demnachst, SCDJWS - Auch Demnachst
Did a rm -R / to find out that I lost my entire Linux installation!
|
 |
 |
|
|
subject: Does EJB Container rollbacks the Transaction in case of a RuntimeException??
|
|
|