具有依赖项的独立 OpenEJB 打包
有一些关于如何打包和部署依赖于 OpenEJB 的 EJB 的文档/规范吗?
我尝试部署一个EAR包:
service.ear/lib/activemq-all.jar
service.ear/META-INF/application.xml
service.ear/model.ejb!META-INF/ejb-jar.xml
service.ear/model.ejb!com/example/MyActivemqDependentService.class
它部署成功,客户端可以使用JNDI找到,但是,当它初始化时,出现NoClassDefFound异常。
there's some documentation/specification about how to package and deploy EJB with dependencies on OpenEJB?
I tried to deploy an EAR package:
service.ear/lib/activemq-all.jar
service.ear/META-INF/application.xml
service.ear/model.ejb!META-INF/ejb-jar.xml
service.ear/model.ejb!com/example/MyActivemqDependentService.class
It was deployed successfully, client can find using JNDI, but, when it initialized, NoClassDefFound exception ocurr.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
ActiveMQ 已经随 OpenEJB 一起提供,我不希望它也能在 EAR 中工作。
这很可能是您的
NoClassDefFoundError
的来源。删除activemq-all.jar
是我尝试的第一件事。ActiveMQ already comes with OpenEJB, I wouldn't expect it to work including it in the EAR as well.
That could very likely be the source of your
NoClassDefFoundError
s. Removing thatactivemq-all.jar
is the first thing I'd try.