LOG4J2-763: use different mechanism to solve this problem: instead of initializing the formatted message string in the message constructor, postpone this as long as possible until getFormattedMessage() is called. Async loggers and AsyncAppender now call message.getFormattedMessage() before passing the log event to the background thread. Added more tests.

git-svn-id: https://svn.apache.org/repos/asf/logging/log4j/log4j2/trunk@1617291 13f79535-47bb-0310-9956-ffa450edef68
LOG4J2-769: also exclude empty package names from new method {{addPackages(Collection)}}.

git-svn-id: https://svn.apache.org/repos/asf/logging/log4j/log4j2/trunk@1617295 13f79535-47bb-0310-9956-ffa450edef68
LOG4J2-679: ignore mkdirs() result, instead check if resulting directory exists to avoid race condition.

git-svn-id: https://svn.apache.org/repos/asf/logging/log4j/log4j2/trunk@1617298 13f79535-47bb-0310-9956-ffa450edef68