ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject [16/26] ignite git commit: ignite-gg-12052 code comments
Date Wed, 28 Jun 2017 06:10:36 GMT
ignite-gg-12052 code comments


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

Branch: refs/heads/ignite-2.1.2-exchange
Commit: 1d88bec2da02b6343ee867e4fbc25b00e67c1fd6
Parents: 07bf0f6
Author: Dmitriy Govorukhin <dmitriy.govorukhin@gmail.com>
Authored: Tue Jun 27 16:13:30 2017 +0300
Committer: Dmitriy Govorukhin <dmitriy.govorukhin@gmail.com>
Committed: Tue Jun 27 16:13:30 2017 +0300

----------------------------------------------------------------------
 .../cache/persistence/GridCacheDatabaseSharedManager.java       | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/1d88bec2/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/GridCacheDatabaseSharedManager.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/GridCacheDatabaseSharedManager.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/GridCacheDatabaseSharedManager.java
index b9ff7e7..990f54c 100755
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/GridCacheDatabaseSharedManager.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/GridCacheDatabaseSharedManager.java
@@ -676,8 +676,10 @@ public class GridCacheDatabaseSharedManager extends IgniteCacheDatabaseSharedMan
                     ByteBuffer pageBuf,
                     Integer tag
                 ) throws IgniteCheckedException {
+                    // First of all, write page to disk.
                     storeMgr.write(fullId.cacheId(), fullId.pageId(), pageBuf, tag);
 
+                    // Only after write we can write page into snapshot.
                     snapshotMgr.flushDirtyPageHandler(fullId, pageBuf, tag);
                 }
             },
@@ -2381,7 +2383,8 @@ public class GridCacheDatabaseSharedManager extends IgniteCacheDatabaseSharedMan
 
                     PageMemoryEx pageMem = (PageMemoryEx)grp.memoryPolicy().pageMemory();
 
-                    Integer tag = pageMem.getForCheckpoint(fullId, tmpWriteBuf, persStoreMetrics.metricsEnabled()
? tracker : null);
+                    Integer tag = pageMem.getForCheckpoint(
+                        fullId, tmpWriteBuf, persStoreMetrics.metricsEnabled() ? tracker
: null);
 
                     if (tag != null) {
                         tmpWriteBuf.rewind();


Mime
View raw message