You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@storm.apache.org by bo...@apache.org on 2018/10/03 18:17:56 UTC

[1/5] storm git commit: STORM-3240 health checks should succeed on exit code 0

Repository: storm
Updated Branches:
  refs/heads/master ad63cc20f -> fe3cfdf0a


STORM-3240 health checks should succeed on exit code 0


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

Branch: refs/heads/master
Commit: 39d28387296a57835947da45f4c5c1f92eb676e6
Parents: c367f9a
Author: Aaron Gresch <ag...@yahoo-inc.com>
Authored: Mon Oct 1 11:12:28 2018 -0500
Committer: Aaron Gresch <ag...@yahoo-inc.com>
Committed: Mon Oct 1 11:12:28 2018 -0500

----------------------------------------------------------------------
 .../main/java/org/apache/storm/healthcheck/HealthChecker.java    | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/storm/blob/39d28387/storm-server/src/main/java/org/apache/storm/healthcheck/HealthChecker.java
----------------------------------------------------------------------
diff --git a/storm-server/src/main/java/org/apache/storm/healthcheck/HealthChecker.java b/storm-server/src/main/java/org/apache/storm/healthcheck/HealthChecker.java
index 83faf13..5f877fc 100644
--- a/storm-server/src/main/java/org/apache/storm/healthcheck/HealthChecker.java
+++ b/storm-server/src/main/java/org/apache/storm/healthcheck/HealthChecker.java
@@ -106,13 +106,13 @@ public class HealthChecker {
                 BufferedReader reader = new BufferedReader(new InputStreamReader(stdin));
                 while ((str = reader.readLine()) != null) {
                     if (str.startsWith("ERROR")) {
+                        LOG.warn("The healthcheck process {} exited with code {}", script, process.exitValue());
                         return FAILED;
                     }
                 }
                 return SUCCESS;
             }
-            LOG.warn("The healthcheck process {} exited with code {}", script, process.exitValue());
-            return FAILED_WITH_EXIT_CODE;
+            return SUCCESS;
         } catch (InterruptedException | ClosedByInterruptException e) {
             LOG.warn("Script:  {} timed out.", script);
             return TIMEOUT;


[3/5] storm git commit: STORM-3240 swap failure codes to better much functionality

Posted by bo...@apache.org.
STORM-3240 swap failure codes to better much functionality


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

Branch: refs/heads/master
Commit: 9e84142c84ea4975d6b446c1aaea19e04daa120c
Parents: 7811fd0
Author: Aaron Gresch <ag...@yahoo-inc.com>
Authored: Tue Oct 2 15:16:40 2018 -0500
Committer: Aaron Gresch <ag...@yahoo-inc.com>
Committed: Tue Oct 2 15:16:40 2018 -0500

----------------------------------------------------------------------
 .../main/java/org/apache/storm/healthcheck/HealthChecker.java    | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/storm/blob/9e84142c/storm-server/src/main/java/org/apache/storm/healthcheck/HealthChecker.java
----------------------------------------------------------------------
diff --git a/storm-server/src/main/java/org/apache/storm/healthcheck/HealthChecker.java b/storm-server/src/main/java/org/apache/storm/healthcheck/HealthChecker.java
index 5f877fc..38bcf64 100644
--- a/storm-server/src/main/java/org/apache/storm/healthcheck/HealthChecker.java
+++ b/storm-server/src/main/java/org/apache/storm/healthcheck/HealthChecker.java
@@ -107,7 +107,7 @@ public class HealthChecker {
                 while ((str = reader.readLine()) != null) {
                     if (str.startsWith("ERROR")) {
                         LOG.warn("The healthcheck process {} exited with code {}", script, process.exitValue());
-                        return FAILED;
+                        return FAILED_WITH_EXIT_CODE;
                     }
                 }
                 return SUCCESS;
@@ -118,7 +118,7 @@ public class HealthChecker {
             return TIMEOUT;
         } catch (Exception e) {
             LOG.warn("Script failed with exception: ", e);
-            return FAILED_WITH_EXIT_CODE;
+            return FAILED;
         } finally {
             if (interruptThread != null) {
                 interruptThread.interrupt();


[4/5] storm git commit: STORM-3240 any non-zero exit code causes health check failure

Posted by bo...@apache.org.
STORM-3240 any non-zero exit code causes health check failure


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

Branch: refs/heads/master
Commit: 0b32a2950c61814ec6f9a9d73a82242559bb003f
Parents: 9e84142
Author: Aaron Gresch <ag...@yahoo-inc.com>
Authored: Tue Oct 2 15:35:59 2018 -0500
Committer: Aaron Gresch <ag...@yahoo-inc.com>
Committed: Tue Oct 2 15:35:59 2018 -0500

----------------------------------------------------------------------
 docs/Setting-up-a-Storm-cluster.md                               | 2 +-
 .../main/java/org/apache/storm/healthcheck/HealthChecker.java    | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/storm/blob/0b32a295/docs/Setting-up-a-Storm-cluster.md
----------------------------------------------------------------------
diff --git a/docs/Setting-up-a-Storm-cluster.md b/docs/Setting-up-a-Storm-cluster.md
index c4a637c..d770a58 100644
--- a/docs/Setting-up-a-Storm-cluster.md
+++ b/docs/Setting-up-a-Storm-cluster.md
@@ -92,7 +92,7 @@ drpc.servers: ["111.222.333.44"]
 
 ### Monitoring Health of Supervisors
 
-Storm provides a mechanism by which administrators can configure the supervisor to run administrator supplied scripts periodically to determine if a node is healthy or not. Administrators can have the supervisor determine if the node is in a healthy state by performing any checks of their choice in scripts located in storm.health.check.dir. If a script detects the node to be in an unhealthy state, it must print a line to standard output beginning with the string ERROR and return a non-zero exit code. In pre-Storm 2.x releases, a bug considered a script exit value of 0 to be a failure.  This has now been fixed.  The supervisor will periodically run the scripts in the health check dir and check the output. If the script’s output contains the string ERROR, as described above, the supervisor will shut down any workers and exit.
+Storm provides a mechanism by which administrators can configure the supervisor to run administrator supplied scripts periodically to determine if a node is healthy or not. Administrators can have the supervisor determine if the node is in a healthy state by performing any checks of their choice in scripts located in storm.health.check.dir. If a script detects the node to be in an unhealthy state, it must return a non-zero exit code. In pre-Storm 2.x releases, a bug considered a script exit value of 0 to be a failure.  This has now been fixed.  The supervisor will periodically run the scripts in the health check dir and check the output. If the script’s output contains the string ERROR, as described above, the supervisor will shut down any workers and exit.
 
 If the supervisor is running with supervision "/bin/storm node-health-check" can be called to determine if the supervisor should be launched or if the node is unhealthy.
 

http://git-wip-us.apache.org/repos/asf/storm/blob/0b32a295/storm-server/src/main/java/org/apache/storm/healthcheck/HealthChecker.java
----------------------------------------------------------------------
diff --git a/storm-server/src/main/java/org/apache/storm/healthcheck/HealthChecker.java b/storm-server/src/main/java/org/apache/storm/healthcheck/HealthChecker.java
index 38bcf64..b5f3655 100644
--- a/storm-server/src/main/java/org/apache/storm/healthcheck/HealthChecker.java
+++ b/storm-server/src/main/java/org/apache/storm/healthcheck/HealthChecker.java
@@ -107,10 +107,10 @@ public class HealthChecker {
                 while ((str = reader.readLine()) != null) {
                     if (str.startsWith("ERROR")) {
                         LOG.warn("The healthcheck process {} exited with code {}", script, process.exitValue());
-                        return FAILED_WITH_EXIT_CODE;
+                        return FAILED;
                     }
                 }
-                return SUCCESS;
+                return FAILED_WITH_EXIT_CODE;
             }
             return SUCCESS;
         } catch (InterruptedException | ClosedByInterruptException e) {


[2/5] storm git commit: STORM-3240 update health check documentation with behavior change

Posted by bo...@apache.org.
STORM-3240 update health check documentation with behavior change


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

Branch: refs/heads/master
Commit: 7811fd02c5880067593a809024893268ea629db4
Parents: 39d2838
Author: Aaron Gresch <ag...@yahoo-inc.com>
Authored: Tue Oct 2 14:00:52 2018 -0500
Committer: Aaron Gresch <ag...@yahoo-inc.com>
Committed: Tue Oct 2 14:00:52 2018 -0500

----------------------------------------------------------------------
 docs/Setting-up-a-Storm-cluster.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/storm/blob/7811fd02/docs/Setting-up-a-Storm-cluster.md
----------------------------------------------------------------------
diff --git a/docs/Setting-up-a-Storm-cluster.md b/docs/Setting-up-a-Storm-cluster.md
index 67ad727..c4a637c 100644
--- a/docs/Setting-up-a-Storm-cluster.md
+++ b/docs/Setting-up-a-Storm-cluster.md
@@ -92,7 +92,7 @@ drpc.servers: ["111.222.333.44"]
 
 ### Monitoring Health of Supervisors
 
-Storm provides a mechanism by which administrators can configure the supervisor to run administrator supplied scripts periodically to determine if a node is healthy or not. Administrators can have the supervisor determine if the node is in a healthy state by performing any checks of their choice in scripts located in storm.health.check.dir. If a script detects the node to be in an unhealthy state, it must print a line to standard output beginning with the string ERROR. The supervisor will periodically run the scripts in the health check dir and check the output. If the script’s output contains the string ERROR, as described above, the supervisor will shut down any workers and exit.
+Storm provides a mechanism by which administrators can configure the supervisor to run administrator supplied scripts periodically to determine if a node is healthy or not. Administrators can have the supervisor determine if the node is in a healthy state by performing any checks of their choice in scripts located in storm.health.check.dir. If a script detects the node to be in an unhealthy state, it must print a line to standard output beginning with the string ERROR and return a non-zero exit code. In pre-Storm 2.x releases, a bug considered a script exit value of 0 to be a failure.  This has now been fixed.  The supervisor will periodically run the scripts in the health check dir and check the output. If the script’s output contains the string ERROR, as described above, the supervisor will shut down any workers and exit.
 
 If the supervisor is running with supervision "/bin/storm node-health-check" can be called to determine if the supervisor should be launched or if the node is unhealthy.
 


[5/5] storm git commit: Merge branch 'agresch_healthcheck' of https://github.com/agresch/storm into STORM-3240

Posted by bo...@apache.org.
Merge branch 'agresch_healthcheck' of https://github.com/agresch/storm into STORM-3240

STORM-3240: health checks should succeed on exit code 0

This clsoes #2855


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

Branch: refs/heads/master
Commit: fe3cfdf0afb111ac16479a059e8aae54fd0a0321
Parents: ad63cc2 0b32a29
Author: Robert Evans <ev...@yahoo-inc.com>
Authored: Wed Oct 3 12:49:39 2018 -0500
Committer: Robert Evans <ev...@yahoo-inc.com>
Committed: Wed Oct 3 12:49:39 2018 -0500

----------------------------------------------------------------------
 docs/Setting-up-a-Storm-cluster.md                           | 2 +-
 .../java/org/apache/storm/healthcheck/HealthChecker.java     | 8 ++++----
 2 files changed, 5 insertions(+), 5 deletions(-)
----------------------------------------------------------------------