• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Tim Cooke
  • Devaka Cooray
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Rob Spoor
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
Bartenders:
  • Carey Brown
  • Roland Mueller

Nested Transaction

 
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Dear All,
I know that EJB doesnt support nested transactions.
But am confused about this scenario.
Session Bean A exists.
A has following methods A.foo1(),A.foo2().A.foo3()
Transaction attributes for these methods are
RequiredNew,Required,RequiresNew.
foo1() {
foo2();
foo3();
}
So in this case foo1 and thereby foo2 's transaction gets suspended when it calls foo3 ,after foo3 the suspended one resumes again.
Does this scenario comes under Nested Transaction Or seems like Nested Transaction.Pls comment on this.
Also friends pls give me some info about NestedTransactions.I am a bit confused abt this Transaction Model.
 
author
Posts: 3892
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
That's not a nested transaction. The outer transaction scope is suspended while the inner transaction executes. If the outer transaction fails after the inner transaction has completed, then things remain as they are after the completion of the inner transaction.
A "Nested transaction" would mean that if the outer transaction fails the the inner transaction would roll back as well.
Kyle
 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Kyle,
Is the RequiresNew equivalent to the concept of Aitonomous Transaction concept in Oracle 9i?
Thanks
Ravi
 
Kyle Brown
author
Posts: 3892
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have no idea, I'm not familiar with that concept in Oracle 9i.
Kyle
 
permaculture is largely about replacing oil with people. And one tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic