-
Bug
-
Resolution: Done
-
Major
-
7.3.6.GA
-
False
-
False
-
-
-
-
-
-
+
-
Undefined
-
-
clear-statistics() set createdCount, destroyedCount and inUseCount to 0. Then following parameters calculated based on these will be wrong values.
ActiveCount : createdCount.get() - destroyedCount.get() AvailableCount : maxPoolSize - inUseCount.get(); CreatedCount : createdCount.get() DestroyedCount : destroyedCount.get() IdleCount : getActiveCount() - getInUseCount() InUseCount : inUseCount.get()
1. pool has 5 active connections and 1 of in-use.
[standalone@localhost:9990 /] /subsystem=datasources/data-source=ExampleDS/statistics=pool:read-resource(include-runtime=true) { "outcome" => "success", "result" => { "ActiveCount" => 5, "AvailableCount" => 4, "CreatedCount" => 5, "DestroyedCount" => 0, "IdleCount" => 4, "InUseCount" => 1,
2. clear statistics
[standalone@localhost:9990 /] /subsystem=datasources/data-source=ExampleDS/statistics=pool:clear-statistics()
3. the statistics become following count.
[standalone@localhost:9990 /] /subsystem=datasources/data-source=ExampleDS/statistics=pool:read-resource(include-runtime=true) { "outcome" => "success", "result" => { "ActiveCount" => 0, // 5 is correct "AvailableCount" => 5, // 4 is correct "CreatedCount" => 0, // 5 is correct "DestroyedCount" => 0, // 0 is correct "IdleCount" => 0, // 4 is correct "InUseCount" => 0, // 1 is correct
And if connections are closed by idle-timeout-minutes after clear-statistics(), the destroyedCount can be bigger than createdCount.
Then clear statistics will happen unexpectedly on every idle-timeout-minutes.
org.jboss.jca.core.connectionmanager.pool.PoolStatisticsImpl#getActiveCount()
if (createdCount.get() < destroyedCount.get())
clear();
- clones
-
JBJCA-1425 Datasource clearStatistics operation clears things it shouldn't
- Resolved
- is cloned by
-
JBEAP-21830 [GSS](7.3.z) JBJCA-1425 - Datasource clearStatistics operation clears things it shouldn't
- Closed
- is incorporated by
-
JBEAP-21313 [GSS](7.4.z) Upgrade Ironjacamar from 1.4.30.Final-redhat-00001 to 1.4.35.Final-redhat-00001
- Closed