插件部署有很多种方法,其中一种方法:
将portlet插件部署到tomcat后,通过命令jar –cvf commodities.war *.*打成war包(如果是WebLogic部署直接压缩成rar包即可)。
如果是在WebSphere上部署,需要在web.xml中加入下列一段话:
<context-param>
<param-name>com.ibm.websphere.portletcontainer.PortletDeploymentEnabled</param-name>
<param-value>false</param-value>
</context-param>
因为在这里我们需要使用Liferay自己的Portlet容器而不是WebSphere Application Server自带的,如果没有任何配置的情况下,WebSphere Application Server总是使用自己的Portlet容器。