Preparing for the Online Auction sample application

To build the Online Auction sample application, you need to ensure that all system prerequisites are met and that the development and run-time environments are correctly installed and configured.

System prerequisites

The hardware and operating system prerequisites for building and running the Online Auction sample application are the same as those that are specified for the IBM Rational Developer product. This scenario was developed for the IBM Rational Deployment Toolkit for WebLogic Server.

In addition to IBM Rational Developer and its prerequisites, you need the following software in order to build and run the Online Auction sample application :

The optional software is as follows:

Setting up the development and run-time environments

In preparation for building and running the Online Auction sample application, you need to perform the following activities, which are described in the sections that follow.

Install and configure the CVS server (optional)

In this section, you get some tips on how to install the CVS server and set up the repository for team development. The installation of CVS is optional for the sample application, but there are sections in the sample application instructions that explain how to use it with IBM Rational Developer for team programming. You can download a free copy of CVS from http://www.cvshome.org/.

To install and configure the CVS server:

  1. Install the CVS product using the product zip file. If you are planning to use it for production purposes, it is recommended that you install the product on a Linux server.
  2. Add the repository (or repositories) by creating a directory and running the cvs init command.
  3. Authorize the users. It is recommended that you use an SSH connection method and create a user ID on the server for each developer.
  4. Configure the server to run the SSH daemon by default.

More detailed information about installing, configuring, and using the CVS server can be found in the CVS manual.

Install IBM Rational Developer

Install IBM Rational Developer (and the IBM Rational Deployment Toolkit for WebLogic Server) using the installation instructions that accompany the product.

Install DB2 and run the DB2 script to create the database tables

In this section, you perform the following activities:

IBM Rational Developer includes a copy of DB2 UDB Personal Edition. You can also download a free copy of DB2 UDB Personal Edition from http://www.ibm.com/software/data/db2.

To enable the JDBC 2.0 driver and create the database:

  1. If DB2 is not already installed, install it by running the DB2 installation program.
  2. Change your DB2 installation to use JDBC 2.0 by completing the following steps:
    1. Open a DB2 command window (Start > Programs > IBM DB2 > Command Line Tools > Command Window), then navigate to DB2_installdir\SQLLIB\java12 (where DB2_installdir is the installation path of DB2).
    2. Stop all DB2 services and make a note of the services you stopped, then run the following command to change your database installation to use JDBC 2.0: usejdbc2.bat
    3. Restart the services that you stopped, then in a DB2 command window, issue the following command to ensure the essential DB2 processes are running: db2start.
  3. Create the DB2 UDB SAMPLE database (if not already created) by completing the following steps:
    1. Select Start > Programs > IBM DB2 > Set-up Tools > First Steps.
    2. Click Create Sample Databases.
    3. Select the DB2 UDB Sample check box and click OK. (Note that if you created the sample database previously, the check box will be cleared.)
    4. When a message box indicates that the database has been created, click OK and close the First Steps wizard.
    5. If you would rather create a new database than use the DB2 UDB Sample database, then edit the crtOnlineItems.sql script.
    6. In the DB2 Command Window, navigate to the following directory (where install_path is the directory where you have installed IBM Rational Developer):
      install_path\eclipse\plugins\com.ibm.etools.weblogic.scenario.auction.doc
    7. In the crtOnlineItems.sql script, all tables are created with the schema ejb. Change this to your DB2 username by replacing all occurrences of ejb with your username.
    8. In the DB2 Command Window, run the script by issuing the following command: db2 -tf crtOnlineItems.sql This creates the required tables and populates them with some test data.
    9. Close the DB2 Command Window.

Install and configure BEA WebLogic Server

Install WebLogic Server using the instructions that accompany the product. You will need to set up a WebLogic domain -- refer to the BEA WebLogic documentation for details.

Install IBM Rational Deployment Toolkit for WebLogic Server

To install IBM Rational Deployment Toolkit for WebLogic Server:

  1. Start IBM Rational Developer and open the Install/Update wizard (Help > Software Updates > Find and Install).
  2. Select Search for new features to install and click Next.
  3. You will be using either a remote IBM Rational update site or an archived site from a zip file to install the IBM Rational Deployment Toolkit for WebLogic Server feature.
  4. In the list of sites to search, check the newly added site and click Next.
  5. In the list of features to install, check IBM Rational Deployment Toolkit for WebLogic Server and click Next.
  6. Review and then accept the license that is shown. It must be accepted to complete the install. Click Next to continue to the next page.
  7. Click Finish to start the install process.
  8. The Feature Verification page will identify that the JAR files in the update site have not been signed; this is expected. Click Install to complete the install process.
  9. Allow IBM Rational Developer to restart when prompted.

Once IBM Rational Deployment Toolkit for WebLogic Server has been installed, it is necessary to configure a server preference in IBM Rational Developer to give the toolkit access to server resources.

  1. From the menu, go to Window > Preferences.
  2. Select Server in the left pane. The Server page opens.
  3. Check Create server resources in workspace and click OK.

To create a WebLogic server runtime, do the following:

  1. From the Window menu, select Preferences.
  2. In the Preferences dialog, expand Server and then select Installed Runtimes.
  3. Click the Add button to create a WebLogic runtime.
  4. Select the type of BEA WebLogic server runtime to create and click Next.
  5. Specify the correct paths for your installation of WebLogic.
  6. Click Finish to save your changes.

Tip: Set the highest J2EE version used for development to 1.3 since WebLogic Server only supports up to J2EE 1.3.

  1. From the menu, go to Window > Preferences.
  2. Select J2EE in the left pane. The J2EE page opens.
  3. Set Highest J2EE version used for development to 1.3 and click OK.

Tip: EJB projects that use a WebLogic server should have automatic validation disabled to improve performance. To disable automatic validation in WebSpehere Studio by default:

  1. From the Window menu, select Preferences.
  2. In the Preferences window, click on Validation.
  3. Clear the Allow projects to override these preference settings checkbox and then clear the Run validation automatically when you save changes to a resource checkbox.
  4. Click OK to save your changes.
Terms of use | Feedback
(C) Copyright IBM Corporation 2002, 2004. All Rights Reserved.