Skip to content

WebSphere Liberty To WebSphere eXtreme Scale Setup

Doug Tollefson edited this page Jun 25, 2013 · 34 revisions

Add Java to your path and set your JAVA_HOME environment variable appropriately

set JAVA_HOME=C:\work\java\ibm-java-sdk-60-win-i386
set PATH=%JAVA_HOME%\bin;%PATH%

Download the following free for developers or trial versions of WebSphere software

WebSphere Liberty 8.5.5.0

  • Download link: https://www.ibm.com/developerworks/community/blogs/wasdev/entry/download

  • Click on the "Download V8.5.5" image under "WebSphere Application Server Liberty Profile"

  • Click on the "Download" image, review and agree to the license, click the "Download Now" link and save the resulting "wlp-developers-runtime-8.5.5.0.jar" file.

  • Download link: https://www.ibm.com/developerworks/community/blogs/wasdev/entry/download

  • Click on the "Download V8.6" image under "WebSphere eXtreme Scale for Developers Liberty Profile"

  • Click on the "I confirm" button, review and agree to the license, click the "Download Now" link and save the resulting "wxs-wlp_8.6.0.2.jar" file.

  • Install the WebSphere Liberty Profile Developers Runtime file into a directory of your choice

java -jar wlp-developers-runtime-8.5.5.0.jar
  • At the end of the install it will ask for the directory and choose something like C:\work\java and it will create a directory call C:\work\java\wlp

  • Install the "WebSphere eXtreme Scale for Developers Liberty Profile" file into the same directory as the developers runtime

java -jar wxs-wlp_8.6.0.2.jar
  • For the rest of these instructions we will assume this to be the WLP_SERVERDIR
set WLP_SERVERDIR=C:\work\java\wlp

WebSphere eXtreme Scale 8.6.0.2

cd \work\java
unzip extremescaletrial860.zip
cd \work\java\ObjectGrid
set WXS_SERVERDIR=C:\work\java\ObjectGrid

Install the following development tools

Install the dependency that isn't available in Maven public repositories:

cd %WXS_SERVERDIR%\lib
mvn install:install-file -Dfile=objectgrid.jar -DgroupId=com.ibm.websphere.objectgrid -DartifactId=objectgrid -Dversion=8.6.0.2 -Dpackaging=jar

Get the Acme Air codebase

  • Go into a directory that you want to have the code in and use git to clone it
cd \work\eclipse
git clone https://github.com/acmeair/acmeair.git
  • For the rest of these instructions we will assume this to be the ACMEAIR_SRCDIR
set ACMEAIR_SRCDIR=\work\eclipse\acmeair

Build the Acme Air codebase

cd %ACMEAIR_SRCDIR%
mvn clean compile package install

Create a WebSphere eXtreme Scale configuration

  • To create a new configuration we will create a copy of the "gettingstarted" configuration and customize it to a configuration and directory called "acmeair"
cd %WXS_SERVERDIR%
xcopy gettingstarted\*.* acmeair\. /s/e/i/v/q
  • Under %WXS_SERVERDIR%\acmeair, customize the env.bat to include pointers to the classes you have built
  • You will find a line with SAMPLE_SERVER_CLASSPATH, modify it as below (ensure these directories and jars exist based on your environment variables)
SET SAMPLE_SERVER_CLASSPATH=%SAMPLE_HOME%\server\bin;%SAMPLE_COMMON_CLASSPATH%;%ACMEAIR_SRCDIR%\acmeair-common\target\classes;%ACMEAIR_SRCDIR%\acmeair-services-wxs\target\classes;%HOMEPATH%\.m2\repository\commons-logging\commons-logging\1.1.1\commons-logging-1.1.1.jar

  • Next we copy the Acme Air specific eXtreme Scale configuration files from our source directory
cd %WXS_SERVERDIR%\acmeair
copy /y %ACMEAIR_SRCDIR%\acmeair-services-wxs\src\main\resources\deployment.xml server\config\.
copy /y %ACMEAIR_SRCDIR%\acmeair-services-wxs\src\main\resources\objectgrid.xml server\config\.

Now start the Acme Air WebSphere eXtreme Scale configuration catalog server and container server

  • In one window start the catalog server
cd %WXS_SERVERDIR%\acmeair
.\runcat.bat
  • In another window start a single container server
  • Ensure that you have set JAVA_HOME and have Java in the path as before
cd %WXS_SERVERDIR%\acmeair
.\runcontainer.bat c0

Now we will load sample data into eXtreme Scale

  • In another window, we do this by running a Acme Air loader program
  • Ensure you have JAVA_HOME, Java and Maven in your path as before
cd %ACMEAIR_SRCDIR%\acmeair-loader
mvn exec:java
  • You should see output that indicates flights and customers (200) were loaded

Create and start the WebSphere Liberty server and then deploy the application

cd %WLP_SERVERDIR%
bin\server create server1
  • Edit %WLP_SERVERDIR%\usr\servers\server1\server.xml to change the featureManager section to:
     <featureManager>
         <feature>jaxrs-1.1</feature>
         <feature>jndi-1.0</feature>
         <feature>eXtremeScale.client-1.1</feature>
     </featureManager>
  • Copy the web application you previously built
copy %ACMEAIR_SRCDIR%\acmeair-webapp\target\acmeair-webapp-1.0-SNAPSHOT.war %WLP_SERVERDIR%\usr\servers\server1\dropins\.
  • Start the WebSphere Liberty server
cd %WLP_SERVERDIR%
bin\server start server1

Finally look at the application

  • Load the following url:
http://localhost:9080/acmeair-webapp-1.0-SNAPSHOT
  • Login (use the provided credentials), search for flights (suggest today between Paris and New York), book the flights, use the checkin link to cancel the bookings one at a time, view your account profile

Optionally, if you want you can use eclipse to work with the codebase

  • Tell eclipse to import existing projects into the workspace looking in %ACMEAIR_SRCDIR%