[
https://issues.jboss.org/browse/JBIDE-19358?page=com.atlassian.jira.plugi...
]
Rastislav Wagner updated JBIDE-19358:
-------------------------------------
Steps to Reproduce:
1. Create CDI 1.2 project, discovery mode annotated
2. Add Bean
{code}
import javax.inject.Singleton;
@Singleton
public class B1 {
}
{code}
3. add another bean
{code}
import javax.enterprise.context.ApplicationScoped;
import javax.inject.Inject;
@ApplicationScoped
public class B2 {
@Inject
private B1 b;
}
{code}
Injection point is satisfied, but it shouldn't be because B1 isnt annotated with bean
defining annotation
was:
1. Create CDI 1.1/1.2 project, discovery mode annotated
2. Add Bean
{code}
import javax.inject.Singleton;
@Singleton
public class B1 {
}
{code}
3. add another bean
{code}
import javax.enterprise.context.ApplicationScoped;
import javax.inject.Inject;
@ApplicationScoped
public class B2 {
@Inject
private B1 b;
}
{code}
Injection point is satisfied, but it shouldn't be because B1 isnt annotated with bean
defining annotation
Singleton bean is discovered by cdi validator
---------------------------------------------
Key: JBIDE-19358
URL:
https://issues.jboss.org/browse/JBIDE-19358
Project: Tools (JBoss Tools)
Issue Type: Bug
Components: cdi
Affects Versions: 4.3.0.Alpha1
Reporter: Rastislav Wagner
Fix For: 4.3.0.Alpha2
@Singleton is pseudo-scope which means its not bean defining annotation and the bean
annotated with this pseudo-scope shouldn't be considered when discovery mode is set to
annotated. However CDI tooling is considering it.
Im not sure if this applies only for CDI 1.2 or also for 1.1 ?
--
This message was sent by Atlassian JIRA
(v6.3.11#6341)