You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@geode.apache.org by ud...@apache.org on 2018/03/29 22:32:13 UTC

[geode] branch feature/GEODE-3926_3 updated: Cosmetic

This is an automated email from the ASF dual-hosted git repository.

udo pushed a commit to branch feature/GEODE-3926_3
in repository https://gitbox.apache.org/repos/asf/geode.git


The following commit(s) were added to refs/heads/feature/GEODE-3926_3 by this push:
     new 654d19f  Cosmetic
654d19f is described below

commit 654d19f413b5d513919eb19d0a0d13a54aacd96a
Author: Udo Kohlmeyer <uk...@pivotal.io>
AuthorDate: Thu Mar 29 15:32:04 2018 -0700

    Cosmetic
---
 .../internal/PartitionedRepositoryManager.java     | 29 +++++++++++-----------
 1 file changed, 15 insertions(+), 14 deletions(-)

diff --git a/geode-lucene/src/main/java/org/apache/geode/cache/lucene/internal/PartitionedRepositoryManager.java b/geode-lucene/src/main/java/org/apache/geode/cache/lucene/internal/PartitionedRepositoryManager.java
index 92b4c08..092b332 100755
--- a/geode-lucene/src/main/java/org/apache/geode/cache/lucene/internal/PartitionedRepositoryManager.java
+++ b/geode-lucene/src/main/java/org/apache/geode/cache/lucene/internal/PartitionedRepositoryManager.java
@@ -88,20 +88,21 @@ public class PartitionedRepositoryManager implements RepositoryManager {
         throw new BucketNotFoundException(
             "User bucket was not found for region " + region + "bucket id " + bucketId);
       } else {
-        if (index.isIndexAvailable(userBucket.getId())) {
-          repos.add(getRepository(userBucket.getId()));
-        } else {
-          waitingThreadPoolFromDM.execute(() -> {
-            try {
-              IndexRepository repository = getRepository(userBucket.getId());
-              repos.add(repository);
-            } catch (BucketNotFoundException e) {
-              logger.debug(
-                  "Lucene Index creation in progress. Catching BucketNotFoundException");
-            }
-          });
-          throw new LuceneIndexCreationInProgressException(
-              "Lucene Index creation in progress for bucket: " + userBucket.getId());
+        if (LuceneServiceImpl.LUCENE_REINDEX) {
+          if (index.isIndexAvailable(userBucket.getId())) {
+            repos.add(getRepository(userBucket.getId()));
+          } else {
+            waitingThreadPoolFromDM.execute(() -> {
+              try {
+                IndexRepository repository = getRepository(userBucket.getId());
+                repos.add(repository);
+              } catch (BucketNotFoundException e) {
+                logger.debug("Lucene Index creation in progress. Catching BucketNotFoundException");
+              }
+            });
+            throw new LuceneIndexCreationInProgressException(
+                "Lucene Index creation in progress for bucket: " + userBucket.getId());
+          }
         }
       }
     }

-- 
To stop receiving notification emails like this one, please contact
udo@apache.org.