Package com.sun.gjc.spi
Class CPManagedConnectionFactory
- java.lang.Object
-
- com.sun.gjc.spi.ManagedConnectionFactoryImpl
-
- com.sun.gjc.spi.CPManagedConnectionFactory
-
- All Implemented Interfaces:
MCFLifecycleListener,jakarta.resource.spi.ManagedConnectionFactory,jakarta.resource.spi.ResourceAdapterAssociation,jakarta.resource.spi.ValidatingManagedConnectionFactory,Externalizable,Serializable
@ConnectionDefinition(connectionFactory=javax.sql.DataSource.class, connectionFactoryImpl=AbstractDataSource.class, connection=java.sql.Connection.class, connectionImpl=ConnectionHolder.class) public class CPManagedConnectionFactory extends ManagedConnectionFactoryImpl
Connection PoolManagedConnectionFactoryimplementation for Generic JDBC Connector.- Version:
- 1.0, 02/07/30
- Author:
- Evani Sai Surya Kiran
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class com.sun.gjc.spi.ManagedConnectionFactoryImpl
cm_, dsObjBuilder, isLazyCm_, JVM_OPTION_STATEMENT_WRAPPING_NOT_SET, JVM_OPTION_STATEMENT_WRAPPING_OFF, JVM_OPTION_STATEMENT_WRAPPING_ON, localStrings, logWriter, ra, spec, sqlTraceDelegator, statementWrapping
-
-
Constructor Summary
Constructors Constructor Description CPManagedConnectionFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description jakarta.resource.spi.ManagedConnectioncreateManagedConnection(Subject subject, jakarta.resource.spi.ConnectionRequestInfo cxRequestInfo)Creates a new physical connection to the underlying EIS resource manager.booleanequals(Object other)Check if thisManagedConnectionFactoryis equal to anotherManagedConnectionFactory.ConnectionPoolDataSourcegetDataSource()Returns the underlying datasourceStringgetInitialPoolSize()Gets the initial pool size.StringgetMaxIdleTime()Gets the maximum idle time.StringgetMaxPoolSize()Gets the maximum pool size.StringgetMaxStatements()Gets the max statements.StringgetMinPoolSize()Gets the minimum pool size.StringgetPropertyCycle()Gets the property cycle.inthashCode()Returns the hash code for thisManagedConnectionFactoryImpl.voidsetInitialPoolSize(String initPoolSz)Sets the initial pool size.voidsetMaxIdleTime(String maxIdleTime)Sets the maximum idle time.voidsetMaxPoolSize(String maxPoolSz)Sets the maximum pool size.voidsetMaxStatements(String maxStmts)Sets the max statements.voidsetMinPoolSize(String minPoolSz)Sets the minimum pool size.voidsetPropertyCycle(String propCycle)Sets the property cycle.-
Methods inherited from class com.sun.gjc.spi.ManagedConnectionFactoryImpl
computeStatementWrappingStatus, constructManagedConnection, createConnectionFactory, createConnectionFactory, getApplicationName, getClassName, getConnectionValidationRequired, getDatabaseName, getDataSourceName, getDelimiter, getDescription, getDriverProperties, getEscapeCharacter, getGuaranteeIsolationLevel, getInitSql, getInvalidConnections, getJdbcObjectsFactory, getLoginTimeOut, getLogJdbcCalls, getLogWriter, getMaxCacheSize, getModuleName, getNetworkProtocol, getNumberOfTopQueriesToReport, getPassword, getPoolInfo, getPoolMonitoringSubTreeRoot, getPoolName, getPortNumber, getResourceAdapter, getRoleName, getServerName, getSlowQueryThresholdInSeconds, getSqlTraceListeners, getStatementCacheSize, getStatementCacheType, getStatementLeakReclaim, getStatementLeakTimeoutInSeconds, getStatementTimeout, getStatementWrapping, getTimeToKeepQueriesInMinutes, getTransactionIsolation, getUser, getValidationClassName, getValidationMethod, getValidationTableName, isEqual, isStatementWrappingEnabled, isValidByAutoCommit, isValidByCustomValidation, isValidByMetaData, isValidByTableQuery, logFine, matchManagedConnections, mcfCreated, mcfDestroyed, readExternal, setApplicationName, setClassName, setConnectionValidationRequired, setDatabaseName, setDataSourceName, setDelimiter, setDescription, setDriverProperties, setEscapeCharacter, setGuaranteeIsolationLevel, setInitSql, setIsolation, setLoginTimeOut, setLogJdbcCalls, setLogWriter, setMaxCacheSize, setModuleName, setNetworkProtocol, setNumberOfTopQueriesToReport, setPassword, setPoolMonitoringSubTreeRoot, setPoolName, setPortNumber, setResourceAdapter, setRoleName, setServerName, setSlowQueryThresholdInSeconds, setSqlTraceListeners, setStatementCacheSize, setStatementCacheType, setStatementLeakReclaim, setStatementLeakTimeoutInSeconds, setStatementTimeout, setStatementWrapping, setTimeToKeepQueriesInMinutes, setTransactionIsolation, setUser, setValidationClassName, setValidationMethod, setValidationTableName, validateAndSetIsolation, writeExternal
-
-
-
-
Method Detail
-
getDataSource
public ConnectionPoolDataSource getDataSource() throws jakarta.resource.ResourceException
Returns the underlying datasource- Overrides:
getDataSourcein classManagedConnectionFactoryImpl- Returns:
- DataSource of jdbc vendor
- Throws:
jakarta.resource.ResourceException
-
createManagedConnection
public jakarta.resource.spi.ManagedConnection createManagedConnection(Subject subject, jakarta.resource.spi.ConnectionRequestInfo cxRequestInfo) throws jakarta.resource.ResourceException
Creates a new physical connection to the underlying EIS resource manager.- Specified by:
createManagedConnectionin interfacejakarta.resource.spi.ManagedConnectionFactory- Specified by:
createManagedConnectionin classManagedConnectionFactoryImpl- Parameters:
subject-Subjectinstance passed by the application servercxRequestInfo-ConnectionRequestInfowhich may be created as a result of the invocationgetConnection(user, password)on theDataSourceobject- Returns:
ManagedConnectionobject created- Throws:
jakarta.resource.ResourceException- if there is an error in instantiating theDataSourceobject used for the creation of theManagedConnectionobjectSecurityException- if there inoPasswordCredentialobject satisfying this requestjakarta.resource.spi.ResourceAllocationException- if there is an error in allocating the physical connection
-
equals
public boolean equals(Object other)
Check if thisManagedConnectionFactoryis equal to anotherManagedConnectionFactory.- Specified by:
equalsin interfacejakarta.resource.spi.ManagedConnectionFactory- Specified by:
equalsin classManagedConnectionFactoryImpl- Parameters:
other-ManagedConnectionFactoryobject for checking equality with- Returns:
- true if the property sets of both the
ManagedConnectionFactoryobjects are the same false otherwise
-
hashCode
public int hashCode()
Description copied from class:ManagedConnectionFactoryImplReturns the hash code for thisManagedConnectionFactoryImpl.- Specified by:
hashCodein interfacejakarta.resource.spi.ManagedConnectionFactory- Overrides:
hashCodein classManagedConnectionFactoryImpl- Returns:
- hash code for this
ManagedConnectionFactoryImpl
-
setMaxStatements
public void setMaxStatements(String maxStmts)
Sets the max statements.- Parameters:
maxStmts-String- See Also:
getMaxStatements
-
getMaxStatements
public String getMaxStatements()
Gets the max statements.- Returns:
- maxStmts
- See Also:
setMaxStatements
-
setInitialPoolSize
public void setInitialPoolSize(String initPoolSz)
Sets the initial pool size.- Parameters:
initPoolSz-String- See Also:
getInitialPoolSize
-
getInitialPoolSize
public String getInitialPoolSize()
Gets the initial pool size.- Returns:
- initPoolSz
- See Also:
setInitialPoolSize
-
setMinPoolSize
public void setMinPoolSize(String minPoolSz)
Sets the minimum pool size.- Parameters:
minPoolSz-String- See Also:
getMinPoolSize
-
getMinPoolSize
public String getMinPoolSize()
Gets the minimum pool size.- Returns:
- minPoolSz
- See Also:
setMinPoolSize
-
setMaxPoolSize
public void setMaxPoolSize(String maxPoolSz)
Sets the maximum pool size.- Parameters:
maxPoolSz-String- See Also:
getMaxPoolSize
-
getMaxPoolSize
public String getMaxPoolSize()
Gets the maximum pool size.- Returns:
- maxPoolSz
- See Also:
setMaxPoolSize
-
setMaxIdleTime
public void setMaxIdleTime(String maxIdleTime)
Sets the maximum idle time.- Parameters:
maxIdleTime- String- See Also:
getMaxIdleTime
-
getMaxIdleTime
public String getMaxIdleTime()
Gets the maximum idle time.- Returns:
- maxIdleTime
- See Also:
setMaxIdleTime
-
setPropertyCycle
public void setPropertyCycle(String propCycle)
Sets the property cycle.- Parameters:
propCycle-String- See Also:
getPropertyCycle
-
getPropertyCycle
public String getPropertyCycle()
Gets the property cycle.- Returns:
- propCycle
- See Also:
setPropertyCycle
-
-