Wednesday, 23 June 2010

Deploying the Unified Task List portlet into a WebSphere Portal cluster

This morning, I was able to successfully deploy the Unified Task List portlet to my WebSphere Portal vertical cluster running on WebSphere Application Server

I used the following file: -

echo Licensed Materials - Property of IBM
echo IBM Industry Templates for WebSphere Portal
echo \(c\)Copyright IBM Corp. 2009.  All rights reserved.

echo Batch file to install the  industry template Unified Task List \(UTL\)  framework to WebSphere portal server

echo Edit the following variables with settings that reflect the machine set up:

echo usage variables:
set assemblyRoot=/home/hayd/Downloads/runtime/PortalAcceleratorUtl
set installPath=/opt/IBM/WebSphere/PortalServer/
set profilePath=/opt/IBM/WebSphere/wp_profile/
set wasUserName=wasadmin
set wasUserPassword=wasadm1n
set hostName=localhost
set soapPort=8879

export assemblyRoot=/home/hayd/Downloads/runtime/PortalAcceleratorUtl
export installPath=/opt/IBM/WebSphere/PortalServer/
export profilePath=/opt/IBM/WebSphere/wp_profile/
export wasUserName=wasadmin
export wasUserPassword=wasadm1n
export hostName=localhost
export soapPort=8879

set -o monitor
echo Registering utl framework components with the ConfigEngine.
$profilePath/ConfigEngine/ -install -assemblyRoot $assemblyRoot -installPath $installPath -user $wasUserName$ -pwd $wasUserPassword -hostname $hostName$ -port $soapPort -offeringName PortalServer -assemblyName PortalAcceleratorUtl -expandBinaries true

echo Deploying the industry template utl framework
$profilePath/ConfigEngine/ deploy-portlets -DComponentList=utl-common -propertyfile $assemblyRoot/   

( this is provided with the portlet, in the runtimes directory )

with the following -

# Licensed Materials - Property of IBM
# IBM Industry Templates for WebSphere Portal
# (c) Copyright IBM Corp. 2009.  All rights reserved.

#Global properties file for the PortalAcceleratorUtl assembly
#users will need to set the values of the properties below
# to mirror the settings for their system

# Installation settings

General settings

( this again is provided with the portlet in the runtimes/PortalAcceleratorUtl directory )

but I also validated the installation using the following two scripts: -

/opt/IBM/WebSphere/wp_profile/ConfigEngine/ -install -assemblyRoot /home/hayd/Downloads/runtime/PortalAcceleratorUtl -installPath /opt/IBM/WebSphere/PortalServer -user wasadmin -pwd wasadm1n -hostname localhost -port 8879 -offeringName PortalServer -assemblyName PortalAcceratorUtl -expandBinaries true

/opt/IBM/WebSphere/wp_profile/ConfigEngine/ deploy-portlets -DComponentList=utl-common -propertyfile /home/hayd/Downloads/runtime/PortalAcceleratorUtl/

I had the Deployment Manager, Node Agent and Portal cluster running.

It's also worth mentioning that I had previously set the parameters WasPassword and PortalAdminPwd in ConfigEngine/properties/, to avoid me having to pass it into the script using the -D parameter.

Looking at the two ConfigEngine commands, the first one registers the UTL application with the ConfigEngine, which involves updating this file: -


with lines such as: -

<assembly xmi:id="Assembly_1277279131674" assemblyName="PortalAcceleratorUtl" installLocation="/opt/IBM/WebSphere/PortalServer/PortalAcceleratorUtl" lastModified="06/23/2010" version="">
      <component xmi:id="Component_1277279131757" compName="accelerators.utl" installLocation="/opt/IBM/WebSphere/PortalServer/PortalAcceleratorUtl/accelerators.utl" version="">
      <component xmi:id="Component_1277279131802" compName="utl-common" installLocation="/opt/IBM/WebSphere/PortalServer/PortalAcceleratorUtl/utl-common" version="">

( I ran the command grep -i utl against the file to generate the above extract )

The second ConfigEngine command then deploys the portlets, referencing the file, which references the node, cell and profile.

Once the second command had been successfully run, I can see the installed application, deployed at the Cell level, via the following path: -


It was necessary to stop/start the application via the Deployment Manager, as it only appeared to automatically start on one out of two instances. Once started, I was able to add the Unified Task List portlet to a page,and have it render - I see an "Unknown Error" message, but I'm guessing that this relates to the fact that I don't have an instance of WebSphere Process Server available to talk to.

No comments: