public class DruidDataSource extends DruidAbstractDataSource implements DruidDataSourceMBean, ManagedDataSource, Referenceable, Closeable, Cloneable, ConnectionPoolDataSource
| 限定符和类型 | 类和说明 |
|---|---|
class |
DruidDataSource.CreateConnectionThread |
class |
DruidDataSource.DestroyConnectionThread |
DruidAbstractDataSource.DruidPoolConnectionFactoryDEFAULT_INITIAL_SIZE, DEFAULT_MAX_ACTIVE_SIZE, DEFAULT_MAX_IDLE, DEFAULT_MAX_WAIT, DEFAULT_MIN_EVICTABLE_IDLE_TIME_MILLIS, DEFAULT_MIN_IDLE, DEFAULT_NUM_TESTS_PER_EVICTION_RUN, DEFAULT_TEST_ON_BORROW, DEFAULT_TEST_ON_RETURN, DEFAULT_TIME_BETWEEN_CONNECT_ERROR_MILLIS, DEFAULT_TIME_BETWEEN_EVICTION_RUNS_MILLIS, DEFAULT_VALIDATION_QUERY, DEFAULT_WHILE_IDLE| 构造器和说明 |
|---|
DruidDataSource() |
addConnectionProperty, closePreapredStatement, createConnectionId, createResultSetId, createStatementId, createTransactionId, decrementCachedPreparedStatementCount, equals, getActiveConnections, getActiveConnectionStackTrace, getCachedPreparedStatementAccessCount, getCachedPreparedStatementCount, getCachedPreparedStatementDeleteCount, getCachedPreparedStatementHitCount, getCachedPreparedStatementMissCount, getClosedPreparedStatementCount, getCommitCount, getCompositeData, getConnectionErrorRetryAttempts, getConnectionInitSqls, getConnectProperties, getCreatedTime, getCreateErrorCount, getCreateTimespanMillis, getCreateTimespanNano, getDbType, getDefaultCatalog, getDefaultReadOnly, getDefaultTransactionIsolation, getDriver, getDriverClassName, getDriverMajorVersion, getDriverMinorVersion, getDupCloseCount, getExceptionSorter, getExceptionSorterClassName, getExecuteCount, getFilterClasses, getID, getInitialSize, getLastCreateError, getLastCreateErrorTime, getLastCreateErrorTimeMillis, getLastError, getLastErrorTime, getLastErrorTimeMillis, getLoginTimeout, getLogWriter, getMaxActive, getMaxIdle, getMaxOpenPreparedStatements, getMaxPoolPreparedStatementPerConnectionSize, getMaxWait, getMaxWaitThreadCount, getMinEvictableIdleTimeMillis, getMinIdle, getName, getNumTestsPerEvictionRun, getObjectName, getParentLogger, getPassword, getPasswordCallback, getPreparedStatementCount, getProxyFilters, getQueryTimeout, getRawDriver, getRawJdbcUrl, getRemoveAbandonedTimeout, getRemoveAbandonedTimeoutMillis, getRollbackCount, getStartTransactionCount, getTimeBetweenConnectErrorMillis, getTimeBetweenEvictionRunsMillis, getTransactionHistogram, getTransactionHistogramRanges, getTransactionHistogramValues, getTransactionQueryTimeout, getTransactionThresholdMillis, getUrl, getUserCallback, getUsername, getValidationQuery, getValidationQueryTimeout, getValidConnectionChecker, getValidConnectionCheckerClassName, incrementCachedPreparedStatementCount, incrementCachedPreparedStatementDeleteCount, incrementCachedPreparedStatementHitCount, incrementCachedPreparedStatementMissCount, incrementClosedPreparedStatementCount, incrementCommitCount, incrementDupCloseCount, incrementExecuteCount, incrementPreparedStatementCount, incrementRollbackCount, incrementStartTransactionCount, isAccessToUnderlyingConnectionAllowed, isBreakAfterAcquireFailure, isDefaultAutoCommit, isDupCloseLogEnable, isLogAbandoned, isOracle, isPoolPreparedStatements, isRemoveAbandoned, isSharePreparedStatements, isTestOnBorrow, isTestOnReturn, isTestWhileIdle, isUseOracleImplicitCache, setAccessToUnderlyingConnectionAllowed, setBreakAfterAcquireFailure, setConnectionErrorRetryAttempts, setConnectionInitSqls, setConnectionProperties, setConnectProperties, setDbType, setDefaultAutoCommit, setDefaultCatalog, setDefaultReadOnly, setDefaultTransactionIsolation, setDriver, setDriverClassName, setDupCloseLogEnable, setExceptionSorter, setExceptionSorter, setExceptionSorterClassName, setFilters, setInitialSize, setLogAbandoned, setLoginTimeout, setLogWriter, setMaxActive, setMaxIdle, setMaxOpenPreparedStatements, setMaxPoolPreparedStatementPerConnectionSize, setMaxWait, setMaxWaitThreadCount, setMinEvictableIdleTimeMillis, setMinIdle, setName, setNumTestsPerEvictionRun, setObjectName, setOracle, setPassword, setPasswordCallback, setPasswordCallbackClassName, setProxyFilters, setQueryTimeout, setRemoveAbandoned, setRemoveAbandonedTimeout, setRemoveAbandonedTimeoutMillis, setSharePreparedStatements, setTestOnBorrow, setTestOnReturn, setTestWhileIdle, setTimeBetweenConnectErrorMillis, setTimeBetweenEvictionRunsMillis, setTransactionQueryTimeout, setTransactionThresholdMillis, setUrl, setUseOracleImplicitCache, setUserCallback, setUsername, setValidationQuery, setValidationQueryTimeout, setValidConnectionChecker, setValidConnectionCheckerClassName, validateConnectionisWrapperFor, unwrapgetObjectNamegetActiveConnectionStackTrace, getCachedPreparedStatementAccessCount, getCachedPreparedStatementCount, getCachedPreparedStatementDeleteCount, getCachedPreparedStatementHitCount, getCachedPreparedStatementMissCount, getClosedPreparedStatementCount, getCommitCount, getConnectionErrorRetryAttempts, getCreatedTime, getCreateErrorCount, getCreateTimespanMillis, getDbType, getDefaultCatalog, getDefaultReadOnly, getDefaultTransactionIsolation, getDriverClassName, getDriverMajorVersion, getDriverMinorVersion, getDupCloseCount, getExceptionSorterClassName, getInitialSize, getLoginTimeout, getMaxActive, getMaxIdle, getMaxOpenPreparedStatements, getMaxPoolPreparedStatementPerConnectionSize, getMaxWait, getMaxWaitThreadCount, getMinEvictableIdleTimeMillis, getMinIdle, getName, getPreparedStatementCount, getQueryTimeout, getRemoveAbandonedTimeoutMillis, getRollbackCount, getStartTransactionCount, getTimeBetweenConnectErrorMillis, getTimeBetweenEvictionRunsMillis, getTransactionHistogramValues, getTransactionQueryTimeout, getTransactionThresholdMillis, getUrl, getUsername, getValidationQuery, getValidationQueryTimeout, getValidConnectionCheckerClassName, isBreakAfterAcquireFailure, isDefaultAutoCommit, isLogAbandoned, isPoolPreparedStatements, isRemoveAbandoned, isSharePreparedStatements, isTestOnBorrow, isTestOnReturn, isTestWhileIdle, isUseOracleImplicitCache, setLogAbandoned, setMaxPoolPreparedStatementPerConnectionSize, setTestOnBorrow, setTestWhileIdle, setTransactionThresholdMillis, setUseOracleImplicitCachegetObjectName, setObjectNamegetLoginTimeout, getLogWriter, getParentLogger, setLoginTimeout, setLogWriterisWrapperFor, unwrappublic String getInitStackTrace()
public boolean isResetStatEnable()
isResetStatEnable 在接口中 DruidDataSourceMBeanpublic void setResetStatEnable(boolean resetStatEnable)
setResetStatEnable 在接口中 DruidDataSourceMBeanpublic long getDiscardCount()
getDiscardCount 在接口中 DruidDataSourceMBeanpublic void restart()
public void resetStat()
resetStat 在接口中 DruidDataSourceMBeanpublic boolean isEnable()
isEnable 在接口中 DruidDataSourceMBeanisEnable 在接口中 ManagedDataSourcepublic void setEnable(boolean enable)
setEnable 在接口中 ManagedDataSourcepublic void setPoolPreparedStatements(boolean value)
public boolean isInited()
public void init()
throws SQLException
SQLExceptionpublic DruidPooledConnection getConnection() throws SQLException
getConnection 在接口中 DataSourceSQLExceptionpublic DruidPooledConnection getConnection(long maxWaitMillis) throws SQLException
SQLExceptionpublic PooledConnection getPooledConnection() throws SQLException
getPooledConnection 在接口中 ConnectionPoolDataSourceSQLExceptionpublic PooledConnection getPooledConnection(String user, String password) throws SQLException
getPooledConnection 在接口中 ConnectionPoolDataSourceSQLExceptionpublic DruidPooledConnection getConnectionDirect(long maxWaitMillis) throws SQLException
SQLExceptionpublic void handleConnectionException(DruidPooledConnection pooledConnection, Throwable t) throws SQLException
handleConnectionException 在类中 DruidAbstractDataSourceSQLExceptionpublic void clearStatementCache()
throws SQLException
clearStatementCache 在接口中 DruidDataSourceMBeanSQLExceptionpublic void close()
close 在接口中 Closeableclose 在接口中 AutoCloseablepublic Connection getConnection(String username, String password) throws SQLException
getConnection 在接口中 DataSourceSQLExceptionpublic long getCreateCount()
getCreateCount 在接口中 DruidAbstractDataSourceMBeanpublic long getDestroyCount()
getDestroyCount 在接口中 DruidAbstractDataSourceMBeanpublic long getConnectCount()
getConnectCount 在接口中 DruidAbstractDataSourceMBeanpublic long getCloseCount()
getCloseCount 在接口中 DruidAbstractDataSourceMBeanpublic long getConnectErrorCount()
public int getPoolingCount()
getPoolingCount 在接口中 DruidAbstractDataSourceMBeanpublic int getPoolingPeak()
getPoolingPeak 在接口中 DruidDataSourceMBeanpublic Date getPoolingPeakTime()
getPoolingPeakTime 在接口中 DruidDataSourceMBeanpublic long getRecycleCount()
getRecycleCount 在接口中 DruidAbstractDataSourceMBeanpublic int getActiveCount()
getActiveCount 在接口中 DruidAbstractDataSourceMBeanpublic boolean isBusy()
public long getRemoveAbandonedCount()
public int removeAbandoned()
removeAbandoned 在接口中 DruidDataSourceMBeanpublic DataSourceProxyConfig getConfig()
public Reference getReference() throws NamingException
getReference 在接口中 ReferenceableNamingExceptionpublic int getRawDriverMajorVersion()
public int getRawDriverMinorVersion()
public String getProperties()
getProperties 在接口中 DruidAbstractDataSourceMBeangetProperties 在类中 DruidAbstractDataSourcepublic void shrink()
shrink 在接口中 DruidDataSourceMBeanpublic void shrink(boolean checkTime)
public int getWaitThreadCount()
getWaitThreadCount 在接口中 DruidDataSourceMBeanpublic long getNotEmptyWaitCount()
getNotEmptyWaitCount 在接口中 DruidDataSourceMBeanpublic int getNotEmptyWaitThreadCount()
public int getNotEmptyWaitThreadPeak()
public long getNotEmptySignalCount()
getNotEmptySignalCount 在接口中 DruidDataSourceMBeanpublic long getNotEmptyWaitMillis()
getNotEmptyWaitMillis 在接口中 DruidDataSourceMBeanpublic long getNotEmptyWaitNanos()
getNotEmptyWaitNanos 在接口中 DruidDataSourceMBeanpublic int getLockQueueLength()
getLockQueueLength 在接口中 DruidDataSourceMBeanpublic int getActivePeak()
getActivePeak 在接口中 DruidDataSourceMBeanpublic Date getActivePeakTime()
getActivePeakTime 在接口中 DruidDataSourceMBeanpublic String dump()
dump 在接口中 DruidDataSourceMBeanpublic long getErrorCount()
getErrorCount 在接口中 DruidDataSourceMBeanpublic void logTransaction(TransactionInfo info)
logTransaction 在类中 DruidAbstractDataSourcepublic String getVersion()
getVersion 在接口中 DruidDataSourceMBeanpublic JdbcDataSourceStat getDataSourceStat()
getDataSourceStat 在接口中 DataSourceProxypublic Object clone() throws CloneNotSupportedException
clone 在类中 ObjectCloneNotSupportedExceptionpublic DruidDataSource cloneDruidDataSource()
public JdbcSqlStat getSqlStat(int sqlId)
public Map<String,JdbcSqlStat> getSqlStatMap()
Copyright © 2012 Alibaba Group. All Rights Reserved.