PiggyBank complete implementation setup instructions

This sample contains the PiggyBank design model and the complete source code for the PiggyBank online banking application. To run the PiggyBank online banking application sample, import the PiggyBank complete implementation sample and follow these steps.

System prerequisites

To run the sample, you must complete the following tasks:

  • Import the PiggyBank complete implementation sample from the overview page.
  • Install the IBM WebSphere Version 6.1 test environment. If you did not select this option during installation, you can install this feature with the IBM Rational Software Development Platform installer.

The PiggyBank online banking application uses the Cloudscape database, which is included with the IBM Rational Software Development Platform. Cloudscape is an embedded Java™ database and no special installation is required.

The PiggyBank sample must be built before it can be deployed to a server. By default, the workbench is set to automatically build projects. If this option is disabled, click Project > Build all to build all of the projects in the workspace. This might take a few minutes for the code to compile.

After the code builds, you can follow these steps to configure and start the PiggyBank online banking application:

Parent topic: PiggyBank complete implementation

Start the server

To start the server:
  1. Click Window > Open Perspective > Other.
  2. In the Select Perspective window, click J2EE and click OK .
  3. In the J2EE perspective, click the Servers tab.
  4. On the Servers page, select WebSphere Application Server v6.1 and clickStart the server . The server status changes from Stopped to Started in the Servers view.

Deploy the application

To deploy the application:
  1. On the Servers page, right-click the new server; then click Add and remove projects.
  2. To move ItsoAdEAR to the Configured projects, under Available projects, click ItsoAdEAR and click Add.
  3. To move ItsoAdCItyBankEAR to the Configured projects, under Available projects, click ItsoAdCityBankEAR and click Add.

Create the database tables

To create the database tables:
  1. In the Server view, right click on WebSphere Application Server and select Create Tables and Data Source.
  2. If this is the first time you are creating the database tables, uncheck Drop the previously generated database tables.
  3. Click Next, then click Finish to create the table.

Explore the application

To run the creating customers and accounts UI:
  1. In the Project Explorer view, expand Application Client Projects and select ItSoAdCustomerAccountManagerClient.
  2. Click Run > Run.
  3. In the Configuration list, select Websphere V6.1 Application Client and click New.
  4. In the Name field type a configuration name. Ensure that the Enterprise Application value is set to ItSoAdEAR and Application client module is set to ItSoAdCustomerAccountManagerClient .
  5. Click Run.
In the PiggyBank application, specify a customer ID, customer name, and account number and click Apply to create a customer and account.

To run the teller UI to deposit cash:
  1. In the Project Explorer view, expand Application Client Projects and select ItSoAdTellerClient.
  2. Click Run > Run.
  3. In the Configuration list, select Websphere V6.1 Application Client and click New.
  4. In the Name field type a configuration name. Ensure that the Enterprise Application value is set to ItSoAdEAR and the Application client module field is set to ItSoAdTellerClient.
  5. Click Run.

    In the PiggyBank application, enter the credit account number, check reference (can be any value - is not currently validated), and amount (should be less than $100) and click Cash check to deposit a check.

To run the customer UI to transfer cash:
  1. In the Project Explorer view, expand Dynamic Web Projects, and select ItSoAdServlet.
  2. Click Run > Run > Run on Server.
  3. In the Server Selection wizard, ensure that the current server is selected and click Finish.

    The PiggyBank web UI opens automatically. Click PiggyBank Home Banking system and enter the customer ID that you created in the previous step to use the online banking system.


Feedback