From 710db267a91233af8bffaa3ce9d1ee78b9f37c41 Mon Sep 17 00:00:00 2001 From: Robert Davies Date: Fri, 29 Feb 2008 09:22:02 +0000 Subject: [PATCH] Move back to using DEfaultThreadPools for reconnect tasks - as for very bad connections, DedicatedTaskRunner could get swamped with reconnect tasks git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@632269 13f79535-47bb-0310-9956-ffa450edef68 --- .../activemq/transport/failover/FailoverTransport.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/activemq-core/src/main/java/org/apache/activemq/transport/failover/FailoverTransport.java b/activemq-core/src/main/java/org/apache/activemq/transport/failover/FailoverTransport.java index 28a1210718..e7688a5cf6 100755 --- a/activemq-core/src/main/java/org/apache/activemq/transport/failover/FailoverTransport.java +++ b/activemq-core/src/main/java/org/apache/activemq/transport/failover/FailoverTransport.java @@ -37,7 +37,7 @@ import org.apache.activemq.command.RemoveInfo; import org.apache.activemq.command.Response; import org.apache.activemq.state.ConnectionStateTracker; import org.apache.activemq.state.Tracked; -import org.apache.activemq.thread.DeterministicTaskRunner; +import org.apache.activemq.thread.DefaultThreadPools; import org.apache.activemq.thread.Task; import org.apache.activemq.thread.TaskRunner; import org.apache.activemq.transport.CompositeTransport; @@ -111,7 +111,7 @@ public class FailoverTransport implements CompositeTransport { } }); // Setup a task that is used to reconnect the a connection async. - reconnectTask = new DeterministicTaskRunner(this.executor,new Task() { + reconnectTask = DefaultThreadPools.getDefaultTaskRunnerFactory().createTaskRunner(new Task() { public boolean iterate() { boolean result=false; boolean buildBackup=true; @@ -133,7 +133,7 @@ public class FailoverTransport implements CompositeTransport { return result; } - }); + }, "ActiveMQ Failover Worker: " + System.identityHashCode(this)); } TransportListener createTransportListener() {