Yingyi Bu has submitted this change and it was merged.

Change subject: cleanup error message
......................................................................


cleanup error message

Change-Id: I38e7ae7ae0f55d0bb3bbc46ee5a1e7f604d66c66
Reviewed-on: https://asterix-gerrit.ics.uci.edu/1286
Sonar-Qube: Jenkins <jenk...@fulliautomatix.ics.uci.edu>
Tested-by: Jenkins <jenk...@fulliautomatix.ics.uci.edu>
Integration-Tests: Jenkins <jenk...@fulliautomatix.ics.uci.edu>
Reviewed-by: Yingyi Bu <buyin...@gmail.com>
---
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/AbstractLangTranslator.java
1 file changed, 4 insertions(+), 5 deletions(-)

Approvals:
  Yingyi Bu: Looks good to me, approved
  Jenkins: Verified; No violations found; Verified



diff --git 
a/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/AbstractLangTranslator.java
 
b/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/AbstractLangTranslator.java
index 9f2d5d8..1abf6c8 100644
--- 
a/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/AbstractLangTranslator.java
+++ 
b/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/AbstractLangTranslator.java
@@ -65,7 +65,7 @@
                 }
             }
             if 
(!ClusterStateManager.INSTANCE.getState().equals(ClusterState.ACTIVE)) {
-                throw new AsterixException(" Asterix Cluster is in " + 
ClusterState.UNUSABLE + " state."
+                throw new AsterixException("Cluster is in " + 
ClusterState.UNUSABLE + " state."
                         + "\n One or more Node Controllers have left or 
haven't joined yet.\n");
             } else {
                 if (LOGGER.isLoggable(Level.INFO)) {
@@ -75,7 +75,7 @@
         }
 
         if 
(ClusterStateManager.INSTANCE.getState().equals(ClusterState.UNUSABLE)) {
-            throw new AsterixException(" Asterix Cluster is in " + 
ClusterState.UNUSABLE + " state."
+            throw new AsterixException("Cluster is in " + 
ClusterState.UNUSABLE + " state."
                     + "\n One or more Node Controllers have left.\n");
         }
 
@@ -83,8 +83,7 @@
             int maxWaitCycles = 
AsterixAppContextInfo.INSTANCE.getExternalProperties().getMaxWaitClusterActive();
             int waitCycleCount = 0;
             try {
-                while 
(!ClusterStateManager.INSTANCE.isGlobalRecoveryCompleted()
-                        && waitCycleCount < maxWaitCycles) {
+                while 
(!ClusterStateManager.INSTANCE.isGlobalRecoveryCompleted() && waitCycleCount < 
maxWaitCycles) {
                     Thread.sleep(1000);
                     waitCycleCount++;
                 }
@@ -94,7 +93,7 @@
                 }
             }
             if (!ClusterStateManager.INSTANCE.isGlobalRecoveryCompleted()) {
-                throw new AsterixException(" Asterix Cluster Global recovery 
is not yet complete and The system is in "
+                throw new AsterixException("Cluster Global recovery is not yet 
complete and the system is in "
                         + ClusterState.ACTIVE + " state");
             }
         }

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1286
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I38e7ae7ae0f55d0bb3bbc46ee5a1e7f604d66c66
Gerrit-PatchSet: 2
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Till Westmann <ti...@apache.org>
Gerrit-Reviewer: Jenkins <jenk...@fulliautomatix.ics.uci.edu>
Gerrit-Reviewer: Yingyi Bu <buyin...@gmail.com>
Gerrit-Reviewer: abdullah alamoudi <bamou...@gmail.com>

Reply via email to