从 JBoss 4.2.3 迁移到 5.1 - application.xml 中列出的模块不是可识别的部署
我有一只耳朵,目前在 JBoss 4.2.3 中部署时工作正常。我正在尝试迁移到 JBoss 5.0.1,但收到错误“application.xml 中列出的类路径模块不是可识别的部署”。
下面是我的耳朵的结构:
MyApp
|
+- classpath
|
+- lib
| |
| +- A.jar
| +- B.jar
| +- C.jar
|
+- META-INF
| |
| +- application.xml
| +- jboss-app.xml
|
+- D.jar
|
*- E.jar
|
+- F.jar
|
+- myApp.war
|
+- WEB-INF
|
+- ....
下面是我的 application.xml 中的内容:
<application>
<display-name>MyApp</display-name>
<module>
<java>classpath</java>
</module>
<module>
<java>lib/A.jar</java>
</module>
<module>
<java>lib/B.jar</java>
</module>
<module>
<java>D.jar</java>
</module>
...
<module>
<web>
<web-uri>myApp.war</web-uri>
<context-root>/WEB-INF</context-root>
</web>
</module>
</application>
正如前面提到的我的耳朵的当前结构和上面概述的 application.xml,在 JBoss 4.2.3 中一切正常。但是,当我部署 JBoss 5.1.0 时,它似乎不喜欢 application.xml 中定义的“classpath”模块。
下面是发生的完整堆栈跟踪:
17:02:09,767 WARN [HDScanner] Scan failed
org.jboss.deployers.spi.DeploymentException: Exception determining structure: AbstractVFSDeployment(MyApp.ear)
at org.jboss.deployers.spi.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:49)
at org.jboss.deployers.structure.spi.helpers.AbstractStructuralDeployers.determineStructure(AbstractStructuralDeployers.java:85)
at org.jboss.deployers.plugins.main.MainDeployerImpl.determineStructure(MainDeployerImpl.java:1004)
at org.jboss.deployers.plugins.main.MainDeployerImpl.determineDeploymentContext(MainDeployerImpl.java:440)
at org.jboss.deployers.plugins.main.MainDeployerImpl.addDeployment(MainDeployerImpl.java:390)
at org.jboss.deployers.plugins.main.MainDeployerImpl.addDeployment(MainDeployerImpl.java:300)
at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.addDeployment(MainDeployerAdapter.java:86)
at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:344)
at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:255)
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:180)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:204)
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:662)
Caused by: java.lang.RuntimeException: Error determining structure: MyApp.ear
at org.jboss.deployment.EARStructure.determineStructure(EARStructure.java:293)
at org.jboss.deployers.vfs.plugins.structure.StructureDeployerWrapper.determineStructure(StructureDeployerWrapper.java:73)
at org.jboss.deployers.vfs.plugins.structure.VFSStructuralDeployersImpl.doDetermineStructure(VFSStructuralDeployersImpl.java:196)
at org.jboss.deployers.vfs.plugins.structure.VFSStructuralDeployersImpl.determineStructure(VFSStructuralDeployersImpl.java:221)
at org.jboss.deployers.structure.spi.helpers.AbstractStructuralDeployers.determineStructure(AbstractStructuralDeployers.java:77)
... 16 more
Caused by: java.lang.RuntimeException: classpath module listed in application.xml is not a recognized deployment, .ear: MyApp.ear
at org.jboss.deployment.EARStructure.determineStructure(EARStructure.java:277)
... 20 more
我正在用这个撕掉我的头发!任何帮助将不胜感激。
谢谢
I have an ear which currently works fine when deployed in JBoss 4.2.3. I am attempting to migrate to JBoss 5.0.1 but am getting the error 'classpath module listed in application.xml is not a recognized deployment'.
Below is the struture of my ear:
MyApp
|
+- classpath
|
+- lib
| |
| +- A.jar
| +- B.jar
| +- C.jar
|
+- META-INF
| |
| +- application.xml
| +- jboss-app.xml
|
+- D.jar
|
*- E.jar
|
+- F.jar
|
+- myApp.war
|
+- WEB-INF
|
+- ....
Below is what I have in my application.xml:
<application>
<display-name>MyApp</display-name>
<module>
<java>classpath</java>
</module>
<module>
<java>lib/A.jar</java>
</module>
<module>
<java>lib/B.jar</java>
</module>
<module>
<java>D.jar</java>
</module>
...
<module>
<web>
<web-uri>myApp.war</web-uri>
<context-root>/WEB-INF</context-root>
</web>
</module>
</application>
As mentioned the current structure of my ear and the application.xml outlined above, all works fine in JBoss 4.2.3. However, when I deploy this is JBoss 5.1.0 it appears not to like the 'classpath' module defined in the application.xml.
Below is the full stack trace occuring:
17:02:09,767 WARN [HDScanner] Scan failed
org.jboss.deployers.spi.DeploymentException: Exception determining structure: AbstractVFSDeployment(MyApp.ear)
at org.jboss.deployers.spi.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:49)
at org.jboss.deployers.structure.spi.helpers.AbstractStructuralDeployers.determineStructure(AbstractStructuralDeployers.java:85)
at org.jboss.deployers.plugins.main.MainDeployerImpl.determineStructure(MainDeployerImpl.java:1004)
at org.jboss.deployers.plugins.main.MainDeployerImpl.determineDeploymentContext(MainDeployerImpl.java:440)
at org.jboss.deployers.plugins.main.MainDeployerImpl.addDeployment(MainDeployerImpl.java:390)
at org.jboss.deployers.plugins.main.MainDeployerImpl.addDeployment(MainDeployerImpl.java:300)
at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.addDeployment(MainDeployerAdapter.java:86)
at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:344)
at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:255)
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:180)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:204)
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:662)
Caused by: java.lang.RuntimeException: Error determining structure: MyApp.ear
at org.jboss.deployment.EARStructure.determineStructure(EARStructure.java:293)
at org.jboss.deployers.vfs.plugins.structure.StructureDeployerWrapper.determineStructure(StructureDeployerWrapper.java:73)
at org.jboss.deployers.vfs.plugins.structure.VFSStructuralDeployersImpl.doDetermineStructure(VFSStructuralDeployersImpl.java:196)
at org.jboss.deployers.vfs.plugins.structure.VFSStructuralDeployersImpl.determineStructure(VFSStructuralDeployersImpl.java:221)
at org.jboss.deployers.structure.spi.helpers.AbstractStructuralDeployers.determineStructure(AbstractStructuralDeployers.java:77)
... 16 more
Caused by: java.lang.RuntimeException: classpath module listed in application.xml is not a recognized deployment, .ear: MyApp.ear
at org.jboss.deployment.EARStructure.determineStructure(EARStructure.java:277)
... 20 more
I'm tearing my hair out with this one! Any help would be greatly appreciated.
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
好消息是,JBoss 5.x 会自动将
lib
中的任何 JAR 添加到 EAR 的类路径中,因此您实际上不需要在application.xml
中指定它们。对于您的
classpath
目录,您必须将其重命名为classpath.jar
,然后 5.x 应该接受它。The good news is that JBoss 5.x automatically adds any JARs in
lib
to the EAR's classpath, so you don't actually need to specify them in theapplication.xml
.For your
classpath
directory, you'll have to rename that toclasspath.jar
, and then 5.x should accept it.是什么
application.xml 中您指的 ?这看起来不像有效的 jar 存档名称。尝试删除此条目并重新部署。
What is the
You are referring to in the application.xml? This does not look like a valid jar archive name. Try removing this entry and redeploy.