Last week, we had the author of TDD for a Shopping Website LiveProject. Friday at 11am Ranch time, Steven Solomon will be hosting a live TDD session just for us. See for the agenda and registration link
Last week, we had the author of TDD for a Shopping Website LiveProject. Friday at 11am Ranch time, Steven Solomon will be hosting a live TDD session just for us. See for the agenda and registration link
  • 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
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

EJB Container provides Transactional Services which is exposed through through JTA API .

 
Ranch Hand
Posts: 2234
Eclipse IDE Firefox Browser Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi

This line is taken from the book called as Mastering EJB 3.0

The EJB Container provides Transactional Services .The Transactional Services is exposed through through JTA API .

Please tell me what dos it mean by this actually ??
 
best scout
Posts: 1294
Scala IntelliJ IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Ravi,

basically it means what it says :-) Every JEE compliant container provides services for transaction handling based on the JTA API. Then in your code it's usually enough to provide a minimum of declarative metadata (=annotations or XML) to use these transaction services of the container for your business interface methods etc.

Marco
 
Ravi Kiran Va
Ranch Hand
Posts: 2234
Eclipse IDE Firefox Browser Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Macro Once again .

Say for example if i used



Please tell me is this above code anywhere will be related to JTA??

Thank you
 
Marco Ehrentreich
best scout
Posts: 1294
Scala IntelliJ IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You're welcome ;-)

Your example is related to the JTA because JTA is the way a JEE container implements its transaction services. The JEE transaction annotations are just a declarative way to configure the exact transaction requirements if the defaults don't fit your needs!

Another way would be to use bean managed transaction where you would have to access the JTA directly in your source code but usually it's a lot better to let the container do this for you and only use the annotations.

I hope that makes it a little bit clearer. JTA is the way how transaction services are realized under the hood in a compliant JEE application server.

Btw.: If you don't specify some annotations there's simply a default behavior which is then of course more or less hidden. Every method which is part of th business interface of a session bean uses @TransactionAttribute(REQUIRED) as its default for example as long as you don't explicitly override this behavior.

Marco
 
Ravi Kiran Va
Ranch Hand
Posts: 2234
Eclipse IDE Firefox Browser Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank you it was nice explanation.
 
There will be plenty of time to discuss your objections when and if you return. The cargo is this tiny ad:
free, earth-friendly heat - a kickstarter for putting coin in your pocket while saving the earth
https://coderanch.com/t/751654/free-earth-friendly-heat-kickstarter
reply
    Bookmark Topic Watch Topic
  • New Topic