Create/Edit Connection Pool

Use this page to configure the Data Source properties and connection pool settings for the JDBC Connection Pool. (Note that this is Step 2 of the JDBC Connection Pool wizard.)

The following table describes the fields and buttons on the screen. The left column lists the fields and buttons; the right column describes the functionality.

Field or Button
Description

Name

This field displays the name of the connection pool used as a reference when creating a JDBC resource.

Datasource Classname

This is the vendor specific classname that implements the DataSource and / or XADataSource APIs.

Description

Provide a brief description for this JDBC Connection Pool. This description is optional.

Back

Steps you back to the prior JDBC Connection Pool wizard screen.

Finish

Click to finish the JDBC Connection Pool wizard.

Properties:

Add

This table allows you to specify standard and proprietary JDBC Data Source properties; many of these properties are optional. By default the names of all of the standard properties are provided. You will need to consult your DB vendor's documentation to determine which standard and vendor specific properties are required. For example, to configure Pointbase 4.2 Server, you need to specify values for the following properties:

  1. databaseName = <url> (for example, "jdbc:pointbase:server://localhost/sample")

  2. user = <username>

  3. password = <password>

tip The remaining properties will be ignored if left blank.

Delete

Mark the checkboxes against the properties you want to delete, and click Delete.

Pool Settings:

Steady Pool Size

This determines the minimum number of connections that will be maintained in the pool and also the number of entries that will be added to the pool on startup.

Max Pool Size

Specify the maximum number of connections allowed.

Pool Resize Quantity

When the pool shrinks toward the steady pool size it is resized in batches. The Pool Resize Quantity value determines the size of the batch into which the steady pool size is resized. Specifying too large a value for this field will delay connection recycling. Specifying a rather small value for this field will make the process less efficient. Please note that the pool capacity is increased by one connection at a time and therefore this field does not effect increases in pool capacity.

Idle Timeout (secs)

The maximum time in seconds that a connection can remain idle in the pool. After this time, the pool implementation can close this connection.

Max Wait time

The amount of time the caller will wait before getting a connection timeout. The default
is wait time is long, which means that a caller can wait for a long time.

Connection Validation:

Connection Validation Required

If you mark this checkbox, then all connections will be validated before they are passed to the application. This allows the application server to automatically re-establish database connections in the case of the database becoming unavailable due to network failure or database server crash. Validation of connections will incur additional overhead and might affect performance negatively.

Validation Method

There are three methods that the application server can employ to validate database connections. You need to understand the capabilities of your database to determine the appropriate one. The three validation methods are:

  • auto-commit, meta-data - the con.getAutoCommit() and con.getMetaData() methods are commonly used to validate a connection. However, many JDBC drivers cache the results of these calls, and therefore they do not always provide a reliable validation. You should check with your vendor to determine whether these calls are cached or not.

  • Table: this method requires Sun JavaTM System Application Server to perform a query on a user specified table. The actual query is "select (count *) from <table- name>". The table must exist and be accessible, though it does not require any rows. You should not use an existing table that has a large number of rows or a table that is already frequently accessed.

Table Name

If you select the last validation option, table, specify the table name here.

Fail All Connections

Check this box to fail all connections in the pool and re-establish them if a single connection is determined to have failed. If left unchecked, connections will be individually re-established only when they are used.

Transaction Isolation

This drop-down list allows you to select the transaction isolation level for this connection. If left unspecified the pool operates with default isolation level provided by the JDBC Driver.

Guarantee Isolation Level

This feature is applicable only if the transaction isolation level has been specified. Marking the Guarantee Isolation Level checkbox ensures that any connection taken from the pool will have the same isolation level. For example if the isolation level for the connection was changed programatically (for example, by using the con.setTransactionIsolation method), when last used, enabling the Guarantee Isolation Level feature will change the isolation level back to the specified isolation level.

Reset

Click Reset if you want to reset the fields to default values.

Save

Saves the completed resource.

See also

Create a Connection Pool


Legal Notices
Copyright © 2004 Sun Microsystems, Inc. All rights reserved.
SUN PROPRIETARY/CONFIDENTIAL