heidloff.net - Building is my Passion
Post
Cancel

Step-by-Step Instructions how to use Transformation Advisor

In a previous blog Improving operational Efficiency through Application Modernization I described how to containerize a Java application from 2010 via IBM’s Cloud Transformation Advisor tool. Transformation Advisor generates Dockerfiles and scripts so that the same applications can be run in containers without changing any code! This article describes how to gather the data for Transformation Advisor.

Here is the description of Transformation Advisor from the home page:

IBM Cloud Transformation Advisor helps you to analyze your on-premises workloads for modernization. It determines the complexity of your applications, estimates a development cost to perform the move to the cloud, and recommends the best target environment.

Running Transformation Advisor locally

The easiest way to start using the tool is the Transformation Advisor Local by running everything in Docker containers.

Here are the instructions for the sample application. First clone the repo:

1
2
$ git clone https://github.com/nheidloff/application-modernization-javaee-quarkus.git && cd application-modernization-javaee-quarkus
$ ROOT_FOLDER=$(pwd)

Download Transformation Advisor.

Copy ‘transformationAdvisor.zip’ to ‘${ROOT_FOLDER}/transformation-advisor/tool’ and extract it.

Accept the licence terms, install and launch Transformation Advisor:

1
$ sh ${ROOT_FOLDER}/transformation-advisor/tool/transformationAdvisor/launchTransformationAdvisor.sh

Open http://localhost:3000.

Collecting Data

In the Transformation Advisor web console create a workspace ‘workspace’ and a collection ‘collection855’.

Download the data collector for Linux ‘transformationadvisor-Linux_workspace_collection855.tgz’ and copy it to ‘${ROOT_FOLDER}/transformation-advisor/tool’.

Launch the WebSphere Traditional application (without database):

1
2
3
$ sh ${ROOT_FOLDER}/scripts/install-dojo.sh
$ sh ${ROOT_FOLDER}/scripts/install-was-dependencies.sh
$ sh ${ROOT_FOLDER}/scripts-docker/build-and-run-monolith-app-was855.sh

Next copy the data collector tool to the WebSphere container and open the container’s terminal:

1
2
$ docker cp ${ROOT_FOLDER}/transformation-advisor/tool/transformationadvisor-Linux_workspace_collection855.tgz storefront-was855:/tmp
$ docker exec -it storefront-was855 /bin/bash

Then extract the compressed data collector file:

1
2
3
$ cd /tmp
$ tar xvfz transformationadvisor-Linux_workspace_collection855.tgz
$ exit

After this copy the configuration file onto the container:

1
$ docker cp ${ROOT_FOLDER}/transformation-advisor/wast855-to-wast90/customCmd.properties storefront-was855:/tmp/transformationadvisor-2.4.0/conf

For this particular example it’s important to define to include the classes from the ‘org.pwte’ packages.

1
--includePackages=org.pwte

Once the data collector and the configuration file has been copied onto the container, the collector tool can be run:

1
2
3
4
$ docker exec -it storefront-was855 /bin/bash
$ cd /tmp/transformationadvisor-2.4.0
$ ./bin/transformationadvisor -w /opt/IBM/WebSphere/AppServer -p AppSrv01
$ exit

Usually the results are uploaded to Transformation Advisor automatically. If this doesn’t work, you can do this manually:

1
2
$ cd ${ROOT_FOLDER}/transformation-advisor/wast855-to-wast90
$ docker cp storefront-was855:/tmp/transformationadvisor-2.4.0/AppSrv01.zip .

Here is the output file AppSrv01.zip.

Viewing the Results

The results can be viewed in the Transformation Advisor Web Console.

image

The source options app server, Java JDK version and Java EE version, are recognized automatically.

The target option ‘WebSphere Traditional’ can be chosen in the web application.

image

The target Java JDK versions and Java EE versions are set automatically by Transformation Advisor. To make modernizations as easy as possible, versions are used which cause as little code changes as possible.

In a future Transformation Advisor version it might also be possible to change these values manually to get advice how to upgrade to the latest and greatest runtime versions.

Featured Blog Posts
Disclaimer
The postings on this site are my own and don’t necessarily represent IBM’s positions, strategies or opinions.
Trending Tags