如何在 glassfish 中部署 wab 文件
将 WAR OSGI 文件 (WAB) 部署到 glassfish 3.1 服务器的正确过程是什么?
我将 war 文件复制到“glassfish3\glassfish\domains\domain1\autodeploy\bundles\” -> OSGI 将该文件识别为捆绑包并将其添加到其容器中。 但是,它不会将战争部署为 Web 应用程序(我无法访问其 JSP)。 为了使其成为一个 Web 应用程序,我从 glassfish 管理控制台部署了 war。
同一场战争部署两次是否正确? OSGI不应该将其部署为WEB和OSGI吗?
What is the correct process of deploying a WAR OSGI file (WAB) to glassfish 3.1 server?
I am copying the war file to "glassfish3\glassfish\domains\domain1\autodeploy\bundles\" -> OSGI recognizes the file as bundle and add it to its container.
However, it doesn't deploy the war as web application (I cannot access its JSPs).
To make it a web application, I deploy the war from glassfish admin console.
Is it correct to deploy the same war twice? Shouldn't OSGI deploy it as WEB and OSGI?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
为了让 OSGI 发现 WAB,我需要在创建 WAB 时将以下属性添加到“maven-bundle-plugin”:
使用此配置,war 应仅复制到 autodeploy/bundles。
更多详细信息(和其他属性)可以在这里找到: http://leshazlewood.com/2010/09/08/osgi-maven-pax-and-web-applications/
To make OSGI discover the wab, I needed to add the following attributes to "maven-bundle-plugin" when creating the WAB:
With this configuration, war should be copied to autodeploy/bundles only.
More details (and other attributes) can be found here: http://leshazlewood.com/2010/09/08/osgi-maven-pax-and-web-applications/
您只需按照最终 OSGi EE 规范的 Web-ContextPath 即可。 Webapp-Context 是一个中间名称。无需将 WAB 再次部署为 WAR,正如本线程中已回答的那样。
You only Web-ContextPath as per the final OSGi EE spec. Webapp-Context was an intermediate name. No need to deploy the WAB again as a WAR as already answered in this thread.