This week's book giveaway is in the Kotlin forum.
We're giving away four copies of Kotlin in Action and have Dmitry Jemerov & Svetlana Isakova on-line!
See this thread for details.
Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Theorical questions about JPA  RSS feed

 
Rodrigo Pagliares
Greenhorn
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.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!