• Post Reply Bookmark Topic Watch Topic
  • New Topic

Theorical questions about JPA

Rodrigo Pagliares
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello folks,

I recently decided to keep an eye on object-relational mapping with JPA and decided to start reading the book Enterprise JavaBeans 3.0 (5th Edition)
by Bill Burke & Richard Monson-Haefel.

Im really enjoying the book and the technology but, as i had time to read only once the chapters about JPA, some doubts still remain. Would you all please help me? sorry if some of these questions have been already answered on other posts...

1 - "after a JTA transaction is finished the transaction scope persistence context is destroyed and the bean instance i no longer managed". When the JTA transaction finishes, in the end of any method?

2 - what about extend persistence context? when the transaction finishes when using this kind of persistence context? after entityManager.getTransaction.commit()?

3 - Can i use dependency injection of EntityManagerFactory and EntityManager on Tomcat with JTA used on persistence.xml? is there any relationship about de use of JTA and dependency injection of EntityManagerFactory and EntityManager ?

4 - "An entity bean cannot depend on any other framework neither be subclasses of another classs". Why should we implement java.io.Serializable?

Thanks in advance.
Happiness is not a goal ... it's a by-product of a life well lived - Eleanor Roosevelt. Tiny ad:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!