java.lang.IllegalArgumentException: Invalid ejb jar [mSender.jar]: it contains zero ejb. Note: 1. A valid ejb jar requires at least one session, entity (1.x/2.x style), or message driven bean. 2. EJB3+ entity beans (@Entity) are POJOs and please package them as library jar. 3. If the jar file contains valid EJBs which are annotated with EJB component level annotations (@Stateless, @Stateful, @MessageDriven, @Singleton), please check server.log to see whether the annotations were processed properly.

kenai.com | 9 months ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    Java EE Patterns And Best Practices: General Discussion: Starting EJB 3.1 Container Inside Your Unit Test — Project Kenai

    kenai.com | 11 months ago
    java.lang.IllegalArgumentException: Invalid ejb jar [mSender.jar]: it contains zero ejb. Note: 1. A valid ejb jar requires at least one session, entity (1.x/2.x style), or message driven bean. 2. EJB3+ entity beans (@Entity) are POJOs and please package them as library jar. 3. If the jar file contains valid EJBs which are annotated with EJB component level annotations (@Stateless, @Stateful, @MessageDriven, @Singleton), please check server.log to see whether the annotations were processed properly.
  2. 0

    Java EE Patterns And Best Practices: General Discussion: Starting EJB 3.1 Container Inside Your Unit Test — Project Kenai

    kenai.com | 9 months ago
    java.lang.IllegalArgumentException: Invalid ejb jar [mSender.jar]: it contains zero ejb. Note: 1. A valid ejb jar requires at least one session, entity (1.x/2.x style), or message driven bean. 2. EJB3+ entity beans (@Entity) are POJOs and please package them as library jar. 3. If the jar file contains valid EJBs which are annotated with EJB component level annotations (@Stateless, @Stateful, @MessageDriven, @Singleton), please check server.log to see whether the annotations were processed properly.

    Root Cause Analysis

    1. java.lang.IllegalArgumentException

      Invalid ejb jar [mSender.jar]: it contains zero ejb. Note: 1. A valid ejb jar requires at least one session, entity (1.x/2.x style), or message driven bean. 2. EJB3+ entity beans (@Entity) are POJOs and please package them as library jar. 3. If the jar file contains valid EJBs which are annotated with EJB component level annotations (@Stateless, @Stateful, @MessageDriven, @Singleton), please check server.log to see whether the annotations were processed properly.

      at com.sun.enterprise.deployment.util.EjbBundleValidator.accept()
    2. Deployment Object Library
      ApplicationArchivist.openWith
      1. com.sun.enterprise.deployment.util.EjbBundleValidator.accept(EjbBundleValidator.java:69)
      2. com.sun.enterprise.deployment.util.ApplicationValidator.accept(ApplicationValidator.java:83)
      3. com.sun.enterprise.deployment.EjbBundleDescriptor.visit(EjbBundleDescriptor.java:722)
      4. com.sun.enterprise.deployment.Application.visit(Application.java:1732)
      5. com.sun.enterprise.deployment.archivist.ApplicationArchivist.validate(ApplicationArchivist.java:766)
      6. com.sun.enterprise.deployment.archivist.ApplicationArchivist.openWith(ApplicationArchivist.java:252)
      6 frames
    3. Deployment Related JavaEE Core Classes
      DolProvider.load
      1. org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:105)
      2. org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:35)
      2 frames
    4. Kernel Classes
      EmbeddedDeployerImpl.deploy
      1. com.sun.enterprise.v3.server.ApplicationLifecycle.loadDeployer(ApplicationLifecycle.java:580)
      2. com.sun.enterprise.v3.server.ApplicationLifecycle.setupContainerInfos(ApplicationLifecycle.java:522)
      3. com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:232)
      4. org.glassfish.kernel.embedded.EmbeddedDeployerImpl.deploy(EmbeddedDeployerImpl.java:186)
      5. org.glassfish.kernel.embedded.EmbeddedDeployerImpl.deploy(EmbeddedDeployerImpl.java:146)
      5 frames
    5. Embedded GlassFish Web
      EJBContainerProviderImpl.createEJBContainer
      1. org.glassfish.ejb.embedded.EJBContainerImpl.deploy(EJBContainerImpl.java:128)
      2. org.glassfish.ejb.embedded.EJBContainerProviderImpl.createEJBContainer(EJBContainerProviderImpl.java:120)
      2 frames
    6. JavaEE 7
      EJBContainer.createEJBContainer
      1. javax.ejb.embeddable.EJBContainer.createEJBContainer(EJBContainer.java:102)
      2. javax.ejb.embeddable.EJBContainer.createEJBContainer(EJBContainer.java:78)
      2 frames
    7. msender.facade
      mSenderFacadeTest.setUpClass
      1. msender.facade.mSenderFacadeTest.setUpClass(mSenderFacadeTest.java:19)
      1 frame
    8. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      4. java.lang.reflect.Method.invoke(Method.java:597)
      4 frames
    9. JUnit
      JUnit4TestAdapter.run
      1. org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44)
      2. org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
      3. org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41)
      4. org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:27)
      5. org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:31)
      6. org.junit.runners.ParentRunner.run(ParentRunner.java:220)
      7. junit.framework.JUnit4TestAdapter.run(JUnit4TestAdapter.java:39)
      7 frames
    10. Apache Ant + JUnit
      JUnitTestRunner.main
      1. org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.run(JUnitTestRunner.java:515)
      2. org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.launch(JUnitTestRunner.java:1031)
      3. org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.main(JUnitTestRunner.java:888)
      3 frames