I'd recommend that you post some code to show what your client is
doing. The logs really don't provide enough information to diagnose
what might be going on.
On 03/22/2016 11:07 AM, Aleks Balaban wrote:
Hi,
Im using Qpid JMS 0.8.0 library in order to implement a standalone
Java AMQP client. Because the underlying transport connection tends to
break every couple of hours I was trying to configure the reconnection
attempts (like failover but to the same server) using following
configuration:
failover:(amqps://someurl:5671)?failover.reconnectDelay=2000&failover.warnAfterReconnectAttempts=1
In accordance with Qpid failover configuration explanation I expect my
client to keep trying to reconnect increasing the attempt delays for
factor 2 (starting with 2 seconds). Instead, according to the log
file, only two attempts to reconnect have been performed when a
connection failure was detected and at the end the whole client
application has been terminated, what I definitively would like to
avoid! Here is the log file:
2016-03-22 14:29:40 INFO AmqpProvider:1190 - IdleTimeoutCheck closed
the transport due to the peer exceeding our requested idle-timeout.
2016-03-22 14:29:40 DEBUG FailoverProvider:761 - Failover: the
provider reports failure: Transport closed due to the peer exceeding
our requested idle-timeout 2016-03-22 14:29:40 DEBUG
FailoverProvider:519 - handling Provider failure: Transport closed due
to the peer exceeding our requested idle-timeout 2016-03-22 14:29:40
DEBUG FailoverProvider:653 - Connection attempt:[1] to:
amqps://publish.preops.nm.eurocontrol.int:5671 in-progress 2016-03-22
14:29:40 INFO FailoverProvider:659 - Connection attempt:[1] to:
amqps://publish.preops.nm.eurocontrol.int:5671 failed 2016-03-22
14:29:40 WARN FailoverProvider:686 - Failed to connect after: 1
attempt(s) continuing to retry. 2016-03-22 14:29:42 DEBUG
FailoverProvider:653 - Connection attempt:[2] to:
amqps://publish.preops.nm.eurocontrol.int:5671 in-progress 2016-03-22
14:29:42 INFO FailoverProvider:659 - Connection attempt:[2] to:
amqps://publish.preops.nm.eurocontrol.int:5671 failed 2016-03-22
14:29:42 WARN FailoverProvider:686 - Failed to connect after: 2
attempt(s) continuing to retry. 2016-03-22 14:29:43 DEBUG
ThreadPoolUtils:156 - Shutdown of ExecutorService:
java.util.concurrent.ThreadPoolExecutor@778970af[Terminated, pool size
= 0, active threads = 0, queued tasks = 0, completed tasks = 0] is
shutdown: true and terminated: true took: 0.000 seconds. 2016-03-22
14:29:45 DEBUG ThreadPoolUtils:192 - Waited 2.004 seconds for
ExecutorService:
java.util.concurrent.ScheduledThreadPoolExecutor@877a470[Shutting
down, pool size = 1, active threads = 0, queued tasks = 1, completed
tasks = 3] to terminate... 2016-03-22 14:29:46 DEBUG
ThreadPoolUtils:156 - Shutdown of ExecutorService:
java.util.concurrent.ScheduledThreadPoolExecutor@877a470[Terminated,
pool size = 0, active threads = 0, queued tasks = 0, completed tasks =
4] is shutdown: true and terminated: true took: 2.889 seconds.
Any idea, what I’m doing wrong here? Basically, what I'm looking for
to achieve is a client which is capable to detect transport connection
failure and try to reconnect every 5-10 seconds.
Many thanks!
--
Tim Bish
twitter: @tabish121
blog: http://timbish.blogspot.com/
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@qpid.apache.org
For additional commands, e-mail: users-h...@qpid.apache.org