Deploying a Portlet Application
New Java portlets are available in Portlet Applications:Â packaged .war files that deploy to their own web context and include one or more portlets. Â Before you can publish a portlet contained within a new portlet application, you must deploy it. Â There are two common ways to do that.
Deploy Using deployPortletApp
You can deploy a portlet using an Ant task. Â Run the following command from your uPortal source directory (add your portlet war path file)
ant deployPortletApp -DportletApp=/path/to/yourProject.war
Bundling a Portlet
The other common approach is called Bundling: Â use a Maven sub-project (typically in uportal-portlets-overlay
) to include your portlet application in the uportal-ear
artifact so it will be deployed automatically whenever the deploy-ear
target executes. Â The bundled portlet is typically a Maven Overlay project and should use the maven-pluto-plugin
. Â (Portlet applications deployed with deployPortletApp
must not use this plugin.) Â Remember to reference your sub-project both in uportal-portlets-overlay/pom.xml
and in uportal-ear/pom.xml
.