String alias = "myPool";
ConnectionPoolDefinitionIF cpd = ProxoolFacade.getConnectionPoolDefinition(alias);
If you want to update the definition you should either update the properties
definition next time you
java.sql.Driver.connect ask for a connection or call
ProxoolFacade.updateConnectionPool Proxool directly.
version: $Revision: 1.22 $, $Date: 2004/06/02 20:19:14 $ author: billhorsman author: $Author: billhorsman $ (current maintainer)
getFatalSqlExceptions() Get the list of fatal SQL exception (Strings) fragments that will
trigger the death of a Connection.
All SQLExceptions are caught and tested for containing this
text fragment.
getInjectableCallableStatementInterface() The class name of an interface that should be injected everytime we make a CallableStatement.
Use this when you want to access methods on a concrete class in the vendor's CallableStatement
object that aren't declared in a public interface.
getInjectableConnectionInterface() The class name of an interface that should be injected everytime we make a Connection.
Use this when you want to access methods on a concrete class in the vendor's Connection
object that aren't declared in a public interface.
getInjectablePreparedStatementInterface() The class name of an interface that should be injected everytime we make a PreparedStatement.
Use this when you want to access methods on a concrete class in the vendor's PreparedStatement
object that aren't declared in a public interface.
getInjectableStatementInterface() The class name of an interface that should be injected everytime we make a Statement.
Use this when you want to access methods on a concrete class in the vendor's Statement
object that aren't declared in a public interface.
getMaximumConnectionLifetime() The maximum amount of time that a connection exists for before it is killed (recycled).
int
getMaximumNewConnections() In order to prevent overloading, this is the maximum number of connections that you can have that are in the progress
of being made.
int
getMinimumConnectionCount() The minimum number of connections we will keep open, regardless of whether anyone needs them or not.
getOverloadWithoutRefusalLifetime() This is the time in milliseconds after the last time that we refused a
connection that we still consider ourselves to be overloaded.
getSimultaneousBuildThrottle() In order to prevent overloading, this is the maximum number of connections that you can have that are in the progress
of being made.
If this is not-null then any fatal SQLException is wrapped up inside
an instance of this class. If null, then the original exception is
thrown.
Range: any valid class name that is a subclass of SQLException or RuntimeException
Default: null (original exception is thrown)
the class name to use for fatal SQL exceptions
Get the list of fatal SQL exception (Strings) fragments that will
trigger the death of a Connection.
All SQLExceptions are caught and tested for containing this
text fragment. If it matches than this connection is considered useless
and it is discarded. Regardless of what happens the exception
is always thrown back to the user.
the list of exception fragments (String) See Also:ConnectionPoolDefinitionIF.FATAL_SQL_EXCEPTIONS_DELIMITER
Class getInjectableCallableStatementInterface()(Code)
The class name of an interface that should be injected everytime we make a CallableStatement.
Use this when you want to access methods on a concrete class in the vendor's CallableStatement
object that aren't declared in a public interface. Without this, the CallableStatement that
is provided will only give you access to public interfaces (like CallableStatement and any
other vendor provided ones)
the interface
The class name of an interface that should be injected everytime we make a Connection.
Use this when you want to access methods on a concrete class in the vendor's Connection
object that aren't declared in a public interface. Without this, the connection that
gets served will only give you access to public interfaces (like Connection and any
other vendor provided ones)
the interface
getInjectablePreparedStatementInterface
Class getInjectablePreparedStatementInterface()(Code)
The class name of an interface that should be injected everytime we make a PreparedStatement.
Use this when you want to access methods on a concrete class in the vendor's PreparedStatement
object that aren't declared in a public interface. Without this, the PreparedStatement that
is provided will only give you access to public interfaces (like PreparedStatement and any
other vendor provided ones)
the interface
The class name of an interface that should be injected everytime we make a Statement.
Use this when you want to access methods on a concrete class in the vendor's Statement
object that aren't declared in a public interface. Without this, the statement that
is provided will only give you access to public interfaces (like Statement and any
other vendor provided ones)
the interface
Get a comma separated list of JMX agent ids (as used by
MBeanServerFactory.findMBeanServer(String agentId)) to register the pool to.
a comma separated list of JMX agent ids (as used byMBeanServerFactory.findMBeanServer(String agentId)) to register the pool to.
If the housekeeper comes across a thread that has been active for longer
than this then it will kill it. So make sure you set this to a number bigger
than your slowest expected response!
In order to prevent overloading, this is the maximum number of connections that you can have that are in the progress
of being made. That is, ones we have started to make but haven't finished yet.
ConnectionPoolDefinitionIF.getSimultaneousBuildThrottle
This is the time in milliseconds after the last time that we refused a
connection that we still consider ourselves to be overloaded. We have to do this
because, even when overloaded, it's not impossible for the available connection
count to be high and it's possible to be serving a lot of connections.
Recognising an overload is easy (we refuse a connection) - it's recognising
when we stop being overloaded that is hard. Hence this fudge :)
This is the number of spare connections we will strive to have. So, if we have a prototypeCount of 5 but only 3 spare
connections the prototyper will make an additional 2. This is important because it can take around a seconds to
establish a connection, and if we are being very strict about killing connections when they get too
old it happens a fair bit.
As long as we have one connection that was started within this threshold
then we consider the pool to be up. (That is, not down). This allows us to
differentiate between having all the connections frozen and just being really
busy.
In order to prevent overloading, this is the maximum number of connections that you can have that are in the progress
of being made. That is, ones we have started to make but haven't finished yet.
The sample length (in seconds) when taking statistical information,
or null to disable statistics. Default is null. You can comma delimit
a series of periods. The suffix for the period is either "s" (seconds),
"m" (minutes), "h" (hours) or "d" (days). For example: "15s,1h" would
give two separate sample rates: every 15 seconds and every hour.
statistics definition
If this is true then we start logging a lot of stuff everytime we serve a
connection and everytime the house keeper and prototyper run. Be
prepared for a lot of debug!
true if in verbose mode