geode-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From zho...@apache.org
Subject [geode] branch feature/GEODE-3569 updated: GEODE-3569: set default class name
Date Fri, 15 Sep 2017 23:13:23 GMT
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/feature/GEODE-3569 by this push:
     new b28e565  GEODE-3569: set default class name
b28e565 is described below

commit b28e5653ec68945b0bf30eed613ed11191478e9e
Author: zhouxh <gzhou@pivotal.io>
AuthorDate: Fri Sep 15 16:12:54 2017 -0700

    GEODE-3569: set default class name
---
 .../java/org/apache/geode/internal/i18n/LocalizedStrings.java    | 2 +-
 .../geode/cache/lucene/internal/LuceneIndexCreationProfile.java  | 9 ++++-----
 .../org/apache/geode/cache/lucene/test/LuceneTestUtilities.java  | 4 +---
 3 files changed, 6 insertions(+), 9 deletions(-)

diff --git a/geode-core/src/main/java/org/apache/geode/internal/i18n/LocalizedStrings.java
b/geode-core/src/main/java/org/apache/geode/internal/i18n/LocalizedStrings.java
index 777797b..ab3b8eb 100755
--- a/geode-core/src/main/java/org/apache/geode/internal/i18n/LocalizedStrings.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/i18n/LocalizedStrings.java
@@ -7613,7 +7613,7 @@ public class LocalizedStrings {
           "Cannot create Lucene index {0} on region {1} with analyzer {2} on field {3} because
another member defines the same index with analyzer {4} on that field.");
   public static final StringId LuceneService_CANNOT_CREATE_INDEX_0_ON_REGION_1_WITH_SERIALIZER_2_BECAUSE_ANOTHER_MEMBER_DEFINES_THE_SAME_INDEX_WITH_DIFFERENT_SERIALIZER_3
=
       new StringId(6632,
-          "Cannot create Lucene index {0} on region {1} with Serializer {2} because another
member defines the same index with different serializer {3}.");
+          "Cannot create Lucene index {0} on region {1} with serializer {2} because another
member defines the same index with different serializer {3}.");
 
   public static final StringId AbstractDistributionConfig_CLUSTER_SSL_ALIAS_0 = new StringId(6633,
       "SSL communication uses the this alias when determining the key to use from the keystore
for SSL. Defaults to \"{0}\".");
diff --git a/geode-lucene/src/main/java/org/apache/geode/cache/lucene/internal/LuceneIndexCreationProfile.java
b/geode-lucene/src/main/java/org/apache/geode/cache/lucene/internal/LuceneIndexCreationProfile.java
index c42e2a0..7ec3f46 100644
--- a/geode-lucene/src/main/java/org/apache/geode/cache/lucene/internal/LuceneIndexCreationProfile.java
+++ b/geode-lucene/src/main/java/org/apache/geode/cache/lucene/internal/LuceneIndexCreationProfile.java
@@ -38,12 +38,13 @@ public class LuceneIndexCreationProfile implements CacheServiceProfile,
DataSeri
 
   private Map<String, String> fieldAnalyzers;
 
-  private String serializerClass;
+  private String serializerClass = HeterogeneousLuceneSerializer.class.getSimpleName();
 
   private String regionPath;
 
   /* Used by DataSerializer */
-  public LuceneIndexCreationProfile() {}
+  public LuceneIndexCreationProfile() {
+  }
 
   public LuceneIndexCreationProfile(String indexName, String regionPath, String[] fieldNames,
       Analyzer analyzer, Map<String, Analyzer> fieldAnalyzers, LuceneSerializer serializer)
{
@@ -52,9 +53,7 @@ public class LuceneIndexCreationProfile implements CacheServiceProfile,
DataSeri
     this.fieldNames = fieldNames;
     this.analyzerClass = analyzer.getClass().getSimpleName();
     initializeFieldAnalyzers(fieldAnalyzers);
-    if (serializer == null) {
-      this.serializerClass = HeterogeneousLuceneSerializer.class.getSimpleName();
-    } else {
+    if (serializer != null) {
       this.serializerClass = serializer.getClass().getSimpleName();
     }
   }
diff --git a/geode-lucene/src/test/java/org/apache/geode/cache/lucene/test/LuceneTestUtilities.java
b/geode-lucene/src/test/java/org/apache/geode/cache/lucene/test/LuceneTestUtilities.java
index 3d9e9a6..307b649 100644
--- a/geode-lucene/src/test/java/org/apache/geode/cache/lucene/test/LuceneTestUtilities.java
+++ b/geode-lucene/src/test/java/org/apache/geode/cache/lucene/test/LuceneTestUtilities.java
@@ -80,9 +80,7 @@ public class LuceneTestUtilities {
   public static final String CANNOT_CREATE_LUCENE_INDEX_DIFFERENT_INDEXES_3 =
       "Cannot create Lucene index index on region /region because it is not defined in another
member.";
   public static final String CANNOT_CREATE_LUCENE_INDEX_DIFFERENT_SERIALIZER =
-      "Cannot create Lucene index index on region /region with Serializer DummyLuceneSerializer
because another member defines the same index with different serializer HeterogeneousLuceneSerializer.";
-  public static final String SERIALIZER_MATCHED =
-      "Serializer matched when creating Lucene index index on region /region.";
+      "Cannot create Lucene index index on region /region with serializer DummyLuceneSerializer
because another member defines the same index with different serializer HeterogeneousLuceneSerializer.";
 
   public static String Quarter1 = "Q1";
   public static String Quarter2 = "Q2";

-- 
To stop receiving notification emails like this one, please contact
['"commits@geode.apache.org" <commits@geode.apache.org>'].

Mime
View raw message