Migrating the HelloWorld Application from Sun ONE Application Server 6.x to Sun Java System Application Server 8

Version 1.0

This document explains how to use the Migration Tool for Sun Java System Application Server 8 (hereafter called the Migration Tool) to migrate the HelloWorld application from the Sun ONE Application Server 6.x source server to the Sun Java System Application Server 8 target server. The document also explains how to assemble, deploy, and run the sample application on the target server.

This document contains the following sections:

Overview
Migrating the Application
Deploying and Running the Migrated Application on the Target Server

Overview

HelloWorld Overview briefly describes the HelloWorld sample application.


Migrating the Application

This section describes how to migrate the application from the source server (Sun ONE Application Server 6.x) to the target server (Sun Java Systems Application Server 8).

  1. Set the following environment variables that are used by the Migration Tool's build scripts:


  2. Start the Migration Tool in GUI mode:
  3. On Solaris:

      <ASMT_HOME>/bin> sh asmigrate.sh -u

    On Windows:

      <ASMT_HOME>\bin> asmigrate -u

    Invoking the Migration Tool in Command-Line Mode explains how to run the Migration Tool in command-line mode.

  4. Specify the Source Application (Input) details:

    1. Select "Source" and specify the directory <ASMT_HOME>/examples/ias_6_x/HelloWorld as input to the Migration Tool.


    2. Select the Source Server as Sun ONE Application Server 6.5 from the dropdown list.

  5. Specify the Target Application (Output) details:

    1. Specify a Directory path of your choice to the location where the migrated output application should be written. From here on, this document will refer to this directory path as <OUTPUT_DIR>.


    2. Select the Target Server from the dropdown list. Your only choice is Sun Java Systems Application Server 8.

  6. Press the Migrate button.

    The Migration Tool creates a directory structure that contains the migrated source files and generated build scripts in the output directory that you selected.


  7. Change to the <OUTPUT_DIR>/HelloWorld/src directory and run the appropriate build script to generate the HelloWorld.ear file:

    The build script generates the <OUTPUT_DIR>/HelloWorld/src/asmtbuild/HelloWorld.ear file.


Deploying and Running the Migrated Application on the Target Server

  1. Make sure that you have set the environment variables.

  2. Start the Application Server.

  3. Deploy HelloWorld.ear, the migrated application.

    1. Change to the bin directory in the Application Server and run the following asadmin command:
      asadmin deploy --user username --password password 
        --host hostname --port adminport --type application
        <OUTPUT_DIR>/HelloWorld/src/asmtbuild/HelloWorld.ear
    2. Run the deployed HelloWorld application by accessing the following URL:
        http://localhost:<port>/helloworld

    Index
    Copyright (c) 2004 Sun Microsystems, Inc. All rights reserved.