geode-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jasonhu...@apache.org
Subject geode git commit: GEODE-2679: Lucene asynchronous disk writes for aeq can lead to data mismatch after compacting
Date Mon, 20 Mar 2017 18:46:25 GMT
Repository: geode
Updated Branches:
  refs/heads/develop 84a1a9bf7 -> 17877689b


GEODE-2679: Lucene asynchronous disk writes for aeq can lead to data mismatch after compacting

* forcing disk sync = true for Lucene AEQ


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

Branch: refs/heads/develop
Commit: 17877689beee29671c143baba7c3d65e917205fe
Parents: 84a1a9b
Author: Jason Huynh <huynhja@gmail.com>
Authored: Fri Mar 17 16:36:16 2017 -0700
Committer: Jason Huynh <huynhja@gmail.com>
Committed: Mon Mar 20 11:15:32 2017 -0700

----------------------------------------------------------------------
 .../org/apache/geode/cache/lucene/internal/LuceneIndexImpl.java  | 2 +-
 .../lucene/LuceneIndexCreationPersistenceIntegrationTest.java    | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/geode/blob/17877689/geode-lucene/src/main/java/org/apache/geode/cache/lucene/internal/LuceneIndexImpl.java
----------------------------------------------------------------------
diff --git a/geode-lucene/src/main/java/org/apache/geode/cache/lucene/internal/LuceneIndexImpl.java
b/geode-lucene/src/main/java/org/apache/geode/cache/lucene/internal/LuceneIndexImpl.java
index 66dc1f9..93fb25b 100644
--- a/geode-lucene/src/main/java/org/apache/geode/cache/lucene/internal/LuceneIndexImpl.java
+++ b/geode-lucene/src/main/java/org/apache/geode/cache/lucene/internal/LuceneIndexImpl.java
@@ -170,7 +170,7 @@ public abstract class LuceneIndexImpl implements InternalLuceneIndex {
       factory.setPersistent(true);
     }
     factory.setDiskStoreName(dataRegion.getAttributes().getDiskStoreName());
-    factory.setDiskSynchronous(dataRegion.getAttributes().isDiskSynchronous());
+    factory.setDiskSynchronous(true);
     factory.setForwardExpirationDestroy(true);
     return factory;
   }

http://git-wip-us.apache.org/repos/asf/geode/blob/17877689/geode-lucene/src/test/java/org/apache/geode/cache/lucene/LuceneIndexCreationPersistenceIntegrationTest.java
----------------------------------------------------------------------
diff --git a/geode-lucene/src/test/java/org/apache/geode/cache/lucene/LuceneIndexCreationPersistenceIntegrationTest.java
b/geode-lucene/src/test/java/org/apache/geode/cache/lucene/LuceneIndexCreationPersistenceIntegrationTest.java
index 8f65574..bed6f13 100644
--- a/geode-lucene/src/test/java/org/apache/geode/cache/lucene/LuceneIndexCreationPersistenceIntegrationTest.java
+++ b/geode-lucene/src/test/java/org/apache/geode/cache/lucene/LuceneIndexCreationPersistenceIntegrationTest.java
@@ -112,7 +112,7 @@ public class LuceneIndexCreationPersistenceIntegrationTest extends LuceneIntegra
 
   @Test
   @Parameters({"true", "false"})
-  public void shouldUseDiskSynchronousWhenUserRegionHasDiskSynchronous(boolean synchronous)
{
+  public void aeqShouldAlwaysBeDiskSynchronousWhenUserRegionIsEither(boolean synchronous)
{
     createIndex(cache, "text");
     cache.createRegionFactory(RegionShortcut.PARTITION_PERSISTENT).setDiskSynchronous(synchronous)
         .create(REGION_NAME);
@@ -122,7 +122,7 @@ public class LuceneIndexCreationPersistenceIntegrationTest extends LuceneIntegra
       assertTrue(region.isDiskSynchronous());
     });
     AsyncEventQueue queue = getIndexQueue(cache);
-    assertEquals(synchronous, queue.isDiskSynchronous());
+    assertTrue(queue.isDiskSynchronous());
     assertEquals(true, queue.isPersistent());
   }
 


Mime
View raw message