File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Getting MEAN with Mongo, Express, Angular, and Node
this week in the
packaging log4j.properties file
Joined: Oct 27, 2008
Oct 27, 2008 10:45:00
I have an application which wraps around log4j logger to be used by several clients. The logger is configured to send messages to a JMS topic using JMSAppender.
There are 2 portions to the application, 1 a client library which is to be used by all clients and the server portion which processes messages from JMS.
I am unable to get the clients to send messages to JMS.
The structure of my jar files are :
| ||_logger.class (Class with all Static methods)
| |_Server.class (MDB which processes JMS Messages)
|_logger.class (Class with all Static methods)
uses the logging-client.jar and calls the logger, its unable to send messages to the JMS.
What am I doing wrong?
Joined: May 14, 2008
Oct 28, 2008 13:12:00
Pras, welcome to JavaRanch!
JBossAS comes with Log4J embedded, and thus all log4j configuration is done via the server/xxx/conf/jboss-log4j.xml file. Essentially, your log4j configuration file is ignored.
You can work around this in one of two ways. First, you could add your logging configuration to jboss-log4j.xml. Second, you could
follow these instructions from Jaikiran.
JBoss In Action
It is sorta covered in the
JavaRanch Style Guide
subject: packaging log4j.properties file
java.util.Logger creating multiple log files
singleton pattern to log messages ?
Good logging system for WebApp (Struts)
Can logger instance be static in multithreaded app?
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015