• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

doubts about configure persistence.xml

Jorge Martinez
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Trying to configure a persistence.xml file I have the next doubts:

1)transaction-type="JTA" means the transaction will be managed by an ejb container? What I have read about JTA is the api used to manage distributed transactions but if we just have one database, why do we need to declare transaction-type="JTA" and not just "RESOURCE LOCAL"?

2) Is this possible to have transaction-type="RESOURCE LOCAL" and have the transactions managed by a EJB container?

3) If I have transaction-type="JTA", is it mandatory to have an element of type jta-data-source?

4)Why is mandatory to have transaction-type="JTA" with jta-data-source element?, why are they related and I cannot just specify properties indicating the datasource?

  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic