[cdi-dev] [JBoss JIRA] (CDI-223) Clarify that any EJB "remote" invocation which doesn't occur when an existing request context is active, starts/ends it's own request context

Mark Struberg (JIRA) jira-events at lists.jboss.org
Mon Apr 30 06:08:17 EDT 2012


    [ https://issues.jboss.org/browse/CDI-223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12688733#comment-12688733 ] 

Mark Struberg commented on CDI-223:
-----------------------------------

The same should happen for @Asynchronous and @Timer, JMS etc. But there is already a section which states exactly that:

6.7.1 Request Context Lifecycle 
The request scope is active:
...
* during any remote method invocation of any EJB, during any asynchronous method invocation of any EJB, during any call to an EJB timeout method and during message delivery to any EJB message-driven bean, and ...

+
The request context is destroyed:
 ...
 * after the EJB remote method invocation, asynchronous method invocation, timeout or message delivery completes, or
 ...

This pretty much implies what you wrote.


What's imo missing is @Timer.

Btw, there is atm a HUGE difference between remote and local EJB invocations!
An example: Imagine a @RequestScoped User CDI bean which gets injected into a @Stateless EJB. Your User will _not_ be available for injection on the remote side! But this would perfectly work for a @Stateless bean which is local.

                
> Clarify that any EJB "remote" invocation which doesn't occur when an existing request context is active, starts/ends it's own request context
> ---------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: CDI-223
>                 URL: https://issues.jboss.org/browse/CDI-223
>             Project: CDI Specification Issues
>          Issue Type: Clarification
>            Reporter: Pete Muir
>
> This should apply to JVM-local or JVM-remote remote invocations

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the cdi-dev mailing list