realwangpu
2021-06-05 19:34
采纳率: 96.7%
浏览 78

部署EJB报OpenEJBException异常

[2019-11-21 10:26:37] [WARNING] [core] [Error deploying application D:\TongWeb\deployment\itreasuryEJB]
com.tongweb.tongejb.OpenEJBException: Cannot Load jar D:\TongWeb\deployment\itreasuryEJB.  The number of beans deployed (166) does not match the number of beans actually in the jar (91).  Please redeploy this jar.
    at com.tongweb.tongejb.config.EjbJarInfoBuilder.buildInfo(EjbJarInfoBuilder.java:136)
    at com.tongweb.tongejb.config.ThorEjbJarInfoBuilder.buildInfo(ThorEjbJarInfoBuilder.java:15)
    at com.tongweb.tongejb.config.ThorAppInfoBuilder.build(ThorAppInfoBuilder.java:93)
    at com.tongweb.tongejb.config.ThorConfigurationFactory.configureApplication(ThorConfigurationFactory.java:896)
    at com.tongweb.twnt.thor.ThorWebtierWebAppBuilder.fireOpenEjbProcess(ThorWebtierWebAppBuilder.java:2587)
    at com.tongweb.twnt.thor.ThorWebtierWebAppBuilder.deployApplication(ThorWebtierWebAppBuilder.java:2371)
    at com.tongweb.deploy.TongWebDeployer.deploy(TongWebDeployer.java:212)
    at com.tongweb.deploy.commands.DeployCommand.deploy(DeployCommand.java:321)
    at com.tongweb.deploy.autodeploy.TongWebAutoDeployer.deployAll(TongWebAutoDeployer.java:66)
    at com.tongweb.deploy.autodeploy.TongWebAutoDeployTask.run(TongWebAutoDeployTask.java:223)
    at java.util.TimerThread.mainLoop(Timer.java:555)
    at java.util.TimerThread.run(Timer.java:505)

  • 写回答
  • 关注问题
  • 收藏
  • 邀请回答

1条回答 默认 最新

  • realwangpu 2021-06-05 19:36
    已采纳

    这是因为实际的EJB个数与ejb-jar.xml中描述的个数不对应,所以部署失败,而weblogic会忽略此错误。

     解决办法:ejb-jar.xml,tongweb-ejb-jar.xml要与实际的EJB一一对应才可以。

    已采纳该答案
    打赏 评论

相关推荐 更多相似问题