lucene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sha...@apache.org
Subject lucene-solr:branch_7x: SOLR-11702: Minor edits to log and exception messages
Date Thu, 15 Mar 2018 11:29:38 GMT
Repository: lucene-solr
Updated Branches:
  refs/heads/branch_7x 00bbe0cda -> 4b52a19f4


SOLR-11702: Minor edits to log and exception messages

(cherry picked from commit dab739a)


Project: http://git-wip-us.apache.org/repos/asf/lucene-solr/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucene-solr/commit/4b52a19f
Tree: http://git-wip-us.apache.org/repos/asf/lucene-solr/tree/4b52a19f
Diff: http://git-wip-us.apache.org/repos/asf/lucene-solr/diff/4b52a19f

Branch: refs/heads/branch_7x
Commit: 4b52a19f4adfed57c9265ebee85d4e03321f6dbb
Parents: 00bbe0c
Author: Shalin Shekhar Mangar <shalin@apache.org>
Authored: Thu Mar 15 16:58:59 2018 +0530
Committer: Shalin Shekhar Mangar <shalin@apache.org>
Committed: Thu Mar 15 16:59:29 2018 +0530

----------------------------------------------------------------------
 .../org/apache/solr/cloud/ZkShardTerms.java     | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/4b52a19f/solr/core/src/java/org/apache/solr/cloud/ZkShardTerms.java
----------------------------------------------------------------------
diff --git a/solr/core/src/java/org/apache/solr/cloud/ZkShardTerms.java b/solr/core/src/java/org/apache/solr/cloud/ZkShardTerms.java
index e6db14f..55d5ace 100644
--- a/solr/core/src/java/org/apache/solr/cloud/ZkShardTerms.java
+++ b/solr/core/src/java/org/apache/solr/cloud/ZkShardTerms.java
@@ -296,15 +296,15 @@ public class ZkShardTerms implements AutoCloseable{
     try {
       Stat stat = zkClient.setData(znodePath, znodeData, newTerms.version, true);
       setNewTerms(new Terms(newTerms.values, stat.getVersion()));
-      log.info("Successful update terms at {} to {}", znodePath, newTerms);
+      log.info("Successful update of terms at {} to {}", znodePath, newTerms);
       return true;
     } catch (KeeperException.BadVersionException e) {
-      log.info("Failed to save terms, version is not match, retrying");
+      log.info("Failed to save terms, version is not a match, retrying");
       refreshTerms();
     } catch (KeeperException.NoNodeException e) {
       throw e;
     } catch (Exception e) {
-      throw new SolrException(SolrException.ErrorCode.SERVER_ERROR, "Error save shard term
for collection:" + collection, e);
+      throw new SolrException(SolrException.ErrorCode.SERVER_ERROR, "Error while saving shard
term for collection: " + collection, e);
     }
     return false;
   }
@@ -333,9 +333,9 @@ public class ZkShardTerms implements AutoCloseable{
       }
     }  catch (InterruptedException e) {
       Thread.interrupted();
-      throw new SolrException(SolrException.ErrorCode.SERVER_ERROR, "Error creating shard
term node in Zookeeper for collection:" + collection, e);
+      throw new SolrException(SolrException.ErrorCode.SERVER_ERROR, "Error creating shard
term node in Zookeeper for collection: " + collection, e);
     } catch (KeeperException e) {
-      throw new SolrException(SolrException.ErrorCode.SERVER_ERROR, "Error creating shard
term node in Zookeeper for collection:" + collection, e);
+      throw new SolrException(SolrException.ErrorCode.SERVER_ERROR, "Error creating shard
term node in Zookeeper for collection: " + collection, e);
     }
   }
 
@@ -350,9 +350,9 @@ public class ZkShardTerms implements AutoCloseable{
       newTerms = new Terms((Map<String, Long>) Utils.fromJSON(data), stat.getVersion());
     } catch (KeeperException e) {
       Thread.interrupted();
-      throw new SolrException(SolrException.ErrorCode.SERVER_ERROR, "Error updating shard
term for collection:" + collection, e);
+      throw new SolrException(SolrException.ErrorCode.SERVER_ERROR, "Error updating shard
term for collection: " + collection, e);
     } catch (InterruptedException e) {
-      throw new SolrException(SolrException.ErrorCode.SERVER_ERROR, "Error updating shard
term for collection:" + collection, e);
+      throw new SolrException(SolrException.ErrorCode.SERVER_ERROR, "Error updating shard
term for collection: " + collection, e);
     }
 
     setNewTerms(newTerms);
@@ -371,12 +371,12 @@ public class ZkShardTerms implements AutoCloseable{
         log.error("Failed watching shard term for collection: {} due to unrecoverable exception",
collection, e);
         return;
       } catch (KeeperException e) {
-        log.warn("Failed watching shard term for collection:{}, retrying!", collection, e);
+        log.warn("Failed watching shard term for collection: {}, retrying!", collection,
e);
         try {
           zkClient.getConnectionManager().waitForConnected(zkClient.getZkClientTimeout());
         } catch (TimeoutException te) {
           if (Thread.interrupted()) {
-            throw new SolrException(SolrException.ErrorCode.SERVER_ERROR, "Error watching
shard term for collection:" + collection, te);
+            throw new SolrException(SolrException.ErrorCode.SERVER_ERROR, "Error watching
shard term for collection: " + collection, te);
           }
         }
       }
@@ -401,7 +401,7 @@ public class ZkShardTerms implements AutoCloseable{
       zkClient.exists(znodePath, watcher, true);
     } catch (InterruptedException e) {
       Thread.interrupted();
-      throw new SolrException(SolrException.ErrorCode.SERVER_ERROR, "Error watching shard
term for collection:" + collection, e);
+      throw new SolrException(SolrException.ErrorCode.SERVER_ERROR, "Error watching shard
term for collection: " + collection, e);
     }
   }
 


Mime
View raw message