ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From yzhda...@apache.org
Subject [22/23] ignite git commit: Merge branches 'ignite-1.4-slow-server-debug' and 'master' of https://git-wip-us.apache.org/repos/asf/ignite into ignite-1.4-slow-server-debug
Date Wed, 28 Oct 2015 15:23:11 GMT
Merge branches 'ignite-1.4-slow-server-debug' and 'master' of https://git-wip-us.apache.org/repos/asf/ignite
into ignite-1.4-slow-server-debug

Conflicts:
	modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedTxRemoteAdapter.java
	modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearTxFinishFuture.java
	modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxManager.java


Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/502223a8
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/502223a8
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/502223a8

Branch: refs/heads/ignite-1.4-slow-server-debug
Commit: 502223a8a5e9d88b90f402298013b503817181e7
Parents: 10956be 215b0cd
Author: Yakov Zhdanov <yzhdanov@gridgain.com>
Authored: Wed Oct 28 18:21:51 2015 +0300
Committer: Yakov Zhdanov <yzhdanov@gridgain.com>
Committed: Wed Oct 28 18:21:51 2015 +0300

----------------------------------------------------------------------
 .../configuration/TransactionConfiguration.java |    6 +-
 .../apache/ignite/internal/IgniteKernal.java    |   69 +-
 .../processors/cache/CacheMetricsImpl.java      |   12 +-
 .../processors/cache/GridCacheAdapter.java      |  459 +-
 .../processors/cache/GridCacheEntryEx.java      |   62 +-
 .../processors/cache/GridCacheMapEntry.java     |  137 +-
 .../processors/cache/GridCacheMvcc.java         |  143 +-
 .../cache/GridCacheMvccCandidate.java           |   26 +-
 .../processors/cache/GridCacheProcessor.java    |   13 -
 .../distributed/GridDistributedCacheEntry.java  |   12 +-
 .../GridDistributedTxRemoteAdapter.java         |   59 +-
 .../dht/CacheDistributedGetFutureAdapter.java   |  158 +
 .../distributed/dht/GridDhtCacheAdapter.java    |   17 +-
 .../distributed/dht/GridDhtCacheEntry.java      |   23 +-
 .../cache/distributed/dht/GridDhtGetFuture.java |  199 +-
 .../distributed/dht/GridDhtLockFuture.java      |    5 +-
 .../dht/GridDhtTransactionalCacheAdapter.java   |  105 +-
 .../cache/distributed/dht/GridDhtTxLocal.java   |    4 +-
 .../distributed/dht/GridDhtTxPrepareFuture.java |  109 +-
 .../dht/GridPartitionedGetFuture.java           |  179 +-
 .../dht/atomic/GridDhtAtomicCache.java          |   16 +-
 .../dht/colocated/GridDhtColocatedCache.java    |  130 +-
 .../colocated/GridDhtColocatedLockFuture.java   |    6 +-
 .../distributed/near/GridNearAtomicCache.java   |    2 -
 .../distributed/near/GridNearCacheAdapter.java  |   32 +-
 .../distributed/near/GridNearCacheEntry.java    |   81 +-
 .../distributed/near/GridNearGetFuture.java     |  340 +-
 .../distributed/near/GridNearGetRequest.java    |    3 -
 ...arOptimisticSerializableTxPrepareFuture.java |  930 ++++
 .../near/GridNearOptimisticTxPrepareFuture.java |  252 +-
 ...ridNearOptimisticTxPrepareFutureAdapter.java |  222 +
 .../GridNearPessimisticTxPrepareFuture.java     |    8 +-
 .../near/GridNearTransactionalCache.java        |   14 +-
 .../near/GridNearTxFinishFuture.java            |   16 +-
 .../cache/distributed/near/GridNearTxLocal.java |  157 +-
 .../near/GridNearTxPrepareFutureAdapter.java    |   13 +-
 .../cache/local/GridLocalCacheEntry.java        |   23 +-
 .../cache/local/GridLocalLockFuture.java        |    2 +
 .../local/atomic/GridLocalAtomicCache.java      |    9 -
 .../transactions/IgniteTransactionsImpl.java    |    6 -
 .../cache/transactions/IgniteTxAdapter.java     |  123 +-
 .../cache/transactions/IgniteTxEntry.java       |   51 +-
 .../cache/transactions/IgniteTxHandler.java     |    4 +-
 .../transactions/IgniteTxLocalAdapter.java      |  832 ++--
 .../cache/transactions/IgniteTxLocalEx.java     |   27 +-
 .../cache/transactions/IgniteTxManager.java     |  325 +-
 .../cache/version/GridCacheVersionManager.java  |   73 +-
 .../datastreamer/DataStreamerImpl.java          |    2 +-
 .../apache/ignite/transactions/Transaction.java |    2 +-
 .../transactions/TransactionIsolation.java      |    3 +-
 .../fair/FairAffinityDynamicCacheSelfTest.java  |    2 +
 .../GridDiscoveryManagerAttributesSelfTest.java |   23 +-
 .../cache/CacheNearReaderUpdateTest.java        |  388 ++
 .../CacheSerializableTransactionsTest.java      | 4297 ++++++++++++++++++
 .../cache/CrossCacheTxRandomOperationsTest.java |    6 +
 .../GridCacheAbstractFailoverSelfTest.java      |   14 +-
 .../cache/GridCacheAbstractFullApiSelfTest.java |    4 +-
 .../GridCacheAbstractRemoveFailureTest.java     |   94 +-
 .../GridCacheConcurrentTxMultiNodeTest.java     |    3 -
 .../cache/GridCacheMvccFlagsTest.java           |    6 +-
 .../cache/GridCacheMvccPartitionedSelfTest.java |  164 +
 .../processors/cache/GridCacheMvccSelfTest.java |    3 +-
 .../processors/cache/GridCacheTestEntryEx.java  |   53 +-
 .../processors/cache/IgniteTxAbstractTest.java  |   42 +-
 .../IgniteTxMultiThreadedAbstractTest.java      |  106 +-
 ...onedNearDisabledTxMultiThreadedSelfTest.java |   31 +
 ...niteCacheClientNodeChangingTopologyTest.java |  170 +-
 .../IgniteCacheCrossCacheTxFailoverTest.java    |   19 +
 .../dht/IgniteCacheLockFailoverSelfTest.java    |   11 +
 ...eAtomicInvalidPartitionHandlingSelfTest.java |    6 +-
 .../near/GridCacheNearTxExceptionSelfTest.java  |    1 +
 ...CachePartitionedTxMultiThreadedSelfTest.java |   15 +-
 .../DataStreamerUpdateAfterLoadTest.java        |  184 +
 .../loadtests/hashmap/GridHashMapLoadTest.java  |    6 +-
 .../inmemory/GridTestSwapSpaceSpi.java          |    8 +
 .../junits/common/GridCommonAbstractTest.java   |   19 +-
 .../ignite/testsuites/IgniteCacheTestSuite.java |    4 +-
 .../testsuites/IgniteCacheTestSuite2.java       |    2 +
 .../testsuites/IgniteCacheTestSuite5.java       |   40 +
 modules/jms11/pom.xml                           |    9 +-
 .../stream/jms11/IgniteJmsStreamerTest.java     |    9 +-
 .../apache/ignite/stream/mqtt/MqttStreamer.java |  386 +-
 .../stream/mqtt/IgniteMqttStreamerTest.java     |  142 +-
 .../mqtt/IgniteMqttStreamerTestSuite.java       |    4 +-
 .../config/benchmark-multicast.properties       |    5 +-
 .../IgniteAccountSerializableTxBenchmark.java   |   81 +
 .../cache/IgniteAccountTxAbstractBenchmark.java |   61 +
 .../cache/IgniteAccountTxBenchmark.java         |   74 +
 .../cache/IgniteCacheAbstractBenchmark.java     |    7 +-
 .../IgnitePutAllSerializableTxBenchmark.java    |   77 +
 .../ignite/yardstick/cache/model/Account.java   |   42 +
 91 files changed, 9644 insertions(+), 2475 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheEntryEx.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedCacheEntry.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedTxRemoteAdapter.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedTxRemoteAdapter.java
index e164be0,fcbf58d..93303c8
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedTxRemoteAdapter.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedTxRemoteAdapter.java
@@@ -577,17 -579,37 +579,37 @@@ public class GridDistributedTxRemoteAda
                                      if (op == CREATE || op == UPDATE) {
                                          // Invalidate only for near nodes (backups cannot
be invalidated).
                                          if (isSystemInvalidate() || (isInvalidate() &&
cacheCtx.isNear()))
-                                             cached.innerRemove(this, eventNodeId(), nodeId,
-                                                 false, true, true,
-                                                 topVer, null, replicate ? DR_BACKUP : DR_NONE,
-                                                 near() ? null : explicitVer, CU.subjectId(this,
cctx),
-                                                 resolveTaskName());
+                                             cached.innerRemove(this,
+                                                 eventNodeId(),
+                                                 nodeId,
+                                                 false,
 -                                                false,
+                                                 true,
+                                                 true,
+                                                 topVer,
+                                                 null,
+                                                 replicate ? DR_BACKUP : DR_NONE,
 -                                                near() ? null : explicitVer, CU.subjectId(this,
cctx),
++                                                near() ? null : explicitVer,
++                                                CU.subjectId(this, cctx),
+                                                 resolveTaskName(),
+                                                 dhtVer);
                                          else {
-                                             cached.innerSet(this, eventNodeId(), nodeId,
val, false, false,
-                                                 txEntry.ttl(), true, true, topVer, null,
-                                                 replicate ? DR_BACKUP : DR_NONE, txEntry.conflictExpireTime(),
-                                                 near() ? null : explicitVer, CU.subjectId(this,
cctx),
-                                                 resolveTaskName());
+                                             cached.innerSet(this,
+                                                 eventNodeId(),
+                                                 nodeId,
+                                                 val,
+                                                 false,
+                                                 false,
+                                                 txEntry.ttl(),
+                                                 true,
+                                                 true,
+                                                 topVer,
+                                                 null,
+                                                 replicate ? DR_BACKUP : DR_NONE,
+                                                 txEntry.conflictExpireTime(),
+                                                 near() ? null : explicitVer,
+                                                 CU.subjectId(this, cctx),
+                                                 resolveTaskName(),
+                                                 dhtVer);
  
                                              // Keep near entry up to date.
                                              if (nearCached != null) {
@@@ -603,10 -625,20 +625,19 @@@
                                          }
                                      }
                                      else if (op == DELETE) {
-                                         cached.innerRemove(this, eventNodeId(), nodeId,
-                                             false, true, true,
-                                             topVer, null, replicate ? DR_BACKUP : DR_NONE,
-                                             near() ? null : explicitVer, CU.subjectId(this,
cctx), resolveTaskName());
+                                         cached.innerRemove(this,
+                                             eventNodeId(),
+                                             nodeId,
+                                             false,
 -                                            false,
+                                             true,
+                                             true,
+                                             topVer,
+                                             null,
+                                             replicate ? DR_BACKUP : DR_NONE,
+                                             near() ? null : explicitVer,
+                                             CU.subjectId(this, cctx),
+                                             resolveTaskName(),
+                                             dhtVer);
  
                                          // Keep near entry up to date.
                                          if (nearCached != null)

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtLockFuture.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTransactionalCacheAdapter.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
index 48fa133,d806801..612e2bb
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
@@@ -59,7 -56,9 +58,8 @@@ import org.apache.ignite.internal.proce
  import org.apache.ignite.internal.processors.cache.transactions.IgniteTxKey;
  import org.apache.ignite.internal.processors.cache.version.GridCacheVersion;
  import org.apache.ignite.internal.processors.dr.GridDrType;
+ import org.apache.ignite.internal.transactions.IgniteTxOptimisticCheckedException;
  import org.apache.ignite.internal.util.F0;
 -import org.apache.ignite.internal.util.GridConcurrentHashSet;
  import org.apache.ignite.internal.util.GridLeanSet;
  import org.apache.ignite.internal.util.future.GridCompoundFuture;
  import org.apache.ignite.internal.util.future.GridFutureAdapter;

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/colocated/GridDhtColocatedCache.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearOptimisticTxPrepareFuture.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearOptimisticTxPrepareFuture.java
index fd1453b,af43113..0002180
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearOptimisticTxPrepareFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearOptimisticTxPrepareFuture.java
@@@ -17,11 -17,8 +17,10 @@@
  
  package org.apache.ignite.internal.processors.cache.distributed.near;
  
 +import java.util.ArrayDeque;
  import java.util.Collection;
- import java.util.Collections;
  import java.util.List;
 +import java.util.Queue;
  import java.util.UUID;
  import java.util.concurrent.atomic.AtomicBoolean;
  import org.apache.ignite.IgniteCheckedException;
@@@ -59,9 -53,9 +55,8 @@@ import org.apache.ignite.internal.util.
  import org.apache.ignite.internal.util.typedef.internal.U;
  import org.apache.ignite.lang.IgniteClosure;
  import org.apache.ignite.lang.IgniteUuid;
- import org.apache.ignite.transactions.TransactionOptimisticException;
  import org.apache.ignite.transactions.TransactionTimeoutException;
  import org.jetbrains.annotations.Nullable;
 -import org.jsr166.ConcurrentLinkedDeque8;
  
  import static org.apache.ignite.internal.processors.cache.GridCacheOperation.TRANSFORM;
  import static org.apache.ignite.transactions.TransactionState.PREPARED;
@@@ -483,9 -293,9 +294,9 @@@ public class GridNearOptimisticTxPrepar
  
          txMapping = new GridDhtTxMapping();
  
 -        ConcurrentLinkedDeque8<GridDistributedTxMapping> mappings = new ConcurrentLinkedDeque8<>();
 +        Queue<GridDistributedTxMapping> mappings = new ArrayDeque<>();
  
-         if (!F.isEmpty(reads) || !F.isEmpty(writes)) {
+         if (!F.isEmpty(writes)) {
              for (int cacheId : tx.activeCacheIds()) {
                  GridCacheContext<?, ?> cacheCtx = cctx.cacheContext(cacheId);
  

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearTransactionalCache.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearTxFinishFuture.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearTxFinishFuture.java
index c7cc3ae,46c9f3e..a9dbda2
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearTxFinishFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearTxFinishFuture.java
@@@ -246,59 -265,44 +246,61 @@@ public final class GridNearTxFinishFutu
                  }
              }
  
 +            if (initialized() || err != null) {
 +                if (tx.needCheckBackup()) {
 +                    assert tx.onePhaseCommit();
 +
 +                    if (err != null)
 +                        err = new TransactionRollbackException("Failed to commit transaction.",
err);
 +
 +                    try {
 +                        tx.finish(err == null);
 +                    }
 +                    catch (IgniteCheckedException e) {
 +                        if (err != null)
 +                            err.addSuppressed(e);
 +                        else
 +                            err = e;
 +                    }
 +                }
 +
-                 if (tx.onePhaseCommit()) {
-                     finishOnePhase();
+             if (tx.onePhaseCommit()) {
+                 boolean commit = this.commit && err == null;
  
-                     tx.tmFinish(commit && err == null);
-                 }
+                 finishOnePhase(commit);
+ 
+                 tx.tmFinish(commit);
+             }
  
 -            Throwable th = this.err.get();
 +                if (super.onDone(tx0, err)) {
 +                    if (error() instanceof IgniteTxHeuristicCheckedException) {
 +                        AffinityTopologyVersion topVer = tx.topologyVersion();
  
 -            if (super.onDone(tx0, th != null ? th : err)) {
 -                if (error() instanceof IgniteTxHeuristicCheckedException) {
 -                    AffinityTopologyVersion topVer = tx.topologyVersion();
 +                        for (IgniteTxEntry e : tx.writeMap().values()) {
 +                            GridCacheContext cacheCtx = e.context();
  
 -                    for (IgniteTxEntry e : tx.writeMap().values()) {
 -                        GridCacheContext cacheCtx = e.context();
 -
 -                        try {
 -                            if (e.op() != NOOP && !cacheCtx.affinity().localNode(e.key(),
topVer)) {
 -                                GridCacheEntryEx entry = cacheCtx.cache().peekEx(e.key());
 +                            try {
 +                                if (e.op() != NOOP && !cacheCtx.affinity().localNode(e.key(),
topVer)) {
 +                                    GridCacheEntryEx entry = cacheCtx.cache().peekEx(e.key());
  
 -                                if (entry != null)
 -                                    entry.invalidate(null, tx.xidVersion());
 +                                    if (entry != null)
 +                                        entry.invalidate(null, tx.xidVersion());
 +                                }
                              }
 -                        }
 -                        catch (Throwable t) {
 -                            U.error(log, "Failed to invalidate entry.", t);
 +                            catch (Throwable t) {
 +                                U.error(log, "Failed to invalidate entry.", t);
  
 -                            if (t instanceof Error)
 -                                throw (Error)t;
 +                                if (t instanceof Error)
 +                                    throw (Error)t;
 +                            }
                          }
                      }
 -                }
  
 -                // Don't forget to clean up.
 -                cctx.mvcc().removeFuture(this);
 +                    // Don't forget to clean up.
 +                    cctx.mvcc().removeFuture(this);
  
 -                return true;
 +                    return true;
 +                }
              }
          }
  
@@@ -508,16 -512,9 +510,16 @@@
      }
  
      /**
-      *
+      * @param commit Commit flag.
       */
-     private void finishOnePhase() {
+     private void finishOnePhase(boolean commit) {
 +        assert Thread.holdsLock(this);
 +
 +        if (finishOnePhaseCalled)
 +            return;
 +
 +        finishOnePhaseCalled = true;
 +
          // No need to send messages as transaction was already committed on remote node.
          // Finish local mapping only as we need send commit message to backups.
          for (GridDistributedTxMapping m : mappings.values()) {

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearTxLocal.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxAdapter.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxHandler.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxLocalAdapter.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxManager.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxManager.java
index d97e648,c1e9202..05129bb
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxManager.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxManager.java
@@@ -24,8 -23,8 +24,7 @@@ import java.util.Collections
  import java.util.HashSet;
  import java.util.Iterator;
  import java.util.LinkedHashSet;
 -import java.util.LinkedList;
  import java.util.Map;
- import java.util.Queue;
  import java.util.Set;
  import java.util.UUID;
  import java.util.concurrent.ConcurrentMap;
@@@ -134,29 -127,9 +132,19 @@@ public class IgniteTxManager extends Gr
      /** TX handler. */
      private IgniteTxHandler txHandler;
  
-     /** All transactions. */
-     private final Queue<IgniteInternalTx> committedQ = new ConcurrentLinkedDeque8<>();
- 
-     /** Preparing transactions. */
-     private final Queue<IgniteInternalTx> prepareQ = new ConcurrentLinkedDeque8<>();
- 
-     /** Minimum start version. */
-     private final ConcurrentNavigableMap<GridCacheVersion, AtomicInt> startVerCnts
=
-         new ConcurrentSkipListMap<>();
- 
      /** Committed local transactions. */
 -    private final GridBoundedConcurrentOrderedMap<GridCacheVersion, Boolean> completedVers
=
 -        new GridBoundedConcurrentOrderedMap<>(Integer.getInteger(IGNITE_MAX_COMPLETED_TX_COUNT,
DFLT_MAX_COMPLETED_TX_CNT));
 +    private final GridBoundedConcurrentOrderedMap<GridCacheVersion, Boolean> completedVersSorted
=
 +        new GridBoundedConcurrentOrderedMap<>(
 +            Integer.getInteger(IGNITE_MAX_COMPLETED_TX_COUNT, DFLT_MAX_COMPLETED_TX_CNT));
 +
 +    /** Committed local transactions. */
 +    private final ConcurrentLinkedHashMap<GridCacheVersion, Boolean> completedVersHashMap
=
 +        new ConcurrentLinkedHashMap<>(
 +            Integer.getInteger(IGNITE_MAX_COMPLETED_TX_COUNT, DFLT_MAX_COMPLETED_TX_CNT),
 +            0.75f,
 +            Runtime.getRuntime().availableProcessors() * 2,
 +            Integer.getInteger(IGNITE_MAX_COMPLETED_TX_COUNT, DFLT_MAX_COMPLETED_TX_CNT),
 +            PER_SEGMENT_Q);
  
      /** Transaction finish synchronizer. */
      private GridCacheTxFinishSync txFinishSync;
@@@ -324,40 -297,8 +312,9 @@@
          X.println(">>> ");
          X.println(">>> Transaction manager memory stats [grid=" + cctx.gridName()
+ ']');
          X.println(">>>   threadMapSize: " + threadMap.size());
-         X.println(">>>   idMap [size=" + idMap.size() + ", minStartVer=" + minStartVer
+ ", dur=" + dur + "ms]");
-         X.println(">>>   committedQueue [size=" + committedSize +
-             ", firstStartVersion=" + (firstTx == null ? "null" : firstTx.startVersion())
+
-             ", firstEndVersion=" + (firstTx == null ? "null" : firstTx.endVersion()) + ']');
-         X.println(">>>   prepareQueueSize: " + prepareQ.size());
-         X.println(">>>   startVerCntsSize [size=" + startVerCnts.size() +
-             ", firstVer=" + startVerEntry + ']');
+         X.println(">>>   idMap [size=" + idMap.size() + ']');
 -        X.println(">>>   completedVersSize: " + completedVers.size());
 +        X.println(">>>   completedVersSortedSize: " + completedVersSorted.size());
 +        X.println(">>>   completedVersHashMapSize: " + completedVersHashMap.sizex());
      }
  
      /**

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAbstractFullApiSelfTest.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTestEntryEx.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/502223a8/modules/core/src/test/java/org/apache/ignite/testframework/junits/common/GridCommonAbstractTest.java
----------------------------------------------------------------------


Mime
View raw message