You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openwebbeans.apache.org by "Mark Struberg (JIRA)" <ji...@apache.org> on 2011/02/28 11:05:37 UTC
[jira] Resolved: (OWB-534) Injection of @PersistenceContext does
not work with abstract/base classes
[ https://issues.apache.org/jira/browse/OWB-534?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Mark Struberg resolved OWB-534.
-------------------------------
Resolution: Duplicate
Fix Version/s: 1.0.1
1.1.0
Assignee: Mark Struberg (was: Gurkan Erdogdu)
> Injection of @PersistenceContext does not work with abstract/base classes
> -------------------------------------------------------------------------
>
> Key: OWB-534
> URL: https://issues.apache.org/jira/browse/OWB-534
> Project: OpenWebBeans
> Issue Type: Bug
> Components: Injection and Lookup
> Affects Versions: 1.0.0
> Reporter: Matthias Weßendorf
> Assignee: Mark Struberg
> Priority: Critical
> Fix For: 1.1.0, 1.0.1
>
> Attachments: OWB-534.zip
>
>
> I am using an "AbstractGenericDao" class for all of my DAOs.
> In there I use @PersistenceContext(unitName = "myUnit") to inject the EntityManager
> The concrete DAO (e.g. EmployeeDao (which extends AbstractGenericDao)) is inject (via @Inject) to a Service IMPL.
> Now, when executing some logic on that DAO, where it delegates to the EntityManager (e.g. em.persist(...);) I am getting a NullPointerException, indicating that the EntityManager is NULL
--
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira