Technical data
Increasing Performance with the Prepared Statement Cache
Administration Guide 16-33
http://e-docs.bea.com/wls/docs61/javadocs/weblogic/management/c
onfiguration/JDBCConnectionPoolMBean.html
.
n Directly in the configuration file (typically config.xml).
To set the prepared statement cache size for a connection pool using the configuration
file, before starting the server, open the
config.xml file in an editor, then add an entry
for the
PreparedStatementCacheSize attribute in the JDBCConnectionPool tag. For
example:
<JDBCConnectionPool CapacityIncrement="5"
DriverName="com.pointbase.jdbc.jdbcUniversalDriver"
InitialCapacity="5" MaxCapacity="20" Name="demoPool"
Password="{3DES}ANfMduXgaaGMeS8+CR1xoA=="
PreparedStatementCacheSize="20" Properties="user=examples"
RefreshMinutes="0" ShrinkPeriodMinutes="15"
ShrinkingEnabled="true" Targets="examplesServer"
TestConnectionsOnRelease="false"
TestConnectionsOnReserve="false"
URL="jdbc:pointbase:server://localhost/demo"/>
Usage Restrictions for the Prepared Statement Cache
Using the prepared statement cache can dramatically increase performance, but you
must consider its limitations before you decide to use it. Please note the following
restrictions when using the prepared statement cache.
There may be other issues related to caching prepared statements that are not listed
here. If you see errors in your system related to prepared statements, you should set the
prepared statement cache size to
0, which turns off prepared statement caching, to test
if the problem is caused by caching prepared statements.
Calling a Stored Prepared Statement After a Database Change May Cause
Errors
Prepared statements stored in the cache refer to specific database objects at the time
the prepared statement is cached. If you perform any DDL (data definition language)
operations on database objects referenced in prepared statements stored in the cache,
the statements will fail the next time you run them. For example, if you cache a