You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-user@logging.apache.org by Richard Dunn <gn...@mac.com> on 2008/10/23 21:26:35 UTC
JMSAppender failover
I have been using the JMSAppender successfully for over a year, and have even
written a command line aggregator server that gathers the messages from
multiple servers (and optionally forward/filters to another aggregator) and
has been working great.
The one stumbling block I have had not been able to cross is getting the JMS
failover working correctly.
If I have the following in my log4j.properties (no failover) everything
works fine:
log4j.appender.jms.ProviderURL=tcp://jmsserver:61616
If I try either of the following (with failover) the webapps using the
JMSAppender block and will not start:
log4j.appender.jms.ProviderURL=failover://(tcp://jmsserver:61616,tcp://jmsserver2:61616)?randomize=true&backup=true&initialReconnectDelay=20
log4j.appender.jms.ProviderURL=failover:(tcp://jmsserver:61616,tcp://jmsserver2:61616)?randomize=true&backup=true&initialReconnectDelay=20
I have tried numerous combinations of the parameters, including omitting,
but nothing seems to work.
I am using ActiveMQ, and have tried 4.1.2, 5.1.0, 5.2.0 (snapshots), and
5.3.0 (snapshots) all with the same results.
My Log4j version is 1.2.15.
--
View this message in context: http://www.nabble.com/JMSAppender-failover-tp20137938p20137938.html
Sent from the Log4j - Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org
Re: JMSAppender failover
Posted by selezovikj <se...@gmail.com>.
I had the same problem.
For me the commons-logging.jar file was making failover say that it is
attempting to connect for hours.
So, try removing the commons-logging.jar file and make sure you use
activemq-all instead of activemq-core jar file.
Hope this fixes your problem.
Richard Dunn wrote:
>
> I have been using the JMSAppender successfully for over a year, and have
> even written a command line aggregator server that gathers the messages
> from multiple servers (and optionally forward/filters to another
> aggregator) and has been working great.
>
> The one stumbling block I have had not been able to cross is getting the
> JMS failover working correctly.
> If I have the following in my log4j.properties (no failover) everything
> works fine:
> log4j.appender.jms.ProviderURL=tcp://jmsserver:61616
>
> If I try either of the following (with failover) the webapps using the
> JMSAppender block and will not start:
> log4j.appender.jms.ProviderURL=failover://(tcp://jmsserver:61616,tcp://jmsserver2:61616)?randomize=true&backup=true&initialReconnectDelay=20
> log4j.appender.jms.ProviderURL=failover:(tcp://jmsserver:61616,tcp://jmsserver2:61616)?randomize=true&backup=true&initialReconnectDelay=20
>
> I have tried numerous combinations of the parameters, including omitting,
> but nothing seems to work.
>
> I am using ActiveMQ, and have tried 4.1.2, 5.1.0, 5.2.0 (snapshots), and
> 5.3.0 (snapshots) all with the same results.
>
> My Log4j version is 1.2.15.
>
--
View this message in context: http://www.nabble.com/JMSAppender-failover-tp20137938p20227071.html
Sent from the Log4j - Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org