Use of 30-40530-log4j

Source: Internet
Author: User

Use of 30-40530-log4j

1. Add the log4j-1.2.16.jar package to buildpath and copy the log4j. properties file to the class path.

The content of the log4j. properties attribute file.

#--------------------------------

#

Log4j. rootLogger = INFO, stdout

# Log4j. logger. test = info

# Log4j.logger.org. apache. jasper = DEBUG

# Log4j.logger.org. apache. catalina. startup. TldConfig = DEBUG

# Log4j.logger.org. apache. catalina. session. ManagerBase = DEBUG

# Log4j.logger.com. fiscal = DEBUG

# Log4j.logger.com. system = DEBUG

Log4j.logger.com. ibatis = DEBUG

Log4j.logger.com. ibatis. common. jdbc. SimpleDataSource = DEBUG

Log4j.logger.com. ibatis. common. jdbc. ScriptRunner = DEBUG

Log4j.logger.com. ibatis. sqlmap. engine. impl. SqlMapClientDelegate = DEBUG

Log4j. logger. java. SQL. Connection = DEBUG

Log4j. logger. java. SQL. Statement = DEBUG

Log4j. logger. java. SQL. PreparedStatement = DEBUG

Log4j. logger. java. SQL. ResultSet = INFO

Log4j. appender. stdout = org. apache. log4j. leleappender

# Log4j. appender. fileout = org. apache. log4j. RollingFileAppender

# Log4j. appender. fileout. File = e:/log/ibatis. log

# Log4j. appender. fileout. MaxFileSize = 0000kb

 

Log4j. appender. stdout. layout = org. apache. log4j. PatternLayout

# Log4j. appender. stdout. layout. ConversionPattern = [%-5 p] % d {yyyy-MM-dd HH: mm: ss }:% m % n

# Log4j. appender. fileout. layout = org. apache. log4j. PatternLayout

# Log4j. appender. fileout. layout. ConversionPattern = [%-5 p] _ % d {yyyy-MM-dd HH: mm: ss }:% m % n

# Log4j. appender. stdout. layout = org. apache. log4j. SimpleLayout

# Log4j.logger.org = info

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.