mirror of
https://github.com/alibaba/druid.git
synced 2023-03-04 19:17:16 +00:00
改进PreparedStatementCache
git-svn-id: http://code.alibabatech.com/svn/druid/trunk@915 b9813039-fb51-4c41-a8b9-e21c2acb5095
This commit is contained in:
@@ -118,7 +118,7 @@ public abstract class DruidAbstractDataSource extends WrapperAdapter implements
|
||||
private boolean testOnReturn = DEFAULT_TEST_ON_RETURN;
|
||||
private boolean testWhileIdle = DEFAULT_WHILE_IDLE;
|
||||
protected boolean poolPreparedStatements = false;
|
||||
protected int maxPoolPreparedStatementPerConnectionSize = -1;
|
||||
protected int maxPoolPreparedStatementPerConnectionSize = 10;
|
||||
|
||||
protected boolean inited = false;
|
||||
|
||||
@@ -192,11 +192,11 @@ public abstract class DruidAbstractDataSource extends WrapperAdapter implements
|
||||
public Histogram getTransactionHistogram() {
|
||||
return transactionHistogram;
|
||||
}
|
||||
|
||||
|
||||
public void incrementPreparedStatementCount() {
|
||||
reusePreparedStatement.incrementAndGet();
|
||||
}
|
||||
|
||||
|
||||
public long getReusePreparedStatement() {
|
||||
return reusePreparedStatement.get();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user