Migrating JSP files

About this task

You can migrate JSP Tablib uri, WebSphere® Multichannel Bank Transformation Toolkit customized tags, page import, and Java code in JSP files. The migration rules of taglib uri and WebSphere Multichannel Bank Transformation Toolkit customized tags are defined in the JSP migration rule file. The migration rules of Java code are defined in the Java migration rule file.

To migrate JSP file, perform the following steps:

Procedure

To migrate a JSP file, do the following steps:

  1. In the Enterprise Explorer pane of IBM® Rational® Application Developer, right-click the JSP file that you want to migrate. If you want to migrate multiple JSP files at the same time, press Shift and select the JSP files that you want to migrate.
  2. Click BTT Migration > Migrate JSP file.
  3. The JSP file is then migrated to the jsp.migrated folder.

Results

The JSP file is migrated to the jsp.migrated folder. If you selected multiple JSP files for migration, all the JSP files are migrated to the jsp.migrated folder at the same time.

The following tables describe the samples for each migration type:

Table 1. Taglib uri migration
Before migration Migration rule After migration
<%@ taglib uri="/WEB-INF/dse.tld" prefix="dse" %> <taglibRule oldTagUrl="/WEB-INF/dse.tld" newTagUrl="/WEB-INF/btt.tld" oldTagPrefix="dse" newTagPrefix="btt"/> <%@ taglib uri="/WEB-INF/btt.tld" prefix="btt" %>
Table 2. Tag migration
Before migration Migration rule After migration
<dse:label text="jspMigrationToolTest"/>

<tagRule oldTitle="dse:label"
newTitle="btt:label"
oldKey="text"
newKey="text_new"
oldVal="jspMigrationToolTest"
newVal=
"jspMigrationToolTest_new"
/>

<btt:label text_new=
"jspMigrationToolTest_new"
/>

Table 3. Page import migration
Before migration Migration rule After migration
<%@page import="com.ibm.dse" %>

<pageImport
oldPattern="com.ibm.dse"
newPattern="com.ibm.btt"/>

<%@page import=“com.ibm.btt"%>
Table 4. Java code migration
Before migration Migration rule After migration

com.ibm.dse.base.
JavaExtensions.
getAlphaUniqueCode()

<simpleRule oldItem="com.ibm.dse" newItem="com.ibm.btt" />

com.ibm.btt.base.
JavaExtensions.
getAlphaUniqueCode()