[JBoss JIRA] Created: (CDI-147) Are EJB's not deployed in a bean archive eligible for CDI injection
by Stuart Douglas (JIRA)
Are EJB's not deployed in a bean archive eligible for CDI injection
-------------------------------------------------------------------
Key: CDI-147
URL: https://issues.jboss.org/browse/CDI-147
Project: CDI Specification Issues
Issue Type: Clarification
Reporter: Stuart Douglas
If an EJB is deployed in an ejb-jar without a beans.xml, is this EJB eligible for CDI injection of beans deployed in other modules?
The spec says:
"The container performs dependency injection on all session and message-driven bean instances, even those which are not
contextual instances."
To me this sounds like the intent was to allow injection into EJB's looked up from JNDI, does this also mean that EJB's in non bean archives should also be injected?
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 6 months
[JBoss JIRA] (CDI-263) Specializing bean should not declare a name if the specialized bean does
by Jozef Hartinger (JIRA)
Jozef Hartinger created CDI-263:
-----------------------------------
Summary: Specializing bean should not declare a name if the specialized bean does
Key: CDI-263
URL: https://issues.jboss.org/browse/CDI-263
Project: CDI Specification Issues
Issue Type: Bug
Components: Inheritance and Specialization
Reporter: Jozef Hartinger
Assignee: Pete Muir
Priority: Minor
Fix For: 1.1 (Proposed)
The spec currently says:
{quote}
If Y has a name and X declares a non-defaulted bean EL name, the container automatically detects the problem and treats it as a definition error.
{quote}
However, it should say:
{quote}
If Y has a name and X declares a bean EL name, the container automatically detects the problem and treats it as a definition error.
{quote}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 6 months
[JBoss JIRA] (CDI-44) Clarify that interceptors must be implemented using subclassing, and clarify the behaviour of self-invocation
by Pete Muir (JIRA)
[ https://issues.jboss.org/browse/CDI-44?page=com.atlassian.jira.plugin.sys... ]
Pete Muir updated CDI-44:
-------------------------
Assignee: (was: Marius Bogoevici)
> Clarify that interceptors must be implemented using subclassing, and clarify the behaviour of self-invocation
> -------------------------------------------------------------------------------------------------------------
>
> Key: CDI-44
> URL: https://issues.jboss.org/browse/CDI-44
> Project: CDI Specification Issues
> Issue Type: Clarification
> Components: Interceptors
> Affects Versions: 1.0
> Reporter: Stuart Douglas
> Fix For: 1.1 (Proposed)
>
>
> When implementing interception using proxying the behaour of self invocation is quite well defined, if a method is invoked on the proxy it is intercepted, if it is invoked on the actual bean (usually through self-invocation) it is not.
> When implementing interception though sub classing this is much less well definied, and the only way to track if an invocation is intercepted or not is through a thread local flag. At the moment in weld this is reset when a call is made on a client proxy, so if we have an intercepted bean A and a SessionScoped bean B and A invokes B when invokes A the second call to A is intercepted. If however B is pseudo scoped, then the second invocation is not intercepted. The correct behaviour here should be specified by the specification.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 6 months
[JBoss JIRA] (CDI-6) Clarify InjectionTarget method parameters
by Pete Muir (JIRA)
[ https://issues.jboss.org/browse/CDI-6?page=com.atlassian.jira.plugin.syst... ]
Pete Muir reassigned CDI-6:
---------------------------
Assignee: (was: Pete Muir)
> Clarify InjectionTarget method parameters
> -----------------------------------------
>
> Key: CDI-6
> URL: https://issues.jboss.org/browse/CDI-6
> Project: CDI Specification Issues
> Issue Type: Clarification
> Components: Portable Extensions
> Affects Versions: 1.0
> Reporter: Jozef Hartinger
> Priority: Minor
> Fix For: 1.1 (Proposed)
>
>
> For the inject() method, the spec says: "inject() performs dependency injection upon the given object". It is not clear to me what does the "given object" refer two. if the CDI implementation uses proxies to implement interceptors and decorators, I can see two candidates for "the given object":
> - the product of the produce() method including interceptors and decorators -> a proxy
> - the target instance -> the object created by calling a constructor (no interception/decoration)
> Arguments for the first option
> - Let's have and extension that adds additional dependency injection capabilities by providing a custom InjectionTarget implementation and wrapping default InjectionTarget instances with custom ones. The custom InjectionTarget implementation does the additional DI in the inject() method and delegates to the default InjectionTarget instance to finish the injection. This implementation needs a direct access to the target instance (it cannot access field values through a proxy)
> - Interceptor-like behavior - similarity to interceptors, where the InvocationContext.getTarget() returns the (non-intercepted) target instance
> Arguments for the second option
> - the contract of the produce() method says: "produce() calls the constructor annotated @Inject if it exists, or the constructor with no parameters otherwise, as defined in Section 5.5.1, "Injection using the bean constructor", and returns the resulting instance. If the class has inter- ceptors, produce() is responsible for building the interceptors and decorators of the instance." which means it returns an intercepted/decorated instance.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 6 months