Return-Path: X-Original-To: apmail-logging-log4j-dev-archive@www.apache.org Delivered-To: apmail-logging-log4j-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 3C1A2112BC for ; Sun, 11 May 2014 18:44:15 +0000 (UTC) Received: (qmail 74672 invoked by uid 500); 11 May 2014 18:44:15 -0000 Delivered-To: apmail-logging-log4j-dev-archive@logging.apache.org Received: (qmail 74625 invoked by uid 500); 11 May 2014 18:44:15 -0000 Mailing-List: contact log4j-dev-help@logging.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Log4J Developers List" Reply-To: "Log4J Developers List" Delivered-To: mailing list log4j-dev@logging.apache.org Received: (qmail 74616 invoked by uid 99); 11 May 2014 18:44:14 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 11 May 2014 18:44:14 +0000 Date: Sun, 11 May 2014 18:44:14 +0000 (UTC) From: "Matt Sicker (JIRA)" To: log4j-dev@logging.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (LOG4J2-631) Cannot use formatter logger and standard logger with same name MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/LOG4J2-631?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13994637#comment-13994637 ] Matt Sicker commented on LOG4J2-631: ------------------------------------ I'd also like to point out that the formatter logger is a lot slower than than normal one. > Cannot use formatter logger and standard logger with same name > -------------------------------------------------------------- > > Key: LOG4J2-631 > URL: https://issues.apache.org/jira/browse/LOG4J2-631 > Project: Log4j 2 > Issue Type: Bug > Affects Versions: 2.0-rc1 > Reporter: Alexandre Gattiker > > {code} > public class Example { > private final static Logger FORMATTER_LOGGER = LogManager.getFormatterLogger(Example.class); > private final static Logger LOGGER = LogManager.getLogger(Example.class); > public static void main(String[] args) { > LOGGER.log(ERROR, "{} happened", "Something"); > FORMATTER_LOGGER.log(ERROR, "%s happened", "Something"); > } > } > {code} > {noformat} > 13:40:35.401 [main] ERROR com.example.Example - {} happened > 13:40:35.404 [main] ERROR com.example.Example - Something happened > {noformat} > After inverting the two constant declarations: > {noformat} > 13:41:13.730 [main] ERROR com.example.Example - Something happened > 13:41:13.732 [main] ERROR com.example.Example - %s happened > {noformat} -- This message was sent by Atlassian JIRA (v6.2#6252) --------------------------------------------------------------------- To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org For additional commands, e-mail: log4j-dev-help@logging.apache.org