Bookmark Topic Watch Topic
  • New Topic

Problem deploying adder.jar with JBoss 5. please help.

 
Anuradha Prasanna
Ranch Hand
Posts: 115
  • Mark post as helpful
  • send pies
  • Report post to moderator
Hi,

Iam new to EJB.

This is my folder structure.

SimpleCalculator/ejbModule/com.brainysoftware.ejb/Adder.java
SimpleCalculator/ejbModule/com.brainysoftware.ejb/AdderBean.java
SimpleCalculator/ejbModule/com.brainysoftware.ejb/AdderHome.java

SimpleCalculator/ejbModule/META-INF/ejb-jar.xml

SimpleCalculator/build/classes/com.brainysoftware.ejb/Adder.class
SimpleCalculator/build/classes/com.brainysoftware.ejb/AdderBean.class
SimpleCalculator/build/classes/com.brainysoftware.ejb/AdderHome.class

SimpleCalculator/build/classes/META-INF/ejb-jar.xml


Adder.java


AdderBean.java


AdderHome.java


ejb-jar.xml


After creating all above, i created adder.jar as,
E:\EJB\SimpleCalculator\build\classes>jar cfv adder.jar com/brainysoftware/ejb/* META-INF/ejb-jar.xml

I did this application in eclipse 3.5 since i dont know how to create the .jar file in eclipse, i did it manually as above.

I copied the created adder.jar file into the JBoss's , "C:\jboss\jboss-5.0.0.CR2\server\default\deploy" folder
and then restarted the JBoss server from eclipse.
I get the following error,

03:00:06,140 INFO [JBossASKernel] Created KernelDeployment for: adder.jar
03:00:06,140 INFO [JBossASKernel] installing bean: jboss.j2ee:ear=adder.jar,jar=adder.jar,name=Adder,service=EJB3
03:00:06,140 INFO [JBossASKernel] with dependencies:
03:00:06,140 INFO [JBossASKernel] and demands:
03:00:06,140 INFO [JBossASKernel] jboss.ejb:service=EJBTimerService
03:00:06,140 INFO [JBossASKernel] and supplies:
03:00:06,140 INFO [JBossASKernel] jndi:Adder
03:00:06,156 INFO [JBossASKernel] Class:com.brainysoftware.ejb.AdderHome
03:00:06,156 INFO [JBossASKernel] Added bean(jboss.j2ee:ear=adder.jar,jar=adder.jar,name=Adder,service=EJB3) to KernelDeployment of: adder.jar
03:00:06,578 INFO [SessionSpecContainer] Starting jboss.j2ee:ear=adder.jar,jar=adder.jar,name=Adder,service=EJB3
03:00:06,609 INFO [EJBContainer] STARTED EJB: com.brainysoftware.ejb.AdderBean ejbName: Adder
03:00:06,609 WARN [SessionSpecContainer] Populating JBoss-specific annotation metadata manually until done by deployers: jboss.j2ee:ear=adder.jar,jar=adder.jar,name=Adder,service=EJB3
03:00:06,671 INFO [SessionSpecContainer] Stopping jboss.j2ee:ear=adder.jar,jar=adder.jar,name=Adder,service=EJB3
03:00:06,671 INFO [EJBContainer] STOPPED EJB: com.brainysoftware.ejb.AdderBean ejbName: Adder
03:00:06,703 ERROR [AbstractKernelController] Error installing to Start: name=jboss.j2ee:ear=adder.jar,jar=adder.jar,name=Adder,service=EJB3 state=Create
java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
at java.util.ArrayList.RangeCheck(ArrayList.java:547)
at java.util.ArrayList.get(ArrayList.java:322)
at org.jboss.ejb3.proxy.jndiregistrar.JndiSessionRegistrarBase.createJndiReferenceBindingSet(JndiSessionRegistrarBase.java:222)
at org.jboss.ejb3.proxy.jndiregistrar.JndiSessionRegistrarBase.bindEjb(JndiSessionRegistrarBase.java:162)
at org.jboss.ejb3.session.SessionSpecContainer.lockedStart(SessionSpecContainer.java:706)
at org.jboss.ejb3.stateless.StatelessContainer.lockedStart(StatelessContainer.java:220)
at org.jboss.ejb3.EJBContainer.start(EJBContainer.java:858)
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:59)
at org.jboss.reflect.plugins.introspection.ReflectMethodInfoImpl.invoke(ReflectMethodInfoImpl.java:150)
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:47)
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:1598)
at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1062)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:984)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:774)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:540)
at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(BeanMetaDataDeployer.java:124)
at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(BeanMetaDataDeployer.java:51)
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:169)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1285)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1003)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1024)
at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:944)
at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1598)
at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1062)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:984)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:822)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:553)
at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:627)
at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:541)
at org.jboss.system.server.profileservice.ProfileServiceBootstrap.loadProfile(ProfileServiceBootstrap.java:265)
at org.jboss.system.server.profileservice.ProfileServiceBootstrap.start(ProfileServiceBootstrap.java:143)
at org.jboss.bootstrap.AbstractServerImpl.start(AbstractServerImpl.java:409)
at org.jboss.Main.boot(Main.java:209)
at org.jboss.Main$1.run(Main.java:544)
at java.lang.Thread.run(Thread.java:619)
03:00:06,984 ERROR [ProfileServiceBootstrap] Failed to load profile: Summary of incomplete deployments (SEE PREVIOUS ERRORS FOR DETAILS):
*** CONTEXTS IN ERROR: Name -> Error

jboss.j2ee:ear=adder.jar,jar=adder.jar,name=Adder,service=EJB3 -> java.lang.IndexOutOfBoundsException: Index: 0, Size: 0

Please help me sort out the error, where did i go wrong?
Please provide me with any corrections/ directions to successfully deploy the .jar file.



 
Jaikiran Pai
Sheriff
Posts: 10447
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Report post to moderator
Anuradha,

Please do not create multiple topics for the same question. Let's continue the discussion in your duplicate thread here http://www.coderanch.com/t/490968/JBoss/deploying-adder-jar-with-JBoss
 
    Bookmark Topic Watch Topic
  • New Topic
Boost this thread!