[jbosstools-issues] [JBoss JIRA] (JBIDE-12402) Ambiguous EL names in case of producers of alternative bean classes
Viacheslav Kabanovich (JIRA)
jira-events at lists.jboss.org
Fri Aug 10 20:26:06 EDT 2012
[ https://issues.jboss.org/browse/JBIDE-12402?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Viacheslav Kabanovich reassigned JBIDE-12402:
---------------------------------------------
Assignee: Alexey Kazakov (was: Viacheslav Kabanovich)
Alexey, please verify.
> Ambiguous EL names in case of producers of alternative bean classes
> -------------------------------------------------------------------
>
> Key: JBIDE-12402
> URL: https://issues.jboss.org/browse/JBIDE-12402
> Project: Tools (JBoss Tools)
> Issue Type: Bug
> Components: CDI
> Affects Versions: 3.3.0.Final
> Reporter: Alexey Kazakov
> Assignee: Alexey Kazakov
> Fix For: 3.4.0.M1
>
>
> See the example from https://github.com/pmuir/jboss-as-developer-guide/tree/master/quickstarts
> There is org.jboss.as.quickstarts.login.EJBUserManager:
> {code:title=org.jboss.as.quickstarts.login.EJBUserManager|borderStyle=solid}
> ...
> @Named("userManager")
> @RequestScoped
> @Alternative
> @Stateful
> public class EJBUserManager implements UserManager {
> ...
> @Produces
> @Named
> @RequestScoped
> public List<User> getUsers() throws Exception {
> ...
> }
> ...
> }
> {code}
> And there is also another bean org.jboss.as.quickstarts.login.ManagedBeanUserManager:
> {code:title=org.jboss.as.quickstarts.login.ManagedBeanUserManager|borderStyle=solid}
> ...
> @Named("userManager")
> @RequestScoped
> public class ManagedBeanUserManager implements UserManager {
> @SuppressWarnings("unchecked")
> @Produces
> @Named
> @RequestScoped
> public List<User> getUsers() throws Exception {
> ...
> }
> ...
> }
> {code}
> We have two beans with EL name #{users}
> Try to inject it in some bean:
> @Inject List<User> users;
> There is a warning about ambiguous beans that is not correct.
> See WELD-930 for details.
--
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 jbosstools-issues
mailing list