Return-Path: X-Original-To: apmail-activemq-users-archive@www.apache.org Delivered-To: apmail-activemq-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 627629603 for ; Thu, 2 Feb 2012 22:21:31 +0000 (UTC) Received: (qmail 73701 invoked by uid 500); 2 Feb 2012 22:21:30 -0000 Delivered-To: apmail-activemq-users-archive@activemq.apache.org Received: (qmail 73619 invoked by uid 500); 2 Feb 2012 22:21:30 -0000 Mailing-List: contact users-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@activemq.apache.org Delivered-To: mailing list users@activemq.apache.org Received: (qmail 73597 invoked by uid 99); 2 Feb 2012 22:21:29 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 02 Feb 2012 22:21:29 +0000 X-ASF-Spam-Status: No, hits=2.2 required=5.0 tests=HTML_MESSAGE,NORMAL_HTTP_TO_IP,SPF_PASS,WEIRD_PORT X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of kai.hackemesser@gmail.com designates 209.85.217.171 as permitted sender) Received: from [209.85.217.171] (HELO mail-lpp01m020-f171.google.com) (209.85.217.171) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 02 Feb 2012 22:21:23 +0000 Received: by lbjn8 with SMTP id n8so549169lbj.2 for ; Thu, 02 Feb 2012 14:21:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=VKkycKTlUuDrQUB09d5sPgQiepQZuw5x4UHuOWebirc=; b=XbtYrZ+a2GV+XmB5Ry4pDXB1kECcgyuanSAEPHv8nT4fH/yGJUGs4hRG9K3pDiWbcL gfYE9XWFBSfol9EjWHLyPJ9bLY8LJu/scUDS8pAbN1em5VNklbLLCu8MrSsBGAvLRcHj j5Sbhl1uUT3vWeJCA6f9atuo0W9qQOnOTtbWY= MIME-Version: 1.0 Received: by 10.112.31.232 with SMTP id d8mr1200456lbi.96.1328221263215; Thu, 02 Feb 2012 14:21:03 -0800 (PST) Received: by 10.112.95.10 with HTTP; Thu, 2 Feb 2012 14:21:03 -0800 (PST) In-Reply-To: References: Date: Fri, 3 Feb 2012 11:21:03 +1300 Message-ID: Subject: Re: static network connection lost and not recreated From: Kai Hackemesser To: users@activemq.apache.org Content-Type: multipart/alternative; boundary=bcaec555543093bd8904b8029c3f X-Virus-Checked: Checked by ClamAV on apache.org --bcaec555543093bd8904b8029c3f Content-Type: text/plain; charset=UTF-8 Hi The symptoms of our configuration got more and more weird. We use currently topics where we have up to 5 producers and about the same number of consumers, mostly spread over the two boxes having a broker each. We did a run overnight and it ended with one broker falling over with not enough memory (our fault)) but the other one is in a very inconsistent state. It doesn't accept incoming connections from the other box (the clients are configured to try first the local then the other broker) and I can see very high numbers of subscribers on one of the topics (a value of up to 4 would make sense but JMX currently shows 314 - sometimes the value goes up to above 3000 for a second). the clients on the remote box loop in message like: INFO [02 Feb 2012 21:33:36,855]: Successfully reconnected to tcp://otherbox:61616 WARN [02 Feb 2012 21:33:36,855]: Transport (otherbox/10.100.88.17:61616) failed to tcp://kd-sage3:61616 , attempting to automatically reconnect due to: java.net.SocketException: Socket closed On the broker side I got: 2012-02-02 21:33:36,858 | INFO | Transport failed: java.io.EOFException | org.apache.activemq.broker.TransportConnection.Transport | ActiveMQ Transport: tcp:///10.100.88.16:36006 2012-02-02 21:33:36,914 | INFO | Transport failed: java.net.SocketException: Broken pipe | org.apache.activemq.broker.TransportConnection.Transport | Async Exception Handler We use a Spring connection factory to connect, which is set to reconnect automatically if connection is lost: @Bean public CachingConnectionFactory cachingConnectionFactory() { CachingConnectionFactory factory = new CachingConnectionFactory(); factory.setReconnectOnException(true); factory.setTargetConnectionFactory(jmsConnectionFactory()); return factory; } @Bean public ActiveMQConnectionFactory jmsConnectionFactory() { ActiveMQConnectionFactory factory = new ActiveMQConnectionFactory(); factory.setBrokerURL("failover:(tcp://localhost:61616,tcp://otherbox:61616)?randomize=false"); return factory; } The only solution we found was to restart the broker, but as this stuff is planned to go into production we want to serve them a configuration that can have the broker running for months without need to interfere with it. Cheers, Kai 2012/2/2 Torsten Mielke > Hi, > > This should generally work alright. > You may want to configure for debug logging on org.apache.activemq.network > and inspect the logging output carefully when the bridge should get > restored. > > > Torsten Mielke > torsten@fusesource.com > tmielke@blogspot.com > > > On Feb 2, 2012, at 1:57 AM, Kai Hackemesser wrote: > > > Hello, > > > > I have set up a static NC between two brokers of Version 5.5.1, and we > have > > now seen twice within our preproduction test that the connection was lost > > and not reestablished automatically. We could not establish it through > JMX > > using the NC's start operation but had to restart one or both brokers. Is > > this a known bug or a configuration issue? > > > > Cheers, > > Kai > > --bcaec555543093bd8904b8029c3f--