Added initialization of 'storeKeepBinary' flag for cache configurations received on discovery.
Project: http://git-wip-us.apache.org/repos/asf/ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/abe44f90 Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/abe44f90 Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/abe44f90 Branch: refs/heads/ignite-2324 Commit: abe44f901722508de29abbf82bc5f3444e365290 Parents: d2f84d1 Author: sboikov <[email protected]> Authored: Thu Jan 21 12:20:04 2016 +0300 Committer: sboikov <[email protected]> Committed: Thu Jan 21 12:20:04 2016 +0300 ---------------------------------------------------------------------- .../processors/cache/GridCacheProcessor.java | 23 +++++++++++++++----- 1 file changed, 17 insertions(+), 6 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/ignite/blob/abe44f90/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProcessor.java ---------------------------------------------------------------------- diff --git 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 index 7e165e0..13048ec 100644 --- 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 @@ -1899,12 +1899,7 @@ public class GridCacheProcessor extends GridProcessorAdapter { } else { for (DynamicCacheChangeRequest req : batch.requests()) { - if (req.startCacheConfiguration() != null) { - CacheConfiguration ccfg = req.startCacheConfiguration(); - - if (ccfg.isStoreKeepBinary() == null) - ccfg.setStoreKeepBinary(CacheConfiguration.DFLT_STORE_KEEP_BINARY); - } + initReceivedCacheConfiguration(req); if (req.template()) { CacheConfiguration ccfg = req.startCacheConfiguration(); @@ -1997,6 +1992,8 @@ public class GridCacheProcessor extends GridProcessorAdapter { for (DynamicCacheChangeRequest req : batch.requests()) { assert !req.template() : req; + initReceivedCacheConfiguration(req); + String name = req.cacheName(); boolean sysCache = CU.isMarshallerCache(name) || CU.isUtilityCache(name) || CU.isAtomicsCache(name); @@ -2445,6 +2442,8 @@ public class GridCacheProcessor extends GridProcessorAdapter { boolean incMinorTopVer = false; for (DynamicCacheChangeRequest req : batch.requests()) { + initReceivedCacheConfiguration(req); + if (req.template()) { CacheConfiguration ccfg = req.startCacheConfiguration(); @@ -2589,6 +2588,18 @@ public class GridCacheProcessor extends GridProcessorAdapter { } /** + * @param req Cache change request. + */ + private void initReceivedCacheConfiguration(DynamicCacheChangeRequest req) { + if (req.startCacheConfiguration() != null) { + CacheConfiguration ccfg = req.startCacheConfiguration(); + + if (ccfg.isStoreKeepBinary() == null) + ccfg.setStoreKeepBinary(CacheConfiguration.DFLT_STORE_KEEP_BINARY); + } + } + + /** * Checks that preload-order-dependant caches has SYNC or ASYNC preloading mode. * * @param cfgs Caches.
