| # An example log4j configuration file that directs its logging output |
| # to a SocketAppender. The SocketAppender is configuted to send its |
| # output to a server running on the localhost port number 12345. |
| |
| # To test this example, you must start a log4j server with the command |
| # |
| # |
| # java org.apache.log4j.net.SocketServer 12345 configurationFile directory/ |
| # |
| # |
| |
| # For the general syntax of property based configuration files see |
| # the documenation of org.apache.log4j.PropertyConfigurator. |
| |
| # The root logger uses the appender called A1. |
| |
| log4j.rootLogger=DEBUG, A1 |
| |
| # A1 is set to be a SocketAppender sending its output to the server |
| running on the local host, port 12345. |
| |
| log4j.appender.A1=org.apache.log4j.net.SocketAppender |
| log4j.appender.A1.Port=12345 |
| log4j.appender.A1.RemoteHost=localhost |
| |
| # In this example, we are not interested in INNER loop or SWAP |
| # messages. You might try to set INNER and SWAP to DEBUG for more |
| # verbose output. |
| |
| log4j.logger.org.apache.log4j.examples.SortAlgo.INNER=INFO |
| log4j.logger.org.apache.log4j.examples.SortAlgo.SWAP=INFO |