Return-Path: X-Original-To: apmail-activemq-commits-archive@www.apache.org Delivered-To: apmail-activemq-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 1509C11754 for ; Fri, 21 Feb 2014 17:15:42 +0000 (UTC) Received: (qmail 21192 invoked by uid 500); 21 Feb 2014 17:15:41 -0000 Delivered-To: apmail-activemq-commits-archive@activemq.apache.org Received: (qmail 21130 invoked by uid 500); 21 Feb 2014 17:15:41 -0000 Mailing-List: contact commits-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@activemq.apache.org Delivered-To: mailing list commits@activemq.apache.org Received: (qmail 21123 invoked by uid 99); 21 Feb 2014 17:15:40 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 21 Feb 2014 17:15:40 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id A45CC82E80A; Fri, 21 Feb 2014 17:15:40 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: tabish@apache.org To: commits@activemq.apache.org Message-Id: X-Mailer: ASF-Git Admin Mailer Subject: git commit: https://issues.apache.org/jira/browse/AMQ-5071 Date: Fri, 21 Feb 2014 17:15:40 +0000 (UTC) Repository: activemq Updated Branches: refs/heads/trunk 232b8c51e -> 914beaeb4 https://issues.apache.org/jira/browse/AMQ-5071 fix bad logger Project: http://git-wip-us.apache.org/repos/asf/activemq/repo Commit: http://git-wip-us.apache.org/repos/asf/activemq/commit/914beaeb Tree: http://git-wip-us.apache.org/repos/asf/activemq/tree/914beaeb Diff: http://git-wip-us.apache.org/repos/asf/activemq/diff/914beaeb Branch: refs/heads/trunk Commit: 914beaeb4cc713c558098b0694fdb48fdfab473c Parents: 232b8c5 Author: Timothy Bish Authored: Fri Feb 21 12:15:13 2014 -0500 Committer: Timothy Bish Committed: Fri Feb 21 12:15:28 2014 -0500 ---------------------------------------------------------------------- .../java/org/apache/activemq/thread/PooledTaskRunner.java | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/activemq/blob/914beaeb/activemq-client/src/main/java/org/apache/activemq/thread/PooledTaskRunner.java ---------------------------------------------------------------------- diff --git a/activemq-client/src/main/java/org/apache/activemq/thread/PooledTaskRunner.java b/activemq-client/src/main/java/org/apache/activemq/thread/PooledTaskRunner.java index 3657e12..2425bc8 100644 --- a/activemq-client/src/main/java/org/apache/activemq/thread/PooledTaskRunner.java +++ b/activemq-client/src/main/java/org/apache/activemq/thread/PooledTaskRunner.java @@ -22,7 +22,7 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; /** - * + * */ class PooledTaskRunner implements TaskRunner { @@ -41,6 +41,7 @@ class PooledTaskRunner implements TaskRunner { this.maxIterationsPerRun = maxIterationsPerRun; this.task = task; runable = new Runnable() { + @Override public void run() { runningThread = Thread.currentThread(); try { @@ -56,6 +57,7 @@ class PooledTaskRunner implements TaskRunner { /** * We Expect MANY wakeup calls on the same TaskRunner. */ + @Override public void wakeup() throws InterruptedException { synchronized (runable) { @@ -88,8 +90,9 @@ class PooledTaskRunner implements TaskRunner { * * @throws InterruptedException */ + @Override public void shutdown(long timeout) throws InterruptedException { - LOG.trace("Shutdown timeout: {} task: {}", task); + LOG.trace("Shutdown timeout: {} task: {}", timeout, task); synchronized (runable) { shutdown = true; // the check on the thread is done @@ -104,6 +107,7 @@ class PooledTaskRunner implements TaskRunner { } } + @Override public void shutdown() throws InterruptedException { shutdown(0); } @@ -132,7 +136,7 @@ class PooledTaskRunner implements TaskRunner { } } } finally { - synchronized( runable ) { + synchronized (runable) { iterating = false; runable.notifyAll(); if (shutdown) {