Configuring Java CAPS JBI Components for GlassFish Clustering

Setting Up the IEP Database

Default connection pools and JDBC resources are automatically created for an IEP Derby database, as are the Derby database and persistence tables once you enable the engine on the cluster. The tables are automatically created for an Oracle database, but you need to manually create the connection pools and JDBC resources for Oracle.

For Derby, you can customize the default connection pools and JDBC resources if necessary, or create new ones for the cluster. IEP uses both XA and non-XA transactions so two connection pools and JDBC resources are required, one for each type.

For more information about creating connection pools and JDBC resources, see Chapter 3, JDBC Resources, in Sun GlassFish Enterprise Server 2.1 Administration Guide.

ProcedureTo Set Up the IEP Database

  1. If you are using Oracle, do the following. These steps are not necessary for other database platforms.

    1. Copy the Oracle driver (ojdbc14.jar) from your Oracle installation to GlassFish_Home/lib. Restart the GlassFish server.

    2. Create an Oracle database instance using the administrative tools provided by Oracle.

    3. Create the IEP user as described in To Create the IEP User in the Oracle Database in Designing Intelligent Event Processor (IEP) Projects.

  2. Launch the GlassFish Admin Console.

  3. Create and configure two connection pools for the database, one for XA transactions and one for non-XA transactions. Point both connection pools to the same database using the same user name and password.


    Note –

    For Derby, you can use the connection pools that are automatically created when IEP is installed.


    • Select Allow Non Component Callers.

    • For a Derby database, enter the following properties:

      • Host (can be localhost)

      • PortNumber (1527 is the default Derby port)

      • DatabaseName

      • User

      • Password

      • connectionAttributes (set this to ;create=true to automatically create the Derby database)

    • For an Oracle database, enter the following properties:

      • URL (the format for the URL is jdbc:oracle:thin:@hostName:portNumber:databaseName)

      • user

      • password

  4. Create and configure two JDBC resources for the database, one for XA transactions and one for non-XA transactions. After you enter the name and connection pool, do the following:

    1. Under Available Targets, select the cluster and click Add.

    2. Click OK.

      This adds the resource to the cluster and enables the resource on the cluster.

  5. To create the database tables, complete the steps under Adding the IEP Service Engine to the Cluster.