Return-Path: X-Original-To: apmail-helix-commits-archive@minotaur.apache.org Delivered-To: apmail-helix-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 4F41310A46 for ; Wed, 19 Nov 2014 04:03:28 +0000 (UTC) Received: (qmail 43863 invoked by uid 500); 19 Nov 2014 04:03:28 -0000 Delivered-To: apmail-helix-commits-archive@helix.apache.org Received: (qmail 43827 invoked by uid 500); 19 Nov 2014 04:03:28 -0000 Mailing-List: contact commits-help@helix.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@helix.apache.org Delivered-To: mailing list commits@helix.apache.org Received: (qmail 43818 invoked by uid 99); 19 Nov 2014 04:03:28 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 19 Nov 2014 04:03:28 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id C04FE9AA11A; Wed, 19 Nov 2014 04:03:27 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: kanak@apache.org To: commits@helix.apache.org Message-Id: X-Mailer: ASF-Git Admin Mailer Subject: helix git commit: [HELIX-549] Rethrow ThreadDeath instead of discarding. Date: Wed, 19 Nov 2014 04:03:27 +0000 (UTC) Repository: helix Updated Branches: refs/heads/helix-0.6.x 961a9e1fe -> 2eaea9135 [HELIX-549] Rethrow ThreadDeath instead of discarding. Project: http://git-wip-us.apache.org/repos/asf/helix/repo Commit: http://git-wip-us.apache.org/repos/asf/helix/commit/2eaea913 Tree: http://git-wip-us.apache.org/repos/asf/helix/tree/2eaea913 Diff: http://git-wip-us.apache.org/repos/asf/helix/diff/2eaea913 Branch: refs/heads/helix-0.6.x Commit: 2eaea9135e345ff027a41010d0a4ab2a3d0620f3 Parents: 961a9e1 Author: Antony T Curtis Authored: Mon Nov 17 13:08:01 2014 -0800 Committer: Antony T Curtis Committed: Mon Nov 17 13:08:01 2014 -0800 ---------------------------------------------------------------------- .../java/org/apache/helix/controller/GenericHelixController.java | 2 ++ .../main/java/org/apache/helix/manager/zk/ZkCacheEventThread.java | 2 ++ helix-core/src/main/java/org/apache/helix/task/TaskRunner.java | 2 ++ 3 files changed, 6 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/helix/blob/2eaea913/helix-core/src/main/java/org/apache/helix/controller/GenericHelixController.java ---------------------------------------------------------------------- diff --git a/helix-core/src/main/java/org/apache/helix/controller/GenericHelixController.java b/helix-core/src/main/java/org/apache/helix/controller/GenericHelixController.java index 81c2e3d..542316a 100644 --- a/helix-core/src/main/java/org/apache/helix/controller/GenericHelixController.java +++ b/helix-core/src/main/java/org/apache/helix/controller/GenericHelixController.java @@ -587,6 +587,8 @@ public class GenericHelixController implements ConfigChangeListener, IdealStateC } catch (ZkInterruptedException e) { logger.warn("ClusterEventProcessor caught a ZK connection interrupt", e); interrupt(); + } catch (ThreadDeath death) { + throw death; } catch (Throwable t) { logger.error("ClusterEventProcessor failed while running the controller pipeline", t); } http://git-wip-us.apache.org/repos/asf/helix/blob/2eaea913/helix-core/src/main/java/org/apache/helix/manager/zk/ZkCacheEventThread.java ---------------------------------------------------------------------- diff --git a/helix-core/src/main/java/org/apache/helix/manager/zk/ZkCacheEventThread.java b/helix-core/src/main/java/org/apache/helix/manager/zk/ZkCacheEventThread.java index e88b7a3..12c198e 100644 --- a/helix-core/src/main/java/org/apache/helix/manager/zk/ZkCacheEventThread.java +++ b/helix-core/src/main/java/org/apache/helix/manager/zk/ZkCacheEventThread.java @@ -68,6 +68,8 @@ public class ZkCacheEventThread extends Thread { interrupt(); } catch (ZkInterruptedException e) { interrupt(); + } catch (ThreadDeath death) { + throw death; } catch (Throwable e) { LOG.error("Error handling event " + zkEvent, e); } http://git-wip-us.apache.org/repos/asf/helix/blob/2eaea913/helix-core/src/main/java/org/apache/helix/task/TaskRunner.java ---------------------------------------------------------------------- diff --git a/helix-core/src/main/java/org/apache/helix/task/TaskRunner.java b/helix-core/src/main/java/org/apache/helix/task/TaskRunner.java index 7941acb..abd1882 100644 --- a/helix-core/src/main/java/org/apache/helix/task/TaskRunner.java +++ b/helix-core/src/main/java/org/apache/helix/task/TaskRunner.java @@ -64,6 +64,8 @@ public class TaskRunner implements Runnable { signalStarted(); try { _result = _task.run(); + } catch (ThreadDeath death) { + throw death; } catch (Throwable t) { LOG.error("Problem running the task", t); _result = new TaskResult(Status.ERROR, null);