[
https://jira.nuxeo.org/browse/NXP-5782?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=83679#action_83679
]
Thierry Delprat commented on NXP-5782:
--------------------------------------
To summarize the problem : If a Stateful EJB3 has an injected fields
(@Resource) that are transient, reactivation will always fail.
What happends :upon reactivation the container tries to reinject transient
fields but fails in a NPE inside the injection code (bean is null because it is
still in process of beeing reactivated)
at
org.jboss.ejb3.stateful.StatefulContainer.invokePostActivate(StatefulContainer.java:669)
at
org.jboss.ejb3.stateful.StatefulBeanContext.postActivate(StatefulBeanContext.java:450)
at
org.jboss.ejb3.cache.simple.StatefulSessionFilePersistenceManager.activateSession(StatefulSessionFilePersistenceManager.java:324)
at
org.jboss.ejb3.cache.simple.SimpleStatefulCache.get(SimpleStatefulCache.java:476)
at
org.jboss.ejb3.cache.simple.SimpleStatefulCache.get(SimpleStatefulCache.java:430)
at
org.jboss.ejb3.stateful.StatefulInstanceInterceptor.invoke(StatefulInstanceInterceptor.java:59)
at
org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)
at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:79)
... 63 more
Caused by: javax.naming.NamingException: Could not dereference object [Root
exception is javax.naming.NamingException: Could not dereference object [Root
exception is java.lang.NullPointerException]]
at org.jnp.interfaces.NamingContext.resolveLink(NamingContext.java:1352)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:817)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:686)
at org.jboss.ejb3.JndiUtil.lookup(JndiUtil.java:44)
at
org.jboss.injection.JndiPropertyInjector.lookup(JndiPropertyInjector.java:75)
... 74 more
Caused by: javax.naming.NamingException: Could not dereference object [Root
exception is java.lang.NullPointerException]
at
org.jnp.interfaces.NamingContext.getObjectInstanceWrapFailure(NamingContext.java:1504)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:822)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:833)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:686)
at javax.naming.InitialContext.lookup(InitialContext.java:392)
at org.jnp.interfaces.NamingContext.resolveLink(NamingContext.java:1346)
... 78 more
Caused by: java.lang.NullPointerException
at
org.jboss.ejb3.EJBContextFactory.getObjectInstance(EJBContextFactory.java:57)
This means @Resource fields can not be transient : the problem is that after
reactivation the EJBContext initially injected is no more valid ...
=> This looks to me like a bug (we never had this issue with JBoss 4.x
> Fix error on DocumentManager when destrying session
> ---------------------------------------------------
>
> Key: NXP-5782
> URL: https://jira.nuxeo.org/browse/NXP-5782
> Project: Nuxeo Enterprise Platform
> Issue Type: Sub-task
> Reporter: Thierry Delprat
> Assignee: Thierry Delprat
> Priority: Critical
> Fix For: 5.4
>
>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.nuxeo.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
_______________________________________________
ECM-tickets mailing list
[email protected]
http://lists.nuxeo.com/mailman/listinfo/ecm-tickets