Repository: ignite
Updated Branches:
  refs/heads/ignite-2.4 2eec607b3 -> b7cc1d745


http://git-wip-us.apache.org/repos/asf/ignite/blob/b7cc1d74/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/wal/SingleSegmentLogicalRecordsIterator.java
----------------------------------------------------------------------
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/wal/SingleSegmentLogicalRecordsIterator.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/wal/SingleSegmentLogicalRecordsIterator.java
index 4a846b4..d5c10cf 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/wal/SingleSegmentLogicalRecordsIterator.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/wal/SingleSegmentLogicalRecordsIterator.java
@@ -25,8 +25,10 @@ import org.apache.ignite.internal.pagemem.wal.WALPointer;
 import org.apache.ignite.internal.pagemem.wal.record.MarshalledRecord;
 import org.apache.ignite.internal.pagemem.wal.record.WALRecord;
 import org.apache.ignite.internal.processors.cache.GridCacheSharedContext;
+import org.apache.ignite.internal.processors.cache.persistence.file.FileIO;
 import 
org.apache.ignite.internal.processors.cache.persistence.file.FileIOFactory;
 import 
org.apache.ignite.internal.processors.cache.persistence.wal.record.RecordTypes;
+import 
org.apache.ignite.internal.processors.cache.persistence.wal.serializer.RecordSerializer;
 import 
org.apache.ignite.internal.processors.cache.persistence.wal.serializer.RecordSerializerFactory;
 import 
org.apache.ignite.internal.processors.cache.persistence.wal.serializer.RecordSerializerFactoryImpl;
 import org.apache.ignite.internal.util.typedef.CIX1;
@@ -93,8 +95,8 @@ public class SingleSegmentLogicalRecordsIterator extends 
AbstractWalRecordsItera
     }
 
     /** {@inheritDoc} */
-    @Override protected FileWriteAheadLogManager.ReadFileHandle advanceSegment(
-        @Nullable FileWriteAheadLogManager.ReadFileHandle curWalSegment) 
throws IgniteCheckedException {
+    @Override protected AbstractReadFileHandle advanceSegment(
+        @Nullable AbstractReadFileHandle curWalSegment) throws 
IgniteCheckedException {
         if (segmentInitialized) {
             closeCurrentWalSegment();
             // No advance as we iterate over single segment.
@@ -123,6 +125,12 @@ public class SingleSegmentLogicalRecordsIterator extends 
AbstractWalRecordsItera
             advanceC.apply(curRec.get2());
     }
 
+    /** {@inheritDoc} */
+    @Override protected AbstractReadFileHandle createReadFileHandle(FileIO 
fileIO, long idx,
+        RecordSerializer ser, FileInput in) {
+        return new FileWriteAheadLogManager.ReadFileHandle(fileIO, idx, ser, 
in);
+    }
+
     /**
      *
      */

http://git-wip-us.apache.org/repos/asf/ignite/blob/b7cc1d74/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/wal/reader/StandaloneWalRecordsIterator.java
----------------------------------------------------------------------
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/wal/reader/StandaloneWalRecordsIterator.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/wal/reader/StandaloneWalRecordsIterator.java
index 7740f28..712517b 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/wal/reader/StandaloneWalRecordsIterator.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/wal/reader/StandaloneWalRecordsIterator.java
@@ -45,6 +45,7 @@ import 
org.apache.ignite.internal.processors.cache.persistence.wal.ByteBufferExp
 import org.apache.ignite.internal.processors.cache.persistence.wal.FileInput;
 import 
org.apache.ignite.internal.processors.cache.persistence.wal.FileWALPointer;
 import 
org.apache.ignite.internal.processors.cache.persistence.wal.FileWriteAheadLogManager;
+import 
org.apache.ignite.internal.processors.cache.persistence.wal.serializer.RecordSerializer;
 import 
org.apache.ignite.internal.processors.cache.persistence.wal.serializer.RecordSerializerFactoryImpl;
 import 
org.apache.ignite.internal.processors.cache.persistence.wal.serializer.RecordV1Serializer;
 import 
org.apache.ignite.internal.processors.cacheobject.IgniteCacheObjectProcessor;
@@ -153,7 +154,7 @@ class StandaloneWalRecordsIterator extends 
AbstractWalRecordsIterator {
         final boolean workDir,
         @Nullable final File[] walFiles) throws IgniteCheckedException {
         if (walFilesDir != null) {
-            FileWriteAheadLogManager.FileDescriptor[] descs = 
loadFileDescriptors(walFilesDir);
+            FileWriteAheadLogManager.FileDescriptor[] descs = 
FileWriteAheadLogManager.loadFileDescriptors(walFilesDir);
             curWalSegmIdx = !F.isEmpty(descs) ? descs[0].getIdx() : 0;
             this.walFilesDir = walFilesDir;
         }
@@ -224,8 +225,8 @@ class StandaloneWalRecordsIterator extends 
AbstractWalRecordsIterator {
     }
 
     /** {@inheritDoc} */
-    @Override protected FileWriteAheadLogManager.ReadFileHandle advanceSegment(
-        @Nullable final FileWriteAheadLogManager.ReadFileHandle curWalSegment) 
throws IgniteCheckedException {
+    @Override protected AbstractReadFileHandle advanceSegment(
+        @Nullable final AbstractReadFileHandle curWalSegment) throws 
IgniteCheckedException {
 
         if (curWalSegment != null)
             curWalSegment.close();
@@ -380,4 +381,10 @@ class StandaloneWalRecordsIterator extends 
AbstractWalRecordsIterator {
 
         curWalSegmIdx = Integer.MAX_VALUE;
     }
+
+    /** {@inheritDoc} */
+    @Override protected AbstractReadFileHandle createReadFileHandle(FileIO 
fileIO, long idx,
+        RecordSerializer ser, FileInput in) {
+        return new FileWriteAheadLogManager.ReadFileHandle(fileIO, idx, ser, 
in);
+    }
 }

http://git-wip-us.apache.org/repos/asf/ignite/blob/b7cc1d74/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/IgniteWalFlushDefaultSelfTest.java
----------------------------------------------------------------------
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/IgniteWalFlushDefaultSelfTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/IgniteWalFlushDefaultSelfTest.java
index d60241e..94e7e25 100644
--- 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/IgniteWalFlushDefaultSelfTest.java
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/IgniteWalFlushDefaultSelfTest.java
@@ -30,6 +30,6 @@ public class IgniteWalFlushDefaultSelfTest extends 
IgniteWalFlushMultiNodeFailov
 
     /** {@inheritDoc} */
     @Override protected WALMode walMode() {
-        return WALMode.DEFAULT;
+        return WALMode.FSYNC;
     }
 }

http://git-wip-us.apache.org/repos/asf/ignite/blob/b7cc1d74/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/reader/IgniteWalReaderTest.java
----------------------------------------------------------------------
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/reader/IgniteWalReaderTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/reader/IgniteWalReaderTest.java
index 63c219b..58da0e2 100644
--- 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/reader/IgniteWalReaderTest.java
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/reader/IgniteWalReaderTest.java
@@ -731,7 +731,7 @@ public class IgniteWalReaderTest extends 
GridCommonAbstractTest {
      * @throws Exception if failed.
      */
     public void testFillWalForExactSegmentsCount() throws Exception {
-        customWalMode = WALMode.DEFAULT;
+        customWalMode = WALMode.FSYNC;
 
         final CountDownLatch reqSegments = new CountDownLatch(15);
         final Ignite ignite = startGrid("node0");
@@ -780,7 +780,7 @@ public class IgniteWalReaderTest extends 
GridCommonAbstractTest {
      * @throws Exception if failed.
      */
     public void testReadEmptyWal() throws Exception {
-        customWalMode = WALMode.DEFAULT;
+        customWalMode = WALMode.FSYNC;
 
         final Ignite ignite = startGrid("node0");
 

Reply via email to