bea.com | products | dev2dev | support | askBEA
 Download Docs   Site Map   Glossary 
Search

WebLogic Server Configuration Reference

 Previous Next Contents Index View as PDF  

JDBCConnectionPool

Description

This bean defines a JDBC connection pool.

Syntax

<!ELEMENT JDBCConnectionPool EMPTY >
<!ATTLIST JDBCConnectionPool
   ACLName                    CDATA                    #IMPLIED
   CapacityIncrement          CDATA                    "1"
   ConnLeakProfilingEnabled   (true | false)           "false"
   DeploymentOrder            CDATA                    "1000"
   DriverName                 CDATA                    #IMPLIED
   InitialCapacity            CDATA                    "1"
   LoginDelaySeconds          CDATA                    "0"
   MaxCapacity                CDATA                    "1"
   Name                       CDATA                    #REQUIRED
   Notes                      CDATA                    #IMPLIED
   Password                   CDATA                    #IMPLIED
   PreparedStatementCacheSize
                              CDATA                    "0"
   Properties                 CDATA                    #IMPLIED
   RefreshMinutes             CDATA                    "0"
   ShrinkPeriodMinutes        CDATA                    "15"
   ShrinkingEnabled           (true | false)           "true"
   SupportsLocalTransaction   (true | false)           "false"
   Targets                    CDATA                    #IMPLIED
   TestConnectionsOnRelease   (true | false)           "false"
   TestConnectionsOnReserve   (true | false)           "false"
   TestTableName              CDATA                    #IMPLIED
   URL                        CDATA                    #IMPLIED
   XAPassword                 CDATA                    #IMPLIED
>

Parent Elements

The JDBCConnectionPool element is a child of the Domain element.

Attributes

Table 21-1 JDBCConnectionPoolMBean Element Attributes

Attribute

Description

Range of Values and Default

Console Label

ACLName

The ACL used to control access to this Connection Pool.


ACLName

Capacity-Increment

Increment by which the connection pool capacity is expanded. When there are no more available physical connections to service requests, the connection pool will create this number of additional physical database connections and add them to the connection pool. The connection pool will ensure that it does not exceed the maximum number of physical connections as set by MaxCapacity.

Default: 1

Minimum: 1

Maximum: 2147483647

Capacity Increment

Conn-Leak-Profiling-Enabled

This property enables JDBC Connection leak profiling.

A Connection leak occurs when a connection from the pool is not closed explicitly by calling close() on that connection.

When connection leak profiling is active, the pool will store the stack trace at the time the Connection object is allocated from the pool and given to the client. When a connection leak is detected (when the Connection object is garbage collected), this stack trace is reported.

This feature uses extra resources and will likely slowdown Connection Pool operations, so it is not recommended for production use.

Default: false

Conn Leak Profiling Enabled

Deployment-Order

A priority that the server uses to determine when it deploys an item. The priority is relative to other deployable items of the same type. For example, the server prioritizes and deploys all startup classes before it prioritizes and deploys EJBs.

Items with the lowest Deployment Order value are deployed first. There is no guarantee on the order of deployments with equal Deployment Order values. There is no guarantee of ordering across clusters.

Default: 1000

Minimum: 0

Maximum: 2147483647

Deployment Order

Driver-Name

The full package name of the JDBC 2-tier driver class used to create the physical connections between WebLogic Server and the DBMS for this connection pool. For example:

com.pointbase.jdbc.jdbcUniversalDriver

It must be the name of a class that implements the java.sql.Driverinterface. Check the documentation for the JDBC driver to find the full pathname.


Driver Classname

Initial-Capacity

The number of physical database connections to create when creating the connection pool.

Default: 1

Minimum: 0

Maximum: 2147483647

Initial Capacity

Login-Delay-Seconds

The number of seconds to delay before creating each physical database connection. This delay takes place both during initial pool creation and during the lifetime of the pool whenever a physical database connection is created.

Default: 0

Minimum: 0

Maximum: 2147483647

Units: seconds

Login Delay Seconds

Max-Capacity

Maximum number of physical database connections that this connection pool can contain. Different JDBC Drivers and database servers may limit the number of possible physical connections.

Default: 1

Minimum: 1

Maximum: 2147483647

Maximum Capacity

Name

The name of this configuration. WebLogic Server uses an MBean to implement and persist the configuration.


Name

Notes

Optional information that you can include to describe this configuration.


Notes

Password

The database password as set with setPassword() or as a key=value pair in setProperties().


Password

Prepared-Statement-Cache-Size

The number of prepared statements stored in the cache for further use. WebLogic Server can reuse prepared statements in the cache without reloading them, which can increase server performance. Setting the size of the prepared statement cache to 0 (the default) turns it off.

Default: 0

Prepared Statement Cache Size

Properties

The list of properties passed to the the 2-tier JDBC Driver to use when creating physical database connections.


Properties (key=value)

Refresh-Minutes

The number of minutes between database connection tests. After every RefreshMinutes interval, unused database connections are tested using TestTableName. Connections that do not pass the test will be closed and reopened to re-establish a valid physical database connection. If TestTableNameis not set, the test will not be performed.

Default: 0

Minimum: 0

Maximum: 2147483647

Units: minutes

Refresh Period

Shrink-Period-Minutes

Number of minutes to wait before shrinking a connection pool that has incrementally increased to meet demand. ShrinkingEnabledmust be set to true for a connection pool to shrink.

Default: 15

Minimum: 1

Maximum: 2147483647

Units: minutes

Shrink Period

Shrinking-Enabled

Indicates whether or not the pool can shrink back to its InitialCapacitywhen it is detected that connections created during increased traffic are not being used.

Default: true

Allow Shrinking

Supports-Local-Transaction

Set to true if the XA driver used to create physical database connections supports SQL without global transactions. Set to false (the default) if the XA driver does not support SQL without global transactions.

This property applies to connection pools that use an XA driver only, and is ignored for connection pools that use non-XA drivers.

Default: false

Supports Local Transaction

Targets

The targets in the current domain on which this item can be deployed.


Targets

Test-Connections-On-Release

When set to true, WebLogic Server tests a connection before returning it to the connection pool. If all connections in the pool are already in use and a client is waiting for a connection, the client's wait will be slightly longer while the connection is tested.

Default: false

Test Released Connections

Test-Connections-On-Reserve

When set to true, WebLogic Server tests a connection before giving it to the client. The test adds a small delay in serving the client's request for a connection from the pool, but ensures that the client receives a working connection (assuming that the DBMS is available and accessible).

Default: false

Test Reserved Connections

Test-Table-Name

The name of the table used when testing a physical database connection. The default SQL code used to test a connection is

"select count(*) from TestTableName"

The TestTableName must exist and be accessible to the database user for the connection. Most database servers optimize this SQL to avoid a table scan, but it is still a good idea to set TestTableName to the name of a table that is known to have few rows, or even no rows.

If TestTableName begins with "SQL ", then the rest of the string following that leading token will be taken as a literal sql statement that will be used to test a connection.


Test Table Name

URL

The database URL used to create the connections in this Connection Pool.


URL

XAPassword

XAPassword attribute If set, this value overrides the password in the open string. This password is used to create physical XA database connections. The value is stored in an encrypted form in the config.xml and can be used to avoid storing cleartext passwords in that file.


Open String Password


 

 

Back to Top Previous Next