[ 
https://issues.apache.org/jira/browse/OWB-447?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12907018#action_12907018
 ] 

Eric Covener commented on OWB-447:
----------------------------------

re: referencing thread-locals beyond @PostConstrut, we already need to do 
_something_ different since the threadlocal CC will be lost during 
serialization.  

One option then is to spill this into a local variable in @PostConstruct, but 
going down this path it becomes clear to me that the better scheme is to create 
a CC in @PostConstruct and use it for all intereptors/decorators.  This 
exploits the fact that the EJB container calls @PostConstrut/@PreDestroy quite 
carefully depending on the lifecyle of the underlying EJB.

> unnecessary contextual/non-contextual distinction in 
> OpenWebBeansEJBIntercpetor
> -------------------------------------------------------------------------------
>
>                 Key: OWB-447
>                 URL: https://issues.apache.org/jira/browse/OWB-447
>             Project: OpenWebBeans
>          Issue Type: Bug
>          Components: Enterprise Web Beans
>    Affects Versions: 1.0.0-alpha-2
>            Reporter: Eric Covener
>            Assignee: Eric Covener
>   Original Estimate: 16h
>  Remaining Estimate: 16h
>
> The separation between contextual and non-contextual is wrong/harmful and 
> unnecessary.  
> * We should be managing a CreationalContext for the lifetime of the 
> interceptor instance and using that for dependent instanes
> * We should not rely on the thread-locals beyond @PostConstruct 
> * Method invocations on non-contextual EJB's must be decoratable

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to