Installing the Migration Toolkit for Applications
Installing the Migration Toolkit for Applications user interface and command-line interface
Abstract
- 1. Introduction to the Migration Toolkit for Applications
- 2. Supported Migration Toolkit for Applications migration paths
- 3. Installing the Migration Toolkit for Applications user interface
- 4. Installing the Migration Toolkit for Applications command-line interface
- A. How to contribute to the MTA project
Chapter 1. Introduction to the Migration Toolkit for Applications
Migration Toolkit for Applications (MTA) is a set of tools that you can use to accelerate large-scale application modernization efforts across hybrid cloud environments on Red Hat OpenShift. MTA looks for common resources and problematic spots when migrating applications. It gives a high level view of the technologies used by the application. MTA also generates a detailed report that evaluates a migration or modernization path. By using this report, you can estimate the effort needed for large-scale projects and reduce the workload involved in the process.
By using the MTA, you can perform the following tasks:
- Use the MTA extensive default questionnaire to assess your applications, or create your own custom questionnaire to estimate the difficulty, time, and other resources needed to prepare an application for containerization. You can use the results of an assessment to determine applications suitable for containerization.
- Analyze applications by applying sets of rules to each application. You can use these rules to determine which specific lines of the application you must modify before modernizing the application.
- Examine application artifacts, including project source directories and application archives, and produce an HTML report that highlights areas that require changes.
1.1. MTA features
Migration Toolkit for Applications (MTA) includes many features that simplify upgrades with multiple migration paths.
MTA brings the following benefits for application analysis and assessment:
- Application inventory and assessment modules to help organizations assess applications' suitability for deployment in containers, including flagging potential risks for migration strategies.
- Integration with source code and binary repositories to automate the applications' retrieval for analysis, along with proxy integration, including HTTP and HTTPS proxy configuration managed in the user interface.
- Improved analysis capabilities with different analysis modes, including source and dependency modes. These modes parse repositories to gather dependencies and add these dependencies to the overall scope of the analysis. You can also use a simplified user experience to configure the analysis scope, including open source libraries.
Enhanced Role-Based Access Control (RBAC) powered by Red Hat build of Keycloak to define the following personas:
- Administrator
- Architect
- Migrator
These personas have different permissions to suit the needs of each user, including credentials management for multiple credential types.
- Administration perspective for administrators to manage tool-wide configuration.
- Support for Red Hat OpenShift on AWS (ROSA)
- Support for Azure Red Hat OpenShift (ARO)
- Support for analyzing applications written in different languages
1.2. MTA rules
The Migration Toolkit for Applications (MTA) contains rule-based migration tools called analyzers. You can use analyzers to analyze the application user interfaces (APIs), technologies, and architectures used by the applications you want to migrate.
MTA analyzer rules use the following rule pattern:
when(condition) message(message) tag(tags)
You can use the MTA rules internally to perform the following tasks:
- Extract files from archives
- Decompile files
- Scan and classify file types
- Analyze XML and other file content
- Analyze the application code
- Build the reports
MTA builds a data model based on the rule execution results and stores component data and relationships in a graph database. This database can then be queried and updated as needed by the migration rules and for reporting purposes.
You can create your own custom analyzer rules. You can use custom rules to identify the use of custom libraries or other components that the provided standard migration rules might not cover.
For instructions on how to write custom rules, see Rules Development Guide.
1.3. MTA tools
Different Migration Toolkit for Applications (MTA) tools help in the various stages of your migration and modernization efforts.
You can use the following MTA tools for assessing and analyzing your applications:
User interface (UI)
By using the user interface for the Migration Toolkit for Applications, you can perform the following tasks:
- Assess the risks involved in containerizing an application for hybrid cloud environments on Red Hat OpenShift
- Analyze the changes that you might need to apply to the code of an application to containerize this application
For more information about using the MTA user interface, see Configuring and managing the Migration Toolkit for Applications user interface.
Command-line interface (CLI)
The CLI is a command-line tool in the Migration Toolkit for Applications that you can use to assess and prioritize migration and modernization efforts for applications. It provides numerous reports that highlight the analysis without using the other tools. The CLI includes a wide array of customization options. By using the CLI, you can tune MTA analysis options or integrate with external automation tools.
For more information about using the CLI, see link:Using the MTA command-line interface to analyze applications.
Migration Toolkit for Applications Operator
By using the Migration Toolkit for Applications Operator, you can install the user interface on OpenShift Container Platform.
For more information about the prerequisites for the MTA Operator installation, see OpenShift Operator Life Cycles.
IDE add-ons
You can migrate and modernize applications by using the Migration Toolkit for Applications add-ons for the following applications:
- Visual Studio Code
IntelliJ IDEA
You can use these add-ons to perform the following tasks:
- Analyze your projects by using customizable sets of rules
- Mark issues in the source code
- Fix the issues by using the provided guidance
- Use the automatic code replacement, if possible
For more information about using add-ons, see the following documentation:
Chapter 2. Supported Migration Toolkit for Applications migration paths
You can use the Migration Toolkit for Applications (MTA) to assess your applications' suitability for the migration to multiple target platforms.
MTA supports the following migration paths:
Table 2.1. Supported Java migration paths
| Source platform ⇒ | Migration to JBoss EAP 7 & 8 | OpenShift (cloud readiness) | OpenJDK 11, 17, and 21 | Jakarta EE 9 | Camel 3 & 4 | Spring Boot in Red Hat Runtimes | Quarkus | Open Liberty |
|---|---|---|---|---|---|---|---|---|
|
Oracle WebLogic Server |
✔ |
✔ |
✔ |
- |
- |
- |
- |
- |
|
IBM WebSphere Application Server |
✔ |
✔ |
✔ |
- |
- |
- |
- |
✔ |
|
JBoss EAP 4 |
✘ [a] |
✔ |
✔ |
- |
- |
- |
- |
- |
|
JBoss EAP 5 |
✔ |
✔ |
✔ |
- |
- |
- |
- |
- |
|
JBoss EAP 6 |
✔ |
✔ |
✔ |
- |
- |
- |
- |
- |
|
JBoss EAP 7 |
✔ |
✔ |
✔ |
- |
- |
- |
✔ |
- |
|
Thorntail |
✔ [b] |
- |
- |
- |
- |
- |
- |
- |
|
Oracle JDK |
- |
✔ |
✔ |
- |
- |
- |
- |
- |
|
Camel 2 |
- |
✔ |
✔ |
- |
✔ |
- |
- |
- |
|
Spring Boot |
- |
✔ |
✔ |
✔ |
- |
✔ |
✔ |
- |
|
Any Java application |
- |
✔ |
✔ |
- |
- |
- |
- |
- |
|
Any Java EE application |
- |
- |
- |
✔ |
- |
- |
- |
- |
[a]
Although MTA does not currently provide rules for this migration path, Red Hat Consulting can assist with migration from any source platform to JBoss EAP 7.
[b]
Requires JBoss Enterprise Application Platform expansion pack 2 (EAP XP 2)
| ||||||||
..NET migration paths
| Source platform ⇒ | OpenShift (cloud readiness) | Migration to .NET 8.0 |
|---|---|---|
|
.NET Framework 4.5+ (Windows only) |
✔ |
✔ |
Analyzing applications written in the .NET language is a Developer Preview feature only. Developer Preview features are not supported by Red Hat in any way and are not functionally complete or production-ready. Do not use Developer Preview features for production or business-critical workloads. Developer Preview features provide early access to upcoming product features in advance of their possible inclusion in a Red Hat product offering, enabling customers to test functionality and provide feedback during the development process. These features might not have any documentation, are subject to change or removal at any time, and testing is limited. Red Hat might provide ways to submit feedback on Developer Preview features without an associated SLA.
Additional resources
Chapter 3. Installing the Migration Toolkit for Applications user interface
By using the Migration Toolkit for Applications (MTA) user interface (UI), you can assess the risks involved in containerizing an application for hybrid cloud environments on Red Hat OpenShift. You can also analyze the changes that you must apply to the application’s code to containerize the application. You can install the Migration Toolkit for Applications UI on all Red Hat OpenShift cloud services and Red Hat OpenShift self-managed editions.
To create MTA instances, you must install the MTA Operator first. The MTA Operator is a structural layer that manages resources deployed on Red Hat OpenShift, such as database, front end, and back end, to automatically create an MTA instance.
3.1. Persistent volume requirements
To successfully deploy the MTA Operator, you must create a persistent volume (PV) used by different MTA components.
MTA Operator requires two ReadWriteOnce (RWO) PVs. If the rwx_supported configuration option is set to true, the MTA Operator needs two additional ReadWriteMany (RWX) PVs used by Maven and the hub file storage.
Table 3.1. Required persistent volumes
| Name | Default size | Access mode | Description |
|---|---|---|---|
|
|
|
RWO |
Hub database |
|
|
|
RWX |
Hub file storage required if the |
|
|
|
RWO |
Keycloak backend database |
|
|
|
RWX |
Maven m2 cache required if the |
|
|
|
RWO |
Red Hat Developer Lightspeed for MTA database required to run an AI-assisted code resolution. |
3.2. Red Hat Build of Keycloak
Starting from version 7.3.0, MTA uses the Red Hat Build of Keycloak (RHBK) instance for user authentication and authorization. A RHBK instance is installed during the installation of the MTA user interface. The MTA Operator manages the RHBK instance and configures a dedicated realm with necessary roles and permissions.
You can use the MTA-managed RHBK instance to perform advanced RHBK configurations, such as adding a provider for User Federation or integrating identity providers.
3.2.1. Accessing the RHBK Admin Console
To perform advanced configurations to a RHBK instance, you must log in to the RHBK Admin Console.
Procedure
Retrieve your admin credentials:
$ oc get secret mta-keycloak-rhbk -n openshift-mta -o json| jq -r '.data.password | @base64d'The admin credentials for RHBK are stored in the
mta-keycloak-rhbksecret file in the namespace where you installed MTA.Enter the following URL in your browser:
https://<web_console_address>/auth/admin- Access the RHBK Admin Console by entering your credentials.
3.2.2. Roles, personas, users, and permissions
The Migration Toolkit for Applications (MTA) uses three roles, each corresponds to a persona. The roles are pre-defined in your Red Hat Build of Keycloak (RHBK) instance. If you are an MTA administrator, you can create users in your RHBK instance and assign each user one or more roles, one role per persona.
A user can have more than one role. Each role must correspond to a specific persona:
-
The
tackle-adminrole corresponds to the Administrator persona. The administrator has all permissions that architects and migrators have. Administrators can also create application-wide configuration parameters that other users can consume but cannot change or view, for example, Git credentials or Mavensettings.xmlfiles. -
The
tackle-architectrole corresponds to the Architect persona. An architect is a technical lead for the migration project. Architects can run assessments and can create and modify applications and information related to the applications. Architects cannot modify or delete sensitive information, but can consume such information. For example, architects can associate an existing set of credentials to the repository of a specific application. -
The
tackle-migratorrole corresponds to the Migrator persona. A migrator can analyze applications. However, the migrator cannot create, modify, or delete the applications.
MTA has two views, Administration and Migration. Only administrators can access the Administration view. Architects and migrators cannot see or access the Administration view. Administrators can perform all actions supported by the Migration view. Architects and migrators can see all elements of the Migration view. However, whether architects and migrators can perform actions in the Migration view depends on the permissions granted to their role.
3.3. Installing the MTA Operator
To create MTA instances, you must install the MTA Operator first.
The Migration Toolkit for Applications (MTA) Operator is a structural layer that manages resources deployed on Red Hat OpenShift, such as the database, front end, and back end, to automatically create an MTA instance.
Prerequisites
- 4 vCPUs, 8 GB RAM, and 40 GB persistent storage.
- Any cloud services or self-hosted edition of Red Hat OpenShift on versions 4.13-4.15.
- 2 RWO persistent volumes (PVs) used by different components. For more information, see Persistent volume requirements.
-
You are logged in as a user with
cluster-adminpermissions.
Procedure
- In the Red Hat OpenShift web console, click Operators.
- Click OperatorHub.
- Type MTA in the Filter by keyword field to search for the MTA Operator.
- Click Migration Toolkit for Applications Operator.
- Click Install.
- On the Install Operator page, click Install.
Optional: Review and edit the custom resource (CR) settings.
A window for creating CR settings opens automatically after the installation of the MTA Operator is complete. The default settings are acceptable. However, make sure to check the system requirements for storage, memory, and cores.
Alternatively, to work directly with the YAML file, click the YAML view and review the CR settings listed in the
specsection of the YAML file. For more details about commonly used CR settings, see Custom resource settings.The
specsection of the YAML file can have the following configuration:kind: Tackle apiVersion: tackle.konveyor.io/v1alpha1 metadata: name: mta namespace: openshift-mta spec: hub_bucket_volume_size: "2.5Gi" maven_data_volume_size: "2.5Gi" rwx_supported: "false"
Verify that the MTA pods are running:
- In the Administration view, click Workloads.
- Click Pods.
Verification
-
Verify that you can see the MTA Operator in the
openshift-mtaproject with the status of Succeeded by clicking Operators and then Installed Operators.
Next steps
Additional resources
3.4. Creating an MTA instance
You can use the Migration Toolkit for Applications (MTA) user interface (UI) to get insights about the application adoption process at both the portfolio and application levels. You can use the MTA UI to inventory, assess, analyze, and manage applications for faster migration to Red Hat OpenShift.
To use the MTA UI for assessing and analyzing your applications, you must create a MTA instance first.
Prerequisites
- You installed the MTA Operator on your system. For more information, see Installing the Migration Toolkit for Applications Operator.
- 4 vCPUs, 8 GB RAM, and 40 GB persistent storage.
- Any cloud services or self-hosted edition of Red Hat OpenShift on versions 4.13-4.15.
-
You are logged in as a user with
cluster-adminpermissions.
Procedure
- Click MTA Operator.
- Under Provided APIs, search for Tackle.
- Click Create Instance.
-
Access the user interface from your browser by using the route provided by the
mta-uiapplication within Red Hat OpenShift. Log in to the user interface instance by using the default credentials:
-
Username:
admin -
Password:
Passw0rd!
-
Username:
- When prompted, create a new password.
Additional resources
3.5. Custom resource settings
When installing the {ProductrFullName} Operator, you might need to create custom resource (CR) settings. The default settings are acceptable. However, make sure to check the system requirements for storage, memory, and cores.
The following are the most commonly used CR settings that you can find in the spec section of the YAML file.
Table 3.2. Common custom resource settings
| CR name | Default size | Description |
|---|---|---|
|
|
100 GB |
A size requested for the cache volume. This CR is ignored when the |
|
|
Default storage class |
A storage class used for the cache volume. This CR is ignored when the |
|
|
True |
A flag to indicate whether keycloak authorization is required. When set to |
|
|
True |
A flag to indicate whether namespace isolation by using network policies is enabled. |
|
|
10 GB |
A size requested for the Hub database volume. |
|
|
100 GB |
A size requested for the Hub bucket volume. |
|
|
Default storage class |
A storage class used for the bucket volume. |
|
|
1 GB |
A size requested for the Keycloak database volume. |
|
|
1 GB |
A size requested for the Pathfinder database volume. |
|
|
True |
A flag to indicate whether the cluster storage supports RWX mode. |
|
|
NA |
A storage class requested for the Tackle RW0 volumes. |
|
|
False |
A flag to indicate whether a dedicated route is created to access the MTA managed RHSSO instance. |
|
|
1 |
A maximum number of CPUs the pod is allowed to use. |
|
|
4 GB |
Maximum amount of memory the pod is allowed to use. You can increase this limit if the pod displays |
|
|
1 |
A minimum number of CPUs the pod needs to run. |
|
|
4 GB |
Minimum amount of memory the pod needs to run. |
Additional resources
Chapter 4. Installing the Migration Toolkit for Applications command-line interface
You can use the Migration Toolkit for Applications (MTA) command-line interface (CLI) to assess and prioritize migration and modernization efforts for applications. You can use different command options to adapt the CLI behavior to your needs. You can tune the MTA analysis options or integrate with external automation tools.
You can install the Migration Toolkit for Applications (MTA) command-line interface (CLI) on Linux, Windows, or macOS operating systems. You can also install the CLI for the use with Docker on Windows. Note, however, that this is a Developer Preview feature only.
4.1. Installing the CLI by using a .zip file
You can use the Migration Toolkit for Applications (MTA) command-line interface (CLI) to assess and analyze your applications to prepare these applications for the migration.
You can install the MTA CLI by using the downloadable .zip file available on the official MTA download page.
Prerequisites
You logged in to
registry.redhat.io. For more details, see Red Hat Container Registry Authentication.NoteThis prerequisite is not applicable for the containerless mode. For more information, see Analyzing an application in containerless mode.
- You installed Java Development Kit (JDK) version 17 or later.
-
You set the
JAVA_HOMEenvironmental variable. -
You installed Maven version 3.9.9 or later and added the Maven binary to the
$PATHvariable.
Procedure
Navigate to the MTA download page and download one of the following operating system-specific CLI files or the
srcfile:- mta-8.0.0-cli-linux-amd64.zip
- mta-8.0.0-cli-linux-arm64.zip
- mta-8.0.0-cli-darwin-amd64.zip
- mta-8.0.0-cli-darwin-arm64.zip
- mta-8.0.0-cli-windows-amd64.zip
- mta-8.0.0-cli-windows-arm64.zip
- mta-8.0.0-cli-src.zip
-
Extract the
.zipfile to the.kantradirectory inside your$HOMEdirectory. The.zipfile extracts themta-clibinary, along with other required directories and files. Move the
mta-clibinary to your$PATHvariable.NoteYou can place the
mta-clibinary in any folder that is included in the$PATHvariable. Alternatively, you can add a folder that containsmta-clito$PATH. This way, you do not need to specify a full path when using the CLI.
4.2. Installing the CLI on a disconnected environment
In certain cases, you might want to install the Migration Toolkit for Applications (MTA) command-line interface (CLI) when the internet connection is not available.
When your system is in a disconnected environment, you can install the Migration Toolkit for Applications (MTA) command-line interface (CLI) by performing the following actions:
- Download the required images by using an external computer.
- Copy the downloaded images to the system you want to install the MTA CLI on.
The following procedure applies only to container mode.
The analysis output in the disconnected environment usually results in fewer incidents because a dependency analysis does not run accurately without access to Maven.
Prerequisites
- You downloaded the required MTA CLI binary from the Migration Toolkit for Applications Red Hat Developer page.
- You installed the Podman tool on your system.
For the analysis of Java applications, you enabled container runtime usage by setting the
--run-localflag tofalse:--run-local=false
The analysis of non-Java applications runs in container mode by default.
Procedure
On a connected device, perform the following steps:
Authenticate to
registry.redhat.io:$ podman login registry.redhat.ioRun the
mta-clibinary file:$ mta-cli analyzeImportantThe binary file pulls only the required provider images. For example, if you run a command that requires Java images, the command will not pull .NET images.
Display the image list:
$ podman imagesREPOSITORY TAG IMAGE ID CREATED SIZE registry.redhat.io/mta/mta-generic-external-provider-rhel9 7.3.1 8b8d7fa14570 13 days ago 692 MB registry.redhat.io/mta/mta-cli-rhel9 7.3.1 45422a12d936 13 days ago 1.6 GB registry.redhat.io/mta/mta-java-external-provider-rhel9 7.3.1 4d6d0912a38b 13 days ago 715 MB registry.redhat.io/mta/mta-dotnet-external-provider-rhel9 7.3.1 66ec9fc51408 13 days ago 1.27 GB
Save the images:
$ podman save <image_ID> -o <image_name>.image- Copy the images onto a USB drive or directly to the file system of the disconnected device.
On the disconnected device, enter:
$ podman load --input <image_name>.image
4.3. Installing the CLI for use with Docker on Windows
To migrate applications built with .NET framework version 4.5 or later, on Microsoft Windows to cross-platform .NET 8.0, you must install the CLI for the use with Docker on Windows.
To install the CLI for the use with Docker on Windows, you must configure Docker to use Windows containers first.
Prerequisites
- You have a host with 64-bit Windows 11, version 21H2 or later.
- You downloaded the Docker Desktop for Windows installation program. For more details, see Install Docker Desktop on Windows.
Procedure
- Open a PowerShell with Administrator privileges.
Ensure Hyper-V is installed and enabled:
PS C:\Users\<user_name>> Enable-WindowsOptionalFeature -Online ` -FeatureName Microsoft-Hyper-V-AllPS C:\Users\<user_name>> Enable-WindowsOptionalFeature -Online ` -FeatureName ContainersNoteYou might need to reboot Windows for the change to take effect.
Install Docker Desktop on Windows.
Run the installer by double-clicking the
Docker_Desktop_Installer.exefile.By default, Docker Desktop is installed to the
C:\Program Files\Docker\Dockerpath.Ensure that Docker runs Windows containers as the backend instead of Linux containers:
- In the Windows task bar, right-click the Docker icon.
- Click Switch to Windows containers.
In PowerShell, create a folder for MTA:
PS C:\Users\<user_name>> mkdir C:\Users\<user_name>\MTAExtract the
mta-8.0.0-cli-windows.zipfile to theMTAfolder:PS C:\Users\<user_name>> cd C:\Users\<user_name>\DownloadsPS C:\Users\<user_name>> Expand-Archive ` -Path "{ProductShortNameLower}-{ProductVersion}-cli-windows.zip" ` -DestinationPath "C:\Users\<user_name>\MTA"Ensure that Docker is running Windows containers the
OS/Archis set towindows/amd64:PS C:\Users\<user_name>> docker versionClient: Version: 27.0.3 API version: 1.46 Go version: go1.21.11 Git commit: 7d4bcd8 Built: Sat Jun 29 00:03:32 2024 OS/Arch: windows/amd64 Context: desktop-windows Server: Docker Desktop 4.32.0 (157355) Engine: Version: 27.0.3 API version: 1.46 (minimum version 1.24) Go version: go1.21.11 Git commit: 662f78c Built: Sat Jun 29 00:02:13 2024 OS/Arch: windows/amd64 Experimental: false
Set the
CONTAINER_TOOLenvironment variable to use Docker:PS C:\Users\<user_name>> $env:CONTAINER_TOOL="C:\Windows\system32\docker.exe"Set the
DOTNET_PROVIDER_IMGenvironment variable to use the upstreamdotnet-external-provider:PS C:\Users\<user_name>> $env:DOTNET_PROVIDER_IMG="quay.io/konveyor/dotnet-external-provider:v0.5.0"Set the
RUNNER_IMGenvironment variable to use the upstream image:PS C:\Users\<user_name>> $env:RUNNER_IMG="quay.io/konveyor/kantra:v0.5.0"
Appendix A. How to contribute to the MTA project
You can help the Migration Toolkit for Applications to cover most application builds and server configurations, including yours.
You can help with any of the following items:
- Send an email to jboss-migration-feedback@redhat.com and let us know what MTA migration rules must cover.
- Provide example applications to test migration rules.
Identify application components and problem areas that might be difficult to migrate:
- Write a short description of the problem migration areas.
- Write a brief overview describing how to solve the problem in migration areas.
- Try Migration Toolkit for Applications on your application. Report any issues you meet. MTA uses Jira as its issue tracking system. If you encounter an issue when using MTA, submit a Jira issue.
Contribute to the Migration Toolkit for Applications rules repository:
- Write a Migration Toolkit for Applications rule to identify or automate a migration process.
Create a test for the new rule.
For more information, see Rule Development Guide.
Contribute to the project source code:
- Create a core rule.
- Improve MTA performance or efficiency.
Any level of involvement is greatly appreciated!
Additional resources