Create a JDBC data source and connection pool.
About this task
The data source is based on the database schema created
as described in Step 3: Creating an empty database schema.
Note: If
you choose to use the Rule Execution Server console
to create the database schema, you must create an empty database.
Procedure
- Ensure that your database is running.
- In the WebLogic Server administration console, in Domain
Structure click and click Data
Sources.
- In the Summary of JDBC Data Sources page
under Data Sources, click New.
- In the Create a New JDBC Data Source page,
name your data source (for example, Rule Execution Server
data source) and type jdbc/resdatasource for
the JNDI name. Select a Database Type.
Click Next.
- Select the Database Driver that
to connect to the database. Use the XA database driver.
Click Next.
- You are provided with information on Transaction
Options and the driver you have selected.
If
you created a connection pool with a non-XA driver and you want to
allow your data source to be involved in XA transactions, select Emulate
Two-Phase Commit. You must also select Supports
Global Transactions.
Click Next.
- Define the Connection Properties.
- Database name
Enter resdb.
- Host name
Enter localhost.
- Port
Enter the port (for example, 0 for the embedded
Derby database).
- Database User Name
Enter RES.
- Password
Use RES and confirm it.
Click Next.
- In the Test Database Connection page,
click Test Configuration to ensure that the
connection pool is operational. If the console displays the following
message, your connection pool is ready to be used.
Connection test succeeded.
Click Next.
- In the Create a New JDBC Data Source page,
under Select Targets and Servers select
the check box next to AdminServer and click Finish.
- Click Activate Changes.
Results
After you have created the JDBC data source and connection
pool, you can view the data pool properties for the selected data
source.
To
view the properties:
In the Domain Structure open and click Data Sources.
In the Summary of JDBC Data Sources page,
click the data source name.
In the Settings page for the data source,
click the Connection Pool tab. The page displays
the data pool properties for the selected data source.