⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 log4j.properties

📁 解觖java技术中后台无法上传数给的情况
💻 PROPERTIES
字号:
#
# NOTE for mvnForum users:
#
# - This log4j configuration is based on the example2 of log4j
# - You should change the file name for the log to the folder mvnForumHome/log
# - You could also change the log level (default is debug)
# - If you deploy to a server, you could disable the appdender A1 
# - Please see log4j document for more information on config log4j
#


# An example log4j configuration file that outputs both to System.out
# and a file named 'test'.

# For the general syntax of property based configuration files see the
# documenation of org.apache.log4j.PropertyConfigurator.

# WARNING: Location information can be useful but is very costly in
# terms of computation.

# The root logger uses the appender called A1. 

# The root logger uses the appenders called A1 and A2. Since no level
# is specified, note the empty string between the comma (",") and the
# equals sign ("="), the level of the root logger remains
# untouched. Log4j always initializes the level for the root logger to
# DEBUG. The root logger is the only logger that has a default
# level. By default, all other loggers do not have an assigned level,
# such that they inherit their level instead.

#log4j.rootLogger = DEBUG, A1, A2
# Log only message from com.mvnforum package and its'subpackages 
log4j.logger.com.mvnforum = DEBUG, A1, A2
# Log only message from net.myvietnam package and its'subpackages 
log4j.logger.net.myvietnam = DEBUG, A1, A2
# Log only message from org.apache(party libraries) package and its'subpackages 

log4j.logger.com.mvnsoft = DEBUG

log4j.logger.org.apache = ERROR

# A1 is set to be ConsoleAppender sending its output to System.out
log4j.appender.A1=org.apache.log4j.ConsoleAppender


# A1 uses PatternLayout.
log4j.appender.A1.layout=org.apache.log4j.PatternLayout

# The conversion pattern consists of date in ISO8601 format, level,
# thread name, logger name truncated to its rightmost two components
# and left justified to 17 characters, location information consisting
# of file name (padded to 13 characters) and line number, nested
# diagnostic context, the and the application supplied message

log4j.appender.A1.layout.ConversionPattern=%d %-5p [%t] %-17c{2} (%13F:%L) %3x - %m%n

# Appender A2 writes to the file "test".
#
# NOTE for mvnForum: you should set the log file to a filename in the 
#                    folder mvnForumHome/log
# EXAMPLE:
# log4j.appender.A2.File=C:/soft/tomcat-4.1.7/webapps/mvnforum/WEB-INF/mvnForumHome/log/mvnforum.log
# Note: You can also use DailyFileAppender or RollingFileAppender instead of FileAppender
#       Please see log4j docs for more information
log4j.appender.A2=org.apache.log4j.FileAppender
log4j.appender.A2.File=D:/web/www.josdn.com/WEB-INF/mvnForumHome/log/mvnforum.log

# uncomment this to log to the database
#log4j.rootLogger=ERROR,DATABASE
#log4j.addivity.org.apache=true
#log4j.appender.DATABASE.Threshold=INFO
#log4j.appender.DATABASE=org.apache.log4j.jdbc.JDBCAppender
#log4j.appender.DATABASE.URL=jdbc:mysql://localhost/mvnforum
#log4j.appender.DATABASE.driver=com.mysql.jdbc.Driver
#log4j.appender.DATABASE.user=admin
#log4j.appender.DATABASE.password=admin  
#log4j.appender.DATABASE.sql=INSERT INTO log4j VALUES('%m')
#log4j.appender.DATABASE.layout=org.apache.log4j.PatternLayout


# Truncate 'test' if it aleady exists.
# log4j.appender.A2.Append=false

# Appender A2 uses the PatternLayout.
log4j.appender.A2.layout=org.apache.log4j.PatternLayout
log4j.appender.A2.layout.ConversionPattern=%-5r %-5p [%t] %c{2} - %m%n


# 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

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -