Deploy the war through netbeans on the v3 beta glass phase

The same .war file is deployed to Glassfish v2.1. I do not know the last time I tried v3, but I wanted to test the functionality of the hot deployment, as it is rumored to work in netbeans 6.8 with glassfish v3. So, I deploy as usual and get the following error:

SEVERE: Exception while invoking class org.glassfish.ejb.startup.EjbDeployer load method .... SEVERE: Exception while loading the app java.lang.RuntimeException: Unable to load EJB module. DeploymentContext does not contain any EJB Check archive to ensure correct packaging for c:\src\svn\trunk\gui\target\WEBAPP at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:134) at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:64) at org.glassfish.internal.data.ModuleInfo.load(ModuleInfo.java:153) at org.glassfish.internal.data.ApplicationInfo.load(ApplicationInfo.java:220) at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:314) at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:169) at org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:272) at com.sun.enterprise.v3.admin.CommandRunnerImpl$1.execute(CommandRunnerImpl.java:305) at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:320) at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1159) at com.sun.enterprise.v3.admin.CommandRunnerImpl.access$900(CommandRunnerImpl.java:83) at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1218) at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1207) at com.sun.enterprise.v3.admin.AdminAdapter.doCommand(AdminAdapter.java:362) at com.sun.enterprise.v3.admin.AdminAdapter.service(AdminAdapter.java:201) at com.sun.grizzly.tcp.http11.GrizzlyAdapter.service(GrizzlyAdapter.java:166) at com.sun.enterprise.v3.server.HK2Dispatcher.dispath(HK2Dispatcher.java:100) at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:241) at com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:789) at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:697) at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:951) at com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:166) at com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:135) at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:102) at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:88) at com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:76) at com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:53) at com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:57) at com.sun.grizzly.ContextTask.run(ContextTask.java:69) at com.sun.grizzly.util.FixedThreadPool$BasicWorker.doWork(FixedThreadPool.java:431) at com.sun.grizzly.util.FixedThreadPool$BasicWorker.run(FixedThreadPool.java:410) at java.lang.Thread.run(Thread.java:619) 

I don’t understand why he is complaining about anything related to EJB as it is a .war file. Any ideas?

UPDATE: I filed a bug with glass fish: https://glassfish.dev.java.net/issues/show_bug.cgi?id=10592 . Either this is a bug in the glass fish, or at least the error message does not help in tracking the problem.

+3
source share
4 answers

https://glassfish.dev.java.net/issues/show_bug.cgi?id=10592

From the error:

Ok, found a reason (thanks for providing a test case!):

  • EjbSniffer was obtained after scanning the archive: one (or more) of the library, packaged in the archive, contains an EJB with component annotations. Thus, the ejb container was asked to load the module later.

  • The ejb container could not find the appropriate metadata because web.xml is version 2.4, so metadata processing skipped the annotation (we only process annotations for Java EE 5+ versions).

After I changed the web.xml file to the link 2.5 (you can also do the 3.0 scheme): http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd ">

The application has been deployed successfully.

Please try and let me know if this works for you.

+6
source

I have a 3_0 scheme and am still getting an error. More interestingly, I have two wars, one of them is an example from the archetype of welding, and the other is setup. Normal warfare does not work.

I checked side by side, the same, with the exception of more model classes and other properties in persistence.xml

+2
source

Someone using @Stateless in ManagedBeans is reporting a similar issue on the java.net Forums .

I don't know if this applies to you, but this workaround was:

Go to the admin console, go to the update center and install EJB.

I have not tested it myself, so I can’t confirm that this will help.

+1
source

Only my $ 0.02 ...

I had the same error after adding the JaxMe library (version 0.5.2) to my application. This caused the deployment to fail on one of my military modules - it confused me because I did not make any changes to this module. Removing JaxMe fixed the problem.

0
source

All Articles