2 Replies Latest reply on Jul 9, 2008 2:03 AM by Andrew Rubinger

    5.0.0CR1: EJB refs across EARs don't work

    Juergen Zimmermann Master

      I'm having 2 different EARs and stateless session beans of the 2nd EAR are referencing stateless session beans of the 1st ear. It worked fine with 4.2.2

      Code of the referenced SLSB in the 1st EAR:

      @Stateless
      public class KundenverwaltungBean implements Kundenverwaltung {
       @SuppressWarnings("unused")
       @PersistenceContext
       private EntityManager em;
      
       @EJB
       private KundenverwaltungDao dao;
      
       @EJB
       @IgnoreDependency
       private Bestellverwaltung bv;
      
       @Resource
       private SessionContext sessionCtx;


      Code of the referencing SLSB in the 2nd EAR:
      @Stateless
      @Remote(KundenverwaltungTestRemote.class)
      public class KundenverwaltungTestBean implements KundenverwaltungTestRemote {
       @EJB
       private Kundenverwaltung kvProxy;


      Deploying the 1st EAR is no problem. When deploying the 2nd EAR server.log has the following records. I tried to add mappedName to the SLSB in the 1st EAR, but the warning below still remains.
      2008-07-09 05:19:33,904 WARN [org.jboss.deployment.MappedReferenceMetaDataResolverDeployer] (HDScanner) Unresolved references exist in JBossMetaData:[testHskaEJB.jar#KundenverwaltungTestBean:AnnotatedEJBReferenceMetaData{name=kvProxy,ejb-ref-type=null,link=null,ignore-dependecy=false,mapped/jndi-name=null,resolved-jndi-name=null,beanInterface=interface de.hska.kundenverwaltung.Kundenverwaltung}, testHskaEJB.jar#BestellverwaltungTestBean:AnnotatedEJBReferenceMetaData{name=bvProxy,ejb-ref-type=null,link=null,ignore-dependecy=false,mapped/jndi-name=null,resolved-jndi-name=null,beanInterface=interface de.hska.bestellverwaltung.Bestellverwaltung}]
      2008-07-09 05:19:34,464 INFO [STDOUT] (HDScanner) ======> Creating interceptor metadata bridge
      2008-07-09 05:19:34,645 INFO [STDOUT] (HDScanner) ======> Creating interceptor metadata bridge
      2008-07-09 05:19:34,915 WARN [org.jboss.injection.EJBRemoteHandler] (HDScanner) EJBTHREE-1289: Using legacy EjbEncInjector, because mappedName for enc "env/de.hska.test.BestellverwaltungTestBean/bvProxy", field "bvProxy" is null (container.environmentRefGroup.annotatedEjbReferences = [AnnotatedEJBReferenceMetaData{name=bvProxy,ejb-ref-type=null,link=null,ignore-dependecy=false,mapped/jndi-name=null,resolved-jndi-name=null,beanInterface=interface de.hska.bestellverwaltung.Bestellverwaltung}])
      2008-07-09 05:19:34,945 WARN [org.jboss.injection.EJBRemoteHandler] (HDScanner) EJBTHREE-1289: Using legacy EjbEncInjector, because mappedName for enc "env/de.hska.test.KundenverwaltungTestBean/kvProxy", field "kvProxy" is null (container.environmentRefGroup.annotatedEjbReferences = [AnnotatedEJBReferenceMetaData{name=kvProxy,ejb-ref-type=null,link=null,ignore-dependecy=false,mapped/jndi-name=null,resolved-jndi-name=null,beanInterface=interface de.hska.kundenverwaltung.Kundenverwaltung}])
      2008-07-09 05:19:34,965 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) Created KernelDeployment for: testHskaEJB.jar
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) installing bean: jboss.j2ee:ear=testHska.ear,jar=testHskaEJB.jar,name=BestellverwaltungTestBean,service=EJB3
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) with dependencies:
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) and demands:
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) jboss.ejb:service=EJBTimerService
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) Class:de.hska.bestellverwaltung.Bestellverwaltung
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) and supplies:
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) jndi:BestellverwaltungTestBean
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) Class:de.hska.test.BestellverwaltungTestRemote
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) jndi:testHska/BestellverwaltungTestBean/remote
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) jndi:testHska/BestellverwaltungTestBean/remote-de.hska.test.BestellverwaltungTestRemote
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) Added bean(jboss.j2ee:ear=testHska.ear,jar=testHskaEJB.jar,name=BestellverwaltungTestBean,service=EJB3) to KernelDeployment of: testHskaEJB.jar
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) installing bean: jboss.j2ee:ear=testHska.ear,jar=testHskaEJB.jar,name=KundenverwaltungTestBean,service=EJB3
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) with dependencies:
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) and demands:
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) Class:de.hska.kundenverwaltung.Kundenverwaltung
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) jboss.ejb:service=EJBTimerService
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) and supplies:
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) Class:de.hska.test.KundenverwaltungTestRemote
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) jndi:testHska/KundenverwaltungTestBean/remote-de.hska.test.KundenverwaltungTestRemote
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) jndi:KundenverwaltungTestBean
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) jndi:testHska/KundenverwaltungTestBean/remote
      2008-07-09 05:19:34,975 INFO [org.jboss.ejb3.deployers.JBossASKernel] (HDScanner) Added bean(jboss.j2ee:ear=testHska.ear,jar=testHskaEJB.jar,name=KundenverwaltungTestBean,service=EJB3) to KernelDeployment of: testHskaEJB.jar
      2008-07-09 05:19:35,416 INFO [org.jboss.ejb3.EJBContainer] (HDScanner) STOPPED EJB: de.hska.test.BestellverwaltungTestBean ejbName: BestellverwaltungTestBean
      2008-07-09 05:19:35,416 ERROR [org.jboss.kernel.plugins.dependency.AbstractKernelController] (HDScanner) Error installing to Start: name=jboss.j2ee:ear=testHska.ear,jar=testHskaEJB.jar,name=BestellverwaltungTestBean,service=EJB3 state=Create
      java.lang.NullPointerException
       at org.jboss.ejb3.proxy.factory.ProxyFactoryHelper.getRemoteAndBusinessRemoteInterfaces(ProxyFactoryHelper.java:617)
       at org.jboss.ejb3.proxy.factory.ProxyFactoryHelper.getJndiName(ProxyFactoryHelper.java:421)
       at org.jboss.ejb3.Ejb3Deployment.getEjbJndiName(Ejb3Deployment.java:377)
       at org.jboss.ejb3.EJBContainer.getEjbJndiName(EJBContainer.java:1427)
       at org.jboss.injection.EjbEncInjector.inject(EjbEncInjector.java:80)
       at org.jboss.ejb3.EJBContainer.start(EJBContainer.java:855)
       at org.jboss.ejb3.session.SessionContainer.start(SessionContainer.java:185)
       at org.jboss.ejb3.stateless.StatelessContainer.start(StatelessContainer.java:202)
       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.reflect.plugins.introspection.ReflectionUtils.invoke(ReflectionUtils.java:56)
       at org.jboss.reflect.plugins.introspection.ReflectMethodInfoImpl.invoke(ReflectMethodInfoImpl.java:110)
       at org.jboss.joinpoint.plugins.BasicMethodJoinPoint.dispatch(BasicMethodJoinPoint.java:66)
       at org.jboss.kernel.plugins.dependency.KernelControllerContextAction$JoinpointDispatchWrapper.execute(KernelControllerContextAction.java:241)
       at org.jboss.kernel.plugins.dependency.ExecutionWrapper.execute(ExecutionWrapper.java:45)
       at org.jboss.kernel.plugins.dependency.KernelControllerContextAction.dispatchExecutionWrapper(KernelControllerContextAction.java:109)
       at org.jboss.kernel.plugins.dependency.KernelControllerContextAction.dispatchJoinPoint(KernelControllerContextAction.java:70)
       at org.jboss.kernel.plugins.dependency.LifecycleAction.installActionInternal(LifecycleAction.java:221)
       at org.jboss.kernel.plugins.dependency.InstallsAwareAction.installAction(InstallsAwareAction.java:54)
       at org.jboss.kernel.plugins.dependency.InstallsAwareAction.installAction(InstallsAwareAction.java:42)
       at org.jboss.dependency.plugins.action.SimpleControllerContextAction.simpleInstallAction(SimpleControllerContextAction.java:62)
       at org.jboss.dependency.plugins.action.AccessControllerContextAction.install(AccessControllerContextAction.java:71)
       at org.jboss.dependency.plugins.AbstractControllerContextActions.install(AbstractControllerContextActions.java:51)
       at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
       at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1392)
       at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:784)
       at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:912)
       at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:834)
       at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:624)
       at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:442)
       at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(BeanMetaDataDeployer.java:88)
       at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(BeanMetaDataDeployer.java:46)
       at org.jboss.deployers.spi.deployer.helpers.AbstractSimpleRealDeployer.internalDeploy(AbstractSimpleRealDeployer.java:62)
       at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(AbstractRealDeployer.java:50)
       at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:174)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:970)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:991)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1023)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:911)
       at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
       at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1392)
       at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:784)
       at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:912)
       at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:834)
       at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:672)
       at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:455)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:594)
       at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:541)
       at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:290)
       at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:221)
       at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
       at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
       at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
       at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
       at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:181)
       at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:205)
       at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
       at java.lang.Thread.run(Thread.java:619)
      2008-07-09 05:19:36,027 INFO [org.jboss.ejb3.EJBContainer] (HDScanner) STOPPED EJB: de.hska.test.KundenverwaltungTestBean ejbName: KundenverwaltungTestBean
      2008-07-09 05:19:36,027 ERROR [org.jboss.kernel.plugins.dependency.AbstractKernelController] (HDScanner) Error installing to Start: name=jboss.j2ee:ear=testHska.ear,jar=testHskaEJB.jar,name=KundenverwaltungTestBean,service=EJB3 state=Create
      java.lang.NullPointerException
       at org.jboss.ejb3.proxy.factory.ProxyFactoryHelper.getRemoteAndBusinessRemoteInterfaces(ProxyFactoryHelper.java:617)
       at org.jboss.ejb3.proxy.factory.ProxyFactoryHelper.getJndiName(ProxyFactoryHelper.java:421)
       at org.jboss.ejb3.Ejb3Deployment.getEjbJndiName(Ejb3Deployment.java:377)
       at org.jboss.ejb3.EJBContainer.getEjbJndiName(EJBContainer.java:1427)
       at org.jboss.injection.EjbEncInjector.inject(EjbEncInjector.java:80)
       at org.jboss.ejb3.EJBContainer.start(EJBContainer.java:855)
       at org.jboss.ejb3.session.SessionContainer.start(SessionContainer.java:185)
       at org.jboss.ejb3.stateless.StatelessContainer.start(StatelessContainer.java:202)
       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.reflect.plugins.introspection.ReflectionUtils.invoke(ReflectionUtils.java:56)
       at org.jboss.reflect.plugins.introspection.ReflectMethodInfoImpl.invoke(ReflectMethodInfoImpl.java:110)
       at org.jboss.joinpoint.plugins.BasicMethodJoinPoint.dispatch(BasicMethodJoinPoint.java:66)
       at org.jboss.kernel.plugins.dependency.KernelControllerContextAction$JoinpointDispatchWrapper.execute(KernelControllerContextAction.java:241)
       at org.jboss.kernel.plugins.dependency.ExecutionWrapper.execute(ExecutionWrapper.java:45)
       at org.jboss.kernel.plugins.dependency.KernelControllerContextAction.dispatchExecutionWrapper(KernelControllerContextAction.java:109)
       at org.jboss.kernel.plugins.dependency.KernelControllerContextAction.dispatchJoinPoint(KernelControllerContextAction.java:70)
       at org.jboss.kernel.plugins.dependency.LifecycleAction.installActionInternal(LifecycleAction.java:221)
       at org.jboss.kernel.plugins.dependency.InstallsAwareAction.installAction(InstallsAwareAction.java:54)
       at org.jboss.kernel.plugins.dependency.InstallsAwareAction.installAction(InstallsAwareAction.java:42)
       at org.jboss.dependency.plugins.action.SimpleControllerContextAction.simpleInstallAction(SimpleControllerContextAction.java:62)
       at org.jboss.dependency.plugins.action.AccessControllerContextAction.install(AccessControllerContextAction.java:71)
       at org.jboss.dependency.plugins.AbstractControllerContextActions.install(AbstractControllerContextActions.java:51)
       at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
       at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1392)
       at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:784)
       at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:912)
       at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:834)
       at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:624)
       at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:442)
       at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(BeanMetaDataDeployer.java:88)
       at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(BeanMetaDataDeployer.java:46)
       at org.jboss.deployers.spi.deployer.helpers.AbstractSimpleRealDeployer.internalDeploy(AbstractSimpleRealDeployer.java:62)
       at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(AbstractRealDeployer.java:50)
       at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:174)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:970)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:991)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1023)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:911)
       at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
       at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1392)
       at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:784)
       at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:912)
       at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:834)
       at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:672)
       at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:455)
       at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:594)
       at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:541)
       at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:290)
       at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:221)
       at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
       at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
       at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
       at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
       at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:181)
       at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:205)
       at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
       at java.lang.Thread.run(Thread.java:619)
      2008-07-09 05:19:36,627 WARN [org.jboss.system.server.profileservice.hotdeploy.HDScanner] (HDScanner) Failed to process changes
      org.jboss.deployers.client.spi.IncompleteDeploymentException: Summary of incomplete deployments (SEE PREVIOUS ERRORS FOR DETAILS):
      
      *** CONTEXTS IN ERROR: Name -> Error
      
      jboss.j2ee:ear=testHska.ear,jar=testHskaEJB.jar,name=BestellverwaltungTestBean,service=EJB3 -> java.lang.NullPointerException
      
      jboss.j2ee:ear=testHska.ear,jar=testHskaEJB.jar,name=KundenverwaltungTestBean,service=EJB3 -> java.lang.NullPointerException
      
      
       at org.jboss.deployers.plugins.deployers.DeployersImpl.checkComplete(DeployersImpl.java:676)
       at org.jboss.deployers.plugins.main.MainDeployerImpl.checkComplete(MainDeployerImpl.java:661)
       at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:291)
       at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:221)
       at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
       at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
       at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
       at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
       at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:181)
       at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:205)
       at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
       at java.lang.Thread.run(Thread.java:619)


        • 1. Re: 5.0.0CR1: EJB refs across EARs don't work
          jaikiran pai Master

           


          2008-07-09 05:19:35,416 ERROR [org.jboss.kernel.plugins.dependency.AbstractKernelController] (HDScan
          ner) Error installing to Start: name=jboss.j2ee:ear=testHska.ear,jar=testHskaEJB.jar,name=Bestellver
          waltungTestBean,service=EJB3 state=Create
          java.lang.NullPointerException
          at org.jboss.ejb3.proxy.factory.ProxyFactoryHelper.getRemoteAndBusinessRemoteInterfaces(ProxyFactor
          yHelper.java:617)
          at org.jboss.ejb3.proxy.factory.ProxyFactoryHelper.getJndiName(ProxyFactoryHelper.java:421)


          There shouldn't have been a NullPointerException.

          Try this workaround:

          In your EJB1 in EAR1, add a @RemoteBinding annotation to bind it to a jndi name of your choice:

          import org.jboss.ejb3.annotation.RemoteBinding;
          
          @Stateless
          @RemoteBinding (jndiBinding="MyKundenverwaltung")
          public class KundenverwaltungBean implements Kundenverwaltung {
          



          In your EJB2 in EAR2, inject the EJB1 using a mappedName attribute:

          @Stateless
          @Remote(KundenverwaltungTestRemote.class)
          public class KundenverwaltungTestBean implements KundenverwaltungTestRemote {
           @EJB (mappedName="MyKundenverwaltung")
           private Kundenverwaltung kvProxy;
          
          


          See if this works.

          • 2. Re: 5.0.0CR1: EJB refs across EARs don't work
            Andrew Rubinger Master

            Juergen:

            If you open a JIRA in the EJBTHREE project, attaching EARs (with source) isolating this case, I'll make sure it gets added to our TestSuite coverage.

            S,
            ALR