tapestry-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From <no-re...@comments.apache.org>
Subject Peter commented on http://tapestry.apache.org/integrating-with-jpa.html
Date Thu, 14 Nov 2013 14:06:07 GMT
    Peter has commented on http://tapestry.apache.org/integrating-with-jpa.html. 
    You can find the comment here:
    Please note that if the comment contains a hyperlink, it must be approved
    before it is shown on the site.

    Below is the reply that was posted:
    The code example for multiple persistence units will trigger an IllegalStateException
within PlasticFieldImpl#claim() "Field entityManager of class UserDAOImpl can not be claimed
by @javax.persistence.PersistenceContext as it is already claimed by @Inject"

As @PersistenceContext is sufficient for injecting, please remove @Inject from this example.

public class UserDAOImpl implements UserDAO {
   @PersistenceContext(unitName = "DemoUnit")
   private EntityManager entityManager;

    With regards,
    The Apache Tapestry Project.

    You are receiving this email because you have subscribed to changes for the tapestry site.
    To stop receiving these emails, unsubscribe from the mailing list that is providing these

To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org

View raw message