camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <claus.ib...@gmail.com>
Subject Re: JMS publish consuming sockets?
Date Fri, 10 Jul 2009 07:55:45 GMT
Hi

Are your routes InOnly? Eg you do not consume from a JMS queue?

There was a bad default in camel-jms. See the warning on the JMS component page.
Maybe it can help.

And have you tried asking on the ActiveMQ forums. Must be an issue
they have heard before.
AMQ have a ton of settings to adjust.


On Thu, Jul 9, 2009 at 2:09 AM, huntc<huntc@mac.com> wrote:
>
> Hi guys,
>
> I've just noticed a problem with my 1.6.0 based application. I believe it
> may be establishing a connection with AMQ for the purposes of publishing on
> a topic, and then while retaining that connection, opening another
> connection the next time it needs to publish. This is just a hypothesis but
> after a good period of time (like a month or two), AMQ runs out of file
> descriptors and complains thus:
>
>
> Could not accept connection : Too many open files
>
>
> Here's my Camel route:
>
>
> from("direct:publishCAT21FeatureCollection").process(
>                                cat21FeatureCollectionToGMLTransformer).to(
>                                "activemq-sender:topic:com.classactionpl.javaFlightTopic");
>
>
>
> My spring config for AMQ is (activemq-receiver is defined but actually not
> used by my app at the moment):
>
>
>        &lt;bean id="activeMQConnectionFactory"
> class="org.apache.activemq.ActiveMQConnectionFactory"&gt;
>                &lt;property name="brokerURL"
>                        value="${com.classactionpl.asterixservices.brokerurl}"
/&gt;
>        &lt;/bean&gt;
>        &lt;bean id="activemq-receiver"
> class="org.apache.activemq.camel.component.ActiveMQComponent"&gt;
>                &lt;property name="connectionFactory" ref="activeMQConnectionFactory"
> /&gt;
>        &lt;/bean&gt;
>        &lt;bean id="activemq-sender"
> class="org.apache.activemq.camel.component.ActiveMQComponent"&gt;
>                &lt;property name="connectionFactory"&gt;
>                        &lt;bean class="org.apache.activemq.pool.PooledConnectionFactory"&gt;
>                                &lt;constructor-arg ref="activeMQConnectionFactory"
/&gt;
>                        &lt;/bean&gt;
>                &lt;/property&gt;
>        &lt;/bean&gt;
>
>
> and the broker url:
>
>
> com.classactionpl.asterixservices.brokerurl=failover:tcp://localhost:61616
>
>
> Here's what I see in my Camel application's log file:
>
>
> 2009-07-09 09:47:09,607 [ActiveMQ Task  ] INFO  FailoverTransport
> - Successfully reconnected to tcp://localhost:61616
> 2009-07-09 09:47:25,123 [127.0.0.1:61616] WARN  FailoverTransport
> - Transport failed to tcp://localhost:61616 , attempting to automatically
> reconnect due to: java.net.SocketException: Connection reset
> 2009-07-09 09:47:25,132 [ActiveMQ Task  ] INFO  FailoverTransport
> - Successfully reconnected to tcp://localhost:61616
> 2009-07-09 09:48:35,279 [127.0.0.1:61616] WARN  FailoverTransport
> - Transport failed to tcp://localhost:61616 , attempting to automatically
> reconnect due to: java.io.EOFException
> 2009-07-09 09:48:35,291 [ActiveMQ Task  ] INFO  FailoverTransport
> - Successfully reconnected to tcp://localhost:61616
> 2009-07-09 09:48:35,337 [ActiveMQ Task  ] INFO  FailoverTransport
> - Successfully connected to tcp://localhost:61616
> 2009-07-09 09:49:35,478 [ActiveMQ Task  ] INFO  FailoverTransport
> - Successfully connected to tcp://localhost:61616
> 2009-07-09 09:51:28,171 [ActiveMQ Task  ] INFO  FailoverTransport
> - Successfully connected to tcp://localhost:61616
> 2009-07-09 09:52:55,163 [ActiveMQ Task  ] INFO  FailoverTransport
> - Successfully connected to tcp://localhost:61616
>
>
> I wouldn't expect so many failovers although it might just be the
> PooledConnectionFactory filling up its pool of connections.
>
> Any ideas?
>
> Kind regards,
> Christopher
> --
> View this message in context: http://www.nabble.com/JMS-publish-consuming-sockets--tp24401653p24401653.html
> Sent from the Camel - Users (activemq) mailing list archive at Nabble.com.
>



-- 
Claus Ibsen
Apache Camel Committer

Open Source Integration: http://fusesource.com
Blog: http://davsclaus.blogspot.com/
Twitter: http://twitter.com/davsclaus

Mime
View raw message