The Migration Toolkit for Application Binaries from IBM is a free tool that diagnoses migrations between Java application versions and migrations to Liberty. A Java application war / ear file is required for diagnostics.
https://developer.ibm.com/wasdev/downloads/#asset/tools-Migration_Toolkit_for_Application_Binaries
The procedure is --Install JDK --Download and install this Migration Toolkit --Preparing the war / ear file --Execution of diagnosis
The migration source and source application servers supported by this tool are JBoss, Liberty, Liberty Core, Apache Tomcat, WebSphere, WebLogic
Migration destination, target application server Liberty, Liberty Core, WebSphere Application Server traditional V8.5.5, WebSphere Application Server traditional V9.0
Also, it seems that you can specify the Java version. Originally, the Java version of the source is Java (11,14), IBM Java (5,6,7,8), Oracle Java (5,6,7,8) The target Java version is Java (11,14), IBM Java (7,8), Oracle Java (7,8)
It seems that you can also diagnose when migrating to IBM Cloud, and you have the following options. `` --targetCloud=[containers|cfIBMCloud|thirdParty|vmIBMCloud] Rules for migrating to the specified target cloud runtime environment Incorporate. There is no default. Source or target application server If you specify this option without specifying it, only cloud rules are included. The following options are valid.
##JDK installation
I downloaded and installed the JDK from here.
https://www.oracle.com/java/technologies/javase-downloads.html
The following command should work.
java --version
Output example
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/59741/8c1fdaee-6810-dbe0-84be-aa5e27286cb9.png)
##Download and install Migration Toolkit
Click Download from this page to download.
https://developer.ibm.com/wasdev/downloads/#asset/tools-Migration_Toolkit_for_Application_Binaries
binaryAppScannerInstaller.A file called jar will be downloaded. I saved it anywhere on my PC.
Then go to the saved folder and install with the following command
java -jar binaryAppScannerInstaller.jar
A folder called wamt will be created after installation. Therefore, enter the following command and check the operation.
cd wamt java -jar binaryAppScanner.jar --help --all
How to use it will come out as follows.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/59741/a352c9e3-4db9-ec08-b939-ebae563b18b6.png)
## war/Ear file preparation
I created a war file with reference to this.
https://techacademy.jp/magazine/23660#:~:text=WAR%E3%83%95%E3%82%A1%E3%82%A4%E3%83%AB%E3%81%AE%E4%BD%9C%E6%88%90%E6%96%B9%E6%B3%95,-WAR%E3%83%95%E3%82%A1%E3%82%A4%E3%83%AB%E3%81%AF&text=%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B%E3%81%93%E3%81%A8%E3%81%A7,%E3%83%95%E3%82%A1%E3%82%A4%E3%83%AB%E3%81%8C%E4%BD%9C%E6%88%90%E3%81%A7%E3%81%8D%E3%81%BE%E3%81%99%E3%80%82
##Perform diagnostics
If you enter the following command in the prepared war file, the diagnosis will start after a while. After that, the browser will start and the diagnostic result will be displayed. Hello Servelet here.Diagnose war
java -jar binaryAppScanner.jar HelloServlet.war
It was displayed as follows.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/59741/b0df8740-eebd-2933-d176-098fdb221a9e.png)
As the name suggests, the above app only outputs Hello, so it is natural that there is no problem, but please try it with various apps.
Recommended Posts