Hi,

Env:Tomcat 5.5; ActiveMQ 4.1.1; Log4J 1.2

I am trying to post error messages to a Log4J topic in ActiveMQ via 
the JMSAppender.  I am running the standard downloaded ActiveMQ 4.1.1 
with no modifications.

When I start up a standalone test case in my IDE it works fine.  When 
I deploy to Tomcat and start up the web app in tomcat  I get the 
following error.

log4j:WARN No appenders could be found for logger 
(org.apache.activemq.transport.WireFormatNegotiator).
log4j:WARN Please initialize the log4j system properly.
log4j:ERROR Error while activating options for appender named [TEST].
javax.jms.JMSException: Wire format negociation timeout: peer did not 
send his wire format.
        at org.apache.activemq.util.JMSExceptionSupport.create
(JMSExceptionSupport.java:58)
        at org.apache.activemq.ActiveMQConnection.syncSendPacket
(ActiveMQConnection.java:1185)
        at 
org.apache.activemq.ActiveMQConnection.ensureConnectionInfoSent
(ActiveMQConnection.java:1263)
        at org.apache.activemq.ActiveMQConnection.createSession
(ActiveMQConnection.java:276)
        at org.apache.activemq.ActiveMQConnection.createTopicSession
(ActiveMQConnection.java:964)
        at org.apache.log4j.net.JMSAppender.activateOptions(Unknown 
Source)
Caused by: java.io.IOException: Wire format negociation 
timeout: peer 
did not send his wire format.
        at org.apache.activemq.transport.WireFormatNegotiator.oneway
(WireFormatNegotiator.java:88)
        at org.apache.activemq.transport.MutexTransport.oneway
(MutexTransport.java:47)

My log4j.properties contains the following:
log4j.appender.TEST=org.apache.log4j.net.JMSAppender
log4j.appender.TEST.InitialContextFactoryName=org.apache.activemq.jndi
.ActiveMQInitialContextFactory
log4j.appender.TEST.ProviderURL=tcp://localhost:61616
log4j.appender.TEST.TopicBindingName=dynamicTopics/testTopic
log4j.appender.TEST.TopicConnectionFactoryBindingName=ConnectionFactor
y

Thanks,
Michael
-- 
View this message in context: 
http://www.nabble.com/Log4j-with-JMSAppender-to-ActiveMQ-in-Tomcat-5.5-tf4106868s2354.html#a11678708
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Reply via email to