1 Reply Latest reply on Nov 16, 2010 1:08 PM by Alexander Bell

    SFSB with @Named on JBossM5

    Alexander Bell Newbie

      Hi,


      I get the following exception when I wanna deploy the class



      @Stateful
      @Named(value="myManager")
      @ConversationScoped
      @TransactionAttribute(TransactionAttributeType.NOT_SUPPORTED)
      @Local(org.j4fry.business.api.local.IMyManager.class)
      public class SalespointManagerImpl extends AbstractManager implements MyManager {
      ...





      18:55:58,781 ERROR [org.jboss.kernel.plugins.dependency.AbstractKernelController] Error installing to Start: name=vfs:///home/sidux/projects/j4fry/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.0_Runtime_Server1286210827066/deploy/j4fry-ear.ear_WeldBootstrapBean state=Create: org.jboss.weld.exceptions.DeploymentException: WELD-001414 Bean name is ambiguous. Name salespointManager resolves to beans [Session bean [class de.j4fry.business.salespoint.manager.SalespointManagerImpl with qualifiers [@Any @Default @Named]; local interfaces are [SalespointManager], Session bean [class de.j4fry.business.salespoint.manager.SalespointManagerImpl with qualifiers [@Any @Default @Named]; local interfaces are [SalespointManager]]
           at org.jboss.weld.bootstrap.Validator.validateBeanNames(Validator.java:461)
           at org.jboss.weld.bootstrap.Validator.validateDeployment(Validator.java:357)
           at org.jboss.weld.bootstrap.WeldBootstrap.validateBeans(WeldBootstrap.java:436)
           at org.jboss.weld.integration.deployer.env.helpers.BootstrapBean.boot(BootstrapBean.java:118) [:6.0.0.20100911-M5]
           at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [:1.6.0_18]



      I'm running on JBoss M5. With JBoss M4 everything worked fine.
      Any ideas?


      Alex

        • 1. Re: SFSB with @Named on JBossM5
          Alexander Bell Newbie

          sorry wrong code example. the right one:




          @Stateful
          @Named(value="myManager")
          @ConversationScoped
          @TransactionAttribute(TransactionAttributeType.NOT_SUPPORTED)
          @Local(org.j4fry.business.api.local.IMyManager.class)
          public class MyManager extends AbstractManager implements IMyManager {
          ...






          18:55:58,781 ERROR [org.jboss.kernel.plugins.dependency.AbstractKernelController] Error installing to Start: name=vfs:///home/sidux/projects/j4fry/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.0_Runtime_Server1286210827066/deploy/j4fry-ear.ear_WeldBootstrapBean state=Create: org.jboss.weld.exceptions.DeploymentException: WELD-001414 Bean name is ambiguous. Name myManager resolves to beans [Session bean [class de.j4fry.business.salespoint.manager.MyManager with qualifiers [@Any @Default @Named]; local interfaces are [IMyManager], Session bean [class de.j4fry.business.salespoint.manager.MyManager with qualifiers [@Any @Default @Named]; local interfaces are [IMyManager]]
               at org.jboss.weld.bootstrap.Validator.validateBeanNames(Validator.java:461)
               at org.jboss.weld.bootstrap.Validator.validateDeployment(Validator.java:357)
               at org.jboss.weld.bootstrap.WeldBootstrap.validateBeans(WeldBootstrap.java:436)
               at org.jboss.weld.integration.deployer.env.helpers.BootstrapBean.boot(BootstrapBean.java:118) [:6.0.0.20100911-M5]
               at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [:1.6.0_18]