Return-Path: Delivered-To: apmail-camel-users-archive@www.apache.org Received: (qmail 58567 invoked from network); 28 Apr 2010 10:49:57 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 28 Apr 2010 10:49:57 -0000 Received: (qmail 53925 invoked by uid 500); 28 Apr 2010 10:49:57 -0000 Delivered-To: apmail-camel-users-archive@camel.apache.org Received: (qmail 53813 invoked by uid 500); 28 Apr 2010 10:49:55 -0000 Mailing-List: contact users-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@camel.apache.org Delivered-To: mailing list users@camel.apache.org Received: (qmail 53804 invoked by uid 99); 28 Apr 2010 10:49:55 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 28 Apr 2010 10:49:55 +0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of claus.ibsen@gmail.com designates 209.85.218.215 as permitted sender) Received: from [209.85.218.215] (HELO mail-bw0-f215.google.com) (209.85.218.215) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 28 Apr 2010 10:49:49 +0000 Received: by bwz7 with SMTP id 7so14611244bwz.36 for ; Wed, 28 Apr 2010 03:49:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:mime-version:received:in-reply-to :references:from:date:message-id:subject:to:content-type :content-transfer-encoding; bh=+b9CaMkyCEBDjeD3h68hZU0CTyoWdZgWUJYRqLUKx/A=; b=BzEDmB4yC2/X78QvXd/nviVaeo2p/bN+Xwd0JZNUEwokmaN6XYW2dNbbx/CZ/xudBX mHpEF5ofDY9l1SbF9CaGnnX83jH9a0i6BQ3jFyHnLyBp3sFAJizAQjlSSFVhej1/QJAg e6SVg8RYGuMCdsdjn+AAMfl5NqwhdsIpzTHKA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type:content-transfer-encoding; b=Mb+kEQxa4V6pvBZbWjYoe6/v3k/4LqDSELYjEw5OTLdZ6kyo8s2p/V7AKi96v03n2R yfTp38TMHfAhEC+j6NJfQSd0SrX1bwJ9gcewyEkJQODUTjN+H9hb6ihws34fBY8BcJQe m5QtMHEfmhVQPTcMwYcvb8tH3u8udcN3+yk6o= Received: by 10.204.3.137 with SMTP id 9mr4645191bkn.6.1272451769193; Wed, 28 Apr 2010 03:49:29 -0700 (PDT) MIME-Version: 1.0 Received: by 10.204.115.210 with HTTP; Wed, 28 Apr 2010 03:49:09 -0700 (PDT) In-Reply-To: <28386612.post@talk.nabble.com> References: <28386612.post@talk.nabble.com> From: Claus Ibsen Date: Wed, 28 Apr 2010 12:49:09 +0200 Message-ID: Subject: Re: activemq component MaxConnection retry To: users@camel.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org Hi I think you can put it in the brokerURL as a uri parameter as shown here http://camel.apache.org/activemq.html On Wed, Apr 28, 2010 at 11:35 AM, ssenth wrote: > > Hi, > I am using the below route to put the message in an ActiveMQ queue > > Bean Declaration =A0 =A0 =A0 =A0 class=3D"org.apache.activemq.camel.component.ActiveMQComponent"> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 > =A0 =A0 =A0 =A0 > > Routing > =A0 =A0 =A0 =A0 > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 > =A0 =A0 =A0 =A0 > > I did send two messages which reached the TargetQueue in ActiveMQ, but wh= en > I stopped the activemq and send the third message, CAMLE did not time > out/stop instead it continuously tries to reconnect to ActiveMQ. Can any = one > let me know how or hing on how to configure the route to stop the CAMEL > context after let's say 3 reconnect attempts and backup the message to a > folder. > > Did find maxReconnectAttempts and startupMaxReconnectAttempts in > org.apache.activemq.transport.failover.FailoverTransport , but could not > figure out how to set these properties. > > > Below is the log4jenties > > Time: 2:24:32 PM=A0=A0Priority: DEBUG=A0=A0Thread: ActiveMQ Task=A0=A0NDC= : null > Category: org.apache.activemq.transport.failover.FailoverTransport Locati= on: > org.apache.activemq.transport.failover.FailoverTransport.doReconnect(Fail= overTransport.java:722) > Message: > Connect fail to: tcp://localhost:61616, reason: java.net.ConnectException= : > Connection refused: connect > Throwable: > null > > Time: 2:24:32 PM=A0=A0Priority: DEBUG=A0=A0Thread: ActiveMQ Task=A0=A0NDC= : null > Category: org.apache.activemq.transport.failover.FailoverTransport Locati= on: > org.apache.activemq.transport.failover.FailoverTransport.doReconnect(Fail= overTransport.java:756) > Message: > Waiting 30000 ms before attempting connection. > Throwable: > null > > Time: 2:24:32 PM=A0=A0Priority: DEBUG=A0=A0Thread: main=A0=A0NDC: null Ca= tegory: > org.apache.activemq.transport.failover.FailoverTransport Location: > org.apache.activemq.transport.failover.FailoverTransport.oneway(FailoverT= ransport.java:406) > Message: > Waiting for transport to reconnect. > Throwable: > null > -- > View this message in context: http://old.nabble.com/activemq-component-Ma= xConnection-retry-tp28386612p28386612.html > Sent from the Camel - Users mailing list archive at Nabble.com. > > --=20 Claus Ibsen Apache Camel Committer Author of Camel in Action: http://www.manning.com/ibsen/ Open Source Integration: http://fusesource.com Blog: http://davsclaus.blogspot.com/ Twitter: http://twitter.com/davsclaus