LOG.error("illegal property 'druid.notFullTimeoutRetryCount'", e); } } } {Stringproperty=properties.getProperty("druid.timeBetweenEvictionRunsMillis");if(property !=null&& property.length() >0) {try{longvalue=Long.parseLong(property);this.setTimeBetweenEvictionRunsMillis(value); }catch(NumberFor...
error("illegal property 'druid.notFullTimeoutRetryCount'", e); } } } { String property = properties.getProperty("druid.timeBetweenEvictionRunsMillis"); if (property != null && property.length() > 0) { try { long value = Long.parseLong(property); this.setTimeBetweenEvictionRunsMillis(...
private boolean isDataSourceAvailable(Plugin plugin, String name, DruidDataSource dataSource, int timeout) { // 指定当前构件 PluginHolder.swithToPlugin(plugin); Connection conn = null; try { conn = dataSource.getConnectionDirect(timeout);// 设置超时时间5m if (conn == null) { throw new SQLE...
默认获取连接方法(getConnectionDirect) getConnectionDirect代码中主要是循环获取连接。主要分为三块代码: getConnectionInternal(maxWaitMillis)获取连接的实例类,获取连接超时会进入catch,在参数notFullTimeoutRetryCnt做累加,并进行重试继续获取连接,一旦重试次数超过this.notFullTimeoutRetryCount则直接抛出当前异常。 testOnB...
LOG.error("illegal property 'druid.notFullTimeoutRetryCount'",e); } } } { //有两个含义: //1) Destroy线程会检测连接的间隔时间,如果连接空闲时间大于等于minEvictableIdleTimeMillis则关闭物理连接。 //2) testWhileIdle的判断依据,详细看testWhileIdle属性的说明 ...
setNotFullTimeoutRetryCount, setNumTestsPerEvictionRun, setObjectName, setOnFatalErrorMaxActive, setOracle, setPassword, setPasswordCallback, setPasswordCallbackClassName, setPhyMaxUseCount, setPhyTimeoutMillis, setProxyFilters, setQueryTimeout, setRemoveAbandoned, setRemoveAbandonedTimeout, setRemoveAbandon...
getNotFullTimeoutRetryCount, getNumTestsPerEvictionRun, getObjectName, getOnFatalErrorMaxActive, getParentLogger, getPassword, getPasswordCallback, getPhyMaxUseCount, getPhyTimeoutMillis, getPreparedStatementCount, getProxyFilters, getQueryTimeout, getRawDriver, getRawJdbcUrl, getRemoveAbandonedTimeout, ge...