Chapter 4. Using the migration tool on a .niogit directory
The .niogit
directory of your Business Central distribution contains all Business Central data. You can use the Business Central migration tool on your .niogit
directory to prepare project data and system configurations for migration to Red Hat Process Automation Manager 7.5.
Prerequisites
Red Hat Process Automation Manager 7.5 is installed.
NoteDo not run Red Hat Process Automation Manager 7.5 Business Central until you have completed the steps in this section.
- Red Hat Process Automation Manager 7.4 is installed and Business Central is not running on Red Hat Process Automation Manager 7.4.
- JDK 8 is installed and is available on the path where the project migration tool will be installed.
Procedure
Locate the
bin/.niogit
directory in your Red Hat Process Automation Manager 7.4 installation and locate the same directory in your new Red Hat Process Automation Manager 7.5 installation.Example:
$ ~/$RHPAM_7.4_HOME/bin/.niogit
$ ~/$RHPAM_7.5_HOME/bin/.niogit
In your command terminal, copy the
.niogit
directory from your current Business Central distribution for Red Hat Process Automation Manager 7.4 to thebin
folder of the new Red Hat Process Automation Manager 7.5 installation directory:cp -r /$RHPAM_7.4_HOME/bin/.niogit /$RHPAM_7.5_HOME/bin/
The copied
.niogit
folder is the directory that the migration tool will prepare for Red Hat Process Automation Manager 7.5. . The original.niogit
folder remains in your Red Hat Process Automation Manager 7.4 installation and will not be modified by the migration tool in this procedure.-
In the Red Hat Process Automation Manager 7.5.
bin
directory, delete the.index
directory. You must delete this folder because Red Hat Process Automation Manager 7.5 comes with certain updates that are not compatible with Red Hat Process Automation Manager 7.4. Thebin
directory will be re-indexed after the migration when you start Red Hat Process Automation Manager 7.5. -
Note the path to the copied
.niogit
directory for Red Hat Process Automation Manager 7.5. The path will be required when you run the migration tool. If you have specific
dependencies
,repositories
, orpluginRepositories
that you want to add, remove, or update as part of the project migration, create apom-migration.json
file containing these elements. When you run the migration tool, the tool will prompt you if you want to include this file in the migration.The
pom-migration.json
file requires the following sections:-
"dependencies":[]
-
"repositories-add":[]
-
"repositories-remove":[]
-
"repositories-update-urls":[]
-
"pluginRepositories-add":[]
-
"pluginRepositories-remove":[]
-
"pluginRepositories-update-urls":[]
If any of these elements do not apply to your project, include them as empty sections to prevent parsing errors.
Example
pom-migration.json
file:{ "dependencies":[ {"groupId":"junit", "artifactId":"junit", "version":"4.12", "scope":"test"}, {"groupId":"com.thoughtworks.xstream", "artifactId":"xstream", "version":"4.12", "scope":"test"} ], "repositories-add":[ { "id":"jboss-public-repository-group", "name":"JBoss Public Repository Group", "url":"http://repository.jboss.org/nexus/content/groups/public/", "releasesEnabled":true, "releasesUpdatePolicy":"never", "snapshotEnabled":true, "snapshotUpdatePolicy":"never" }, { "id":"kie-internal-staging-repository-group", "name":"KIE Internal Staging Repositories", "url":"https://origin-repository.jboss.org/nexus/content/groups/kie-internal-group", "releasesEnabled":true, "releasesUpdatePolicy":"never", "snapshotEnabled":false, "snapshotUpdatePolicy":"never" } ], "repositories-remove":[ { "id":"productization-repository", "url":"http://download.lab.bos.redhat.com/brewroot/repos/jb-ip-6.1-build/latest/maven/" } ], "repositories-update-urls":[ { "id":"guvnor-m2-repo", "url":"http://localhost:8080/business-central/maven3/" } ], "pluginRepositories-add":[ { "id":"jboss-public-repository-group", "name":"JBoss Public Repository Group", "url":"http://repository.jboss.org/nexus/content/groups/public/", "releasesEnabled":true, "releasesUpdatePolicy":"never", "snapshotEnabled":true, "snapshotUpdatePolicy":"never" }, { "id":"kie-internal-staging-repository-group", "name":"KIE Internal Staging Repositories", "url":"https://origin-repository.jboss.org/nexus/content/groups/kie-internal-group", "releasesEnabled":true, "releasesUpdatePolicy":"never", "snapshotEnabled":false, "snapshotUpdatePolicy":"never" } ], "pluginRepositories-remove":[], "pluginRepositories-update-urls":[] }
Example
pom-migration.json
file withdependencies
only:{ "dependencies":[ {"groupId":"junit", "artifactId":"junit", "version":"4.12", "scope":"test"}, {"groupId":"com.thoughtworks.xstream", "artifactId":"xstream", "version":"4.12", "scope":"test"} ], "repositories-add":[], "repositories-remove":[], "repositories-update-urls":[], "pluginRepositories-add":[], "pluginRepositories-remove":[], "pluginRepositories-update-urls":[] }
-
Navigate to the Software Downloads page in the Red Hat Customer Portal (login required), and select the product and version from the drop-down options:
- Product: Process Automation Manager
- Version: 7.5
-
Download Red Hat Process Automation Manager 7.5 Add-Ons and extract the downloaded
rhpam-7.5.0-add-ons.zip
file to a temporary directory. -
In the extracted
rhpam-7.4.0-add-ons
folder, extract therhpam-7.5-migration-tool.zip
sub-folder. The migration tool is in thebin
directory. In your command terminal, navigate to the temporary directory where you extracted the
rhpam-7.5-migration-tool
folder and run the migration tool. The$RHPAM_NIOGIT_DIR
portion is the path to the.niogit
directory that you previously copied to the Red Hat Process Automation Manager 7.5 installation.On Linux or UNIX-based systems:
$ cd $INSTALL_DIR/rhpam-7.5-migration-tool/bin $ ./migration-tool.sh -t $RHPAM_NIOGIT_DIR
On Windows systems:
$ cd $INSTALL_DIR\rhpam-7.5-migration-tool\bin $ migration-tool.bat -t $RHPAM_NIOGIT_DIR
In the command prompt that appears, the following options are displayed:
- Project structure migration: Migrates the Red Hat Process Automation Manager 7.4 project repository structure to the new project-oriented structure used in Red Hat Process Automation Manager 7.4.
-
System configuration directory structure migration: Migrates the
system.git
repository structure used in Red Hat Process Automation Manager 7.4 to the new structure used in Red Hat Process Automation Manager 7.5. This migration option requires the project structure migration to be executed first. - Forms migration: Migrates forms created in the Red Hat JBoss BPM Suite forms designer to the new forms designer. With this migration option, you must first complete the project structure migration and system configuration directory structure migration.
-
POMs migration: Updates
pom.xml
files with dependencies required for Red Hat Process Automation Manager 7.5. This migration option requires the project structure migration, system configuration directory structure migration, and forms migration to be executed first. - All: Runs all migration options in sequence.
- Exit: Exits the migration tool.
Select the option to run All migrations in sequence.
NoteIf you prefer to run one migration option at a time, select and run the first individual migration option. After the tool runs, re-run the Business Central migration tool and select the next individual migration option in the sequence.
Enter
yes
each time you are prompted to run a specific migration option.For the POMs migration option, if you want to include a path to an external
pom-migration.json
file that you created previously, enteryes
when prompted and enter the path.After the tool finishes running, enter the option to Exit the migration tool.
The
.niogit
directory structure is now compatible with Business Central in Red Hat Process Automation Manager 7.5.-
Project directories are in separate repositories and all other related configurations have been migrated. You can navigate to the new
.niogit
directory to inspect the restructured contents.