# 日志配置文件
# Author: yu_cheng@dahuatech.com
# 说明：仅常用日志配置说明
#
# 定义一个子Logger：log4j.logger.子Logger名称 = [日志级别], [AppenderA], [AppenderB]
# log4j.logger.subMoudleLog = DEBUG, subMoudleLogAppender
#
# 是否继承rootLogger, true则日志会在子Logger与rootLogger中同时输出
# log4j.additivity.subMoudleLog = false
#
# 设置Appender模式
# log4j.appender.subMoudleLogAppender = org.apache.log4j.RollingFileAppender
#
# 设置日志输出文件
# log4j.appender.subMoudleLogAppender.File = ./SubMoudleLog.log
#
# 设置日志是否追加模式(true:追加模式，false:覆盖模式)
# log4j.appender.subMoudleLogAppender.Append = false
#
# 子模块日志内输出级别控制(输出最低级别)
# log4j.appender.subMoudleLogAppender.Threshold = TRACE
#
# 设置单个日志文件最大容量
# log4j.appender.subMoudleLogAppender.MaxFileSize = 40MB
#
# 设置最大Rolling文件个数
# log4j.appender.subMoudleLogAppender.MaxBackupIndex = 10
#
# 设置日志输出样式
# log4j.appender.subMoudleLogAppender.layout = org.apache.log4j.PatternLayout
#
# 设置日志输出格式(%d:时间, %c:模块名称, %p:日志级别, %t:线程号, %m:代码中要打印的日志, %n:换行, %r:自程序启动到打印该日志时的延时(毫秒) )
# log4j.appender.subMoudleLogAppender.layout.ConversionPattern = %d [%c] [%-5p] [%t] %m%n


# 配置rootLogger
log4j.rootLogger = DEBUG, default, stdout

# 设置日志文件编码
log4j.appender.logfile.encoding = UTF-8

# 设置rootLogger Appender输出格式
log4j.appender.default = org.apache.log4j.RollingFileAppender
log4j.appender.default.File = ./Log/Default.log
log4j.appender.default.Append = true
log4j.appender.default.Threshold = DEBUG
log4j.appender.default.MaxFileSize = 40MB
log4j.appender.default.MaxBackupIndex = 10
log4j.appender.default.layout = org.apache.log4j.PatternLayout
log4j.appender.default.layout.ConversionPattern = %d [%c] [%-5p] TID[%t] %m%n

# 标准输出，控制台输出格式
log4j.appender.stdout = org.apache.log4j.ConsoleAppender
log4j.appender.stdout.Threshold = DEBUG
log4j.appender.stdout.layout = org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern = %d [%c] [%-5p] TID[%t] %m%n

# 默认日志
log4j.logger.Default = DEBUG, default
log4j.additivity.Default = false

# VsApp日志
log4j.logger.LogisticsBase = DEBUG, default
log4j.additivity.LogisticsBase = false

# 自定义模块输出格式(NetUtility模块)
log4j.logger.NetUtility = DEBUG, NetUtilityApd
log4j.additivity.NetUtility = false
log4j.appender.NetUtilityApd = org.apache.log4j.RollingFileAppender
log4j.appender.NetUtilityApd.File = ./Log/NetUtility.log
log4j.appender.NetUtilityApd.Append = true
log4j.appender.NetUtilityApd.Threshold = DEBUG
log4j.appender.NetUtilityApd.MaxFileSize = 40MB
log4j.appender.NetUtilityApd.MaxBackupIndex = 10
log4j.appender.NetUtilityApd.layout = org.apache.log4j.PatternLayout
log4j.appender.NetUtilityApd.layout.ConversionPattern = %d [%c] [%-5p] TID[%t] %m%n

# 自定义模块输出格式(DHCamera模块)
log4j.logger.DHCamera = INFO, DHCameraApd
log4j.additivity.DHCamera = false
log4j.appender.DHCameraApd = org.apache.log4j.RollingFileAppender
log4j.appender.DHCameraApd.File = ./Log/DHCamera.log
log4j.appender.DHCameraApd.Append = true
log4j.appender.DHCameraApd.Threshold = DEBUG
log4j.appender.DHCameraApd.MaxFileSize = 40MB
log4j.appender.DHCameraApd.MaxBackupIndex = 10
log4j.appender.DHCameraApd.layout = org.apache.log4j.PatternLayout
log4j.appender.DHCameraApd.layout.ConversionPattern = %d [%c] [%-5p] TID[%t] %m%n

# 自定义模块输出格式(COMM模块)
log4j.logger.COMM = DEBUG, CommApd
log4j.additivity.COMM = false
log4j.appender.CommApd = org.apache.log4j.RollingFileAppender
log4j.appender.CommApd.File = ./Log/Comm.log
log4j.appender.CommApd.Append = true
log4j.appender.CommApd.Threshold = DEBUG
log4j.appender.CommApd.MaxFileSize = 40MB
log4j.appender.CommApd.MaxBackupIndex = 10
log4j.appender.CommApd.layout = org.apache.log4j.PatternLayout
log4j.appender.CommApd.layout.ConversionPattern = %d [%c] [%-5p] TID[%t] %m%n

# 自定义模块输出格式(3D体积记录, 每天记录一个文件)
log4j.logger.VolumeRecord = INFO, dailyRecord
log4j.additivity.VolumeRecord = false
log4j.appender.dailyRecord = org.apache.log4j.DailyRollingFileAppender
log4j.appender.dailyRecord.File = ./Log/3DVolume.txt
log4j.appender.dailyRecord.Append = true
log4j.appender.dailyRecord.Threshold = DEBUG
log4j.appender.dailyRecord.DatePattern = '.'yyyy-MM-dd
log4j.appender.dailyRecord.layout = org.apache.log4j.PatternLayout
log4j.appender.dailyRecord.layout.ConversionPattern = %d [%c] %m%n

# 自定义模块输出格式(Alarm模块)
log4j.logger.Alarm = DEBUG, AlarmApd
log4j.additivity.Alarm = false
log4j.appender.AlarmApd = org.apache.log4j.RollingFileAppender
log4j.appender.AlarmApd.File = ./Log/Alarm.log
log4j.appender.AlarmApd.Append = true
log4j.appender.AlarmApd.Threshold = DEBUG
log4j.appender.AlarmApd.MaxFileSize = 10MB
log4j.appender.AlarmApd.MaxBackupIndex = 10
log4j.appender.AlarmApd.layout = org.apache.log4j.PatternLayout
log4j.appender.AlarmApd.layout.ConversionPattern = %d [%c] [%-5p] TID[%t] %m%n