mirror of
https://github.com/apache/openjpa.git
synced 2025-02-08 02:59:42 +00:00
OPENJPA-703: Remove sync on stats
git-svn-id: https://svn.apache.org/repos/asf/openjpa/trunk@935035 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
191c7fd329
commit
fb1808b2a3
@ -123,6 +123,7 @@ public interface QueryStatistics<T> extends Serializable {
|
||||
* A default implementation.
|
||||
*
|
||||
* Maintains statistics for only a fixed number of queries.
|
||||
* Statistical counts are approximate and not exact (to keep thread synchorization overhead low).
|
||||
*
|
||||
*/
|
||||
public static class Default<T> implements QueryStatistics<T> {
|
||||
@ -222,7 +223,7 @@ public interface QueryStatistics<T> extends Serializable {
|
||||
target.put(query, row);
|
||||
}
|
||||
|
||||
public synchronized void recordExecution(T query) {
|
||||
public void recordExecution(T query) {
|
||||
if (query == null)
|
||||
return;
|
||||
boolean cached = astats.containsKey(query);
|
||||
|
Loading…
x
Reference in New Issue
Block a user