早教吧 育儿知识 作业答案 考试题库 百科 知识分享

log4j.properties中log4j.addivity.org.apache=true的这句是什么意思!谢谢各位

题目详情
log4j.properties中log4j.addivity.org.apache=true 的这句是什么意思!
谢谢各位
▼优质解答
答案和解析
The syntax for setting the additivity flag of a logger is:
log4j.additivity.loggerName=[true|false]
Note that the “additivity” keyword appears before the logger name not after, as one
might expect. There is a rationale for this idiosyncrasy. By design all logger names
are considered valid, in particular a name that ends with “.addivity” – a very unlikely
case but one that still must be taken into consideration. The additivity flag applies
only to non-root loggers because a root logger, placed at the top of the hierarchy by
construction, has no parent loggers.