ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject [23/25] incubator-ignite git commit: Merge branch 'ignite-sprint-3' into ignite-598
Date Tue, 31 Mar 2015 15:39:11 GMT
Merge branch 'ignite-sprint-3' into ignite-598

Conflicts:
	modules/core/src/main/java/org/apache/ignite/internal/GridKernalContextImpl.java
	modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheContext.java
	modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProcessor.java
	modules/core/src/test/java/org/apache/ignite/loadtests/hashmap/GridCacheTestContext.java


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

Branch: refs/heads/ignite-598
Commit: c7c3926146d2914d03b3b63289deee4807f3f50c
Parents: d42ce81 c302175
Author: Artem Shutak <ashutak@gridgain.com>
Authored: Tue Mar 31 17:16:24 2015 +0300
Committer: Artem Shutak <ashutak@gridgain.com>
Committed: Tue Mar 31 17:16:24 2015 +0300

----------------------------------------------------------------------
 .../ignite/internal/GridKernalContextImpl.java  |   3 +
 .../cache/CacheConflictResolutionManager.java   |  30 +++++
 .../cache/CacheOsConflictResolutionManager.java |  58 ++++++++++
 .../processors/cache/GridCacheContext.java      |  18 +--
 .../processors/cache/GridCacheProcessor.java    |  14 ++-
 .../processors/cache/dr/GridCacheDrManager.java |   5 -
 .../cache/dr/GridOsCacheDrManager.java          | 106 ++++++++++++++++++
 .../cache/dr/os/GridOsCacheDrManager.java       | 111 -------------------
 .../transactions/IgniteTxLocalAdapter.java      |  13 ++-
 .../version/CacheVersionConflictResolver.java   |  40 +++++++
 ...ridCacheVersionAbstractConflictResolver.java |  56 ----------
 .../GridCacheVersionConflictResolver.java       |  59 ----------
 .../loadtests/hashmap/GridCacheTestContext.java |   6 +-
 .../IgniteCacheFailoverTestSuite.java           |   8 +-
 14 files changed, 272 insertions(+), 255 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/c7c39261/modules/core/src/main/java/org/apache/ignite/internal/GridKernalContextImpl.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/GridKernalContextImpl.java
index a3e3971,3bee762..d81d756
--- a/modules/core/src/main/java/org/apache/ignite/internal/GridKernalContextImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/GridKernalContextImpl.java
@@@ -785,8 -786,12 +786,10 @@@ public class GridKernalContextImpl impl
          if (res != null)
              return res;
  
 -        if (cls.equals(GridCacheDrManager.class))
 -            return (T)new GridOsCacheDrManager();
 -        else if (cls.equals(IgniteCacheObjectProcessor.class))
 +        if (cls.equals(IgniteCacheObjectProcessor.class))
              return (T)new IgniteCacheObjectProcessorImpl(this);
+         else if (cls.equals(CacheConflictResolutionManager.class))
+             return (T)new CacheOsConflictResolutionManager<>();
  
          throw new IgniteException("Unsupported component type: " + cls);
      }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/c7c39261/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheContext.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheContext.java
index 84321bd,434d9e0..7a5e7bf
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheContext.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheContext.java
@@@ -136,9 -135,9 +136,12 @@@ public class GridCacheContext<K, V> imp
      /** JTA manager. */
      private CacheJtaManagerAdapter jtaMgr;
  
+     /** Conflict resolver manager. */
+     private CacheConflictResolutionManager rslvrMgr;
+ 
 +    /** Cache plugin manager. */
 +    private CachePluginManager pluginMgr;
 +
      /** Managers. */
      private List<GridCacheManager<K, V>> mgrs = new LinkedList<>();
  
@@@ -249,8 -247,8 +252,9 @@@
          GridCacheTtlManager ttlMgr,
          GridCacheDrManager drMgr,
          CacheJtaManagerAdapter jtaMgr,
 -        CacheConflictResolutionManager<K, V> rslvrMgr
++        CacheConflictResolutionManager<K, V> rslvrMgr,
 +        CachePluginManager pluginMgr
-         ) {
+     ) {
          assert ctx != null;
          assert sharedCtx != null;
          assert cacheCfg != null;
@@@ -264,7 -262,7 +268,8 @@@
          assert affMgr != null;
          assert dataStructuresMgr != null;
          assert ttlMgr != null;
+         assert rslvrMgr != null;
 +        assert pluginMgr != null;
  
          this.ctx = ctx;
          this.sharedCtx = sharedCtx;
@@@ -286,7 -284,7 +291,8 @@@
          this.ttlMgr = add(ttlMgr);
          this.drMgr = add(drMgr);
          this.jtaMgr = add(jtaMgr);
+         this.rslvrMgr = add(rslvrMgr);
 +        this.pluginMgr = add(pluginMgr);
  
          log = ctx.log(getClass());
  

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/c7c39261/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProcessor.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProcessor.java
index 16537c6,a04746a..e997ba8
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProcessor.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProcessor.java
@@@ -1014,11 -1013,8 +1014,13 @@@ public class GridCacheProcessor extend
          CacheContinuousQueryManager contQryMgr = new CacheContinuousQueryManager();
          CacheDataStructuresManager dataStructuresMgr = new CacheDataStructuresManager();
          GridCacheTtlManager ttlMgr = new GridCacheTtlManager();
 -        GridCacheDrManager drMgr = ctx.createComponent(GridCacheDrManager.class);
 +        CachePluginManager pluginMgr = new CachePluginManager(ctx, cfg);
 +        
 +        pluginMgr.validate();
-         
++
++        //TODO: move creation at pluginMgr.
+         CacheConflictResolutionManager rslvrMgr = ctx.createComponent(CacheConflictResolutionManager.class);
 +        GridCacheDrManager drMgr = pluginMgr.createComponent(GridCacheDrManager.class);
  
          GridCacheStoreManager storeMgr = new GridCacheStoreManager(ctx, sesHolders, cfgStore,
cfg);
  
@@@ -1043,7 -1039,8 +1045,9 @@@
              ttlMgr,
              drMgr,
              jta,
-             pluginMgr);
 -            rslvrMgr
++            rslvrMgr,
++            pluginMgr
+         );
  
          cacheCtx.cacheObjectContext(cacheObjCtx);
  
@@@ -1168,8 -1164,9 +1172,10 @@@
                  dataStructuresMgr,
                  ttlMgr,
                  drMgr,
-                 jta, 
-                 pluginMgr);
+                 jta,
 -                rslvrMgr
++                rslvrMgr,
++                pluginMgr
+             );
  
              cacheCtx.cacheObjectContext(cacheObjCtx);
  

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/c7c39261/modules/core/src/test/java/org/apache/ignite/loadtests/hashmap/GridCacheTestContext.java
----------------------------------------------------------------------
diff --cc modules/core/src/test/java/org/apache/ignite/loadtests/hashmap/GridCacheTestContext.java
index 39301d6,90b6b1f..e9d390c
--- a/modules/core/src/test/java/org/apache/ignite/loadtests/hashmap/GridCacheTestContext.java
+++ b/modules/core/src/test/java/org/apache/ignite/loadtests/hashmap/GridCacheTestContext.java
@@@ -71,6 -70,7 +71,8 @@@ public class GridCacheTestContext<K, V
              new GridCacheTtlManager(),
              new GridOsCacheDrManager(),
              new CacheNoopJtaManager(),
-             new CachePluginManager(ctx, new CacheConfiguration()));
 -            new CacheOsConflictResolutionManager<K, V>()
++            new CacheOsConflictResolutionManager<K, V>(),
++            new CachePluginManager(ctx, new CacheConfiguration()))
+         );
      }
  }


Mime
View raw message