Return-Path: X-Original-To: apmail-cxf-issues-archive@www.apache.org Delivered-To: apmail-cxf-issues-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E5D57D664 for ; Fri, 6 Jul 2012 06:21:40 +0000 (UTC) Received: (qmail 96259 invoked by uid 500); 6 Jul 2012 06:21:40 -0000 Delivered-To: apmail-cxf-issues-archive@cxf.apache.org Received: (qmail 96109 invoked by uid 500); 6 Jul 2012 06:21:38 -0000 Mailing-List: contact issues-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cxf.apache.org Delivered-To: mailing list issues@cxf.apache.org Received: (qmail 96055 invoked by uid 99); 6 Jul 2012 06:21:36 -0000 Received: from issues-vm.apache.org (HELO issues-vm) (140.211.11.160) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 06 Jul 2012 06:21:36 +0000 Received: from isssues-vm.apache.org (localhost [127.0.0.1]) by issues-vm (Postfix) with ESMTP id BC399142852 for ; Fri, 6 Jul 2012 06:21:35 +0000 (UTC) Date: Fri, 6 Jul 2012 06:21:35 +0000 (UTC) From: "Freeman Fang (JIRA)" To: issues@cxf.apache.org Message-ID: <1618058997.12854.1341555695772.JavaMail.jiratomcat@issues-vm> In-Reply-To: <99448855.43478.1340356122645.JavaMail.jiratomcat@issues-vm> Subject: [jira] [Resolved] (CXF-4392) Easier customization of log messages in Logging[In|Out]Interceptor 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/CXF-4392?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Freeman Fang resolved CXF-4392. ------------------------------- Resolution: Fixed Fix Version/s: 2.7.0 2.6.2 Apply patch on behalf of Tore Eide Andersen with thanks > Easier customization of log messages in Logging[In|Out]Interceptor > ------------------------------------------------------------------ > > Key: CXF-4392 > URL: https://issues.apache.org/jira/browse/CXF-4392 > Project: CXF > Issue Type: Improvement > Components: Core > Affects Versions: 2.6.1 > Reporter: Tore Eide Andersen > Assignee: Freeman Fang > Fix For: 2.6.2, 2.7.0 > > Attachments: CXF-4392-customized-logging-format.patch > > > We're using LoggingInInterceptor and LoggingOutInterceptor to produce logs for use in debugging issues in our services. > Although we're very happy with the features they provide, we find it a bit difficult to tweak what information is being logged and the format of the log. > Some of our clients would like more or less info to be logged, some would like everything in one line, wrapped in XML. > Specifically, it would be nice if the code fragment in the LoggingInInterceptor.logging() and LoggingOutInterceptor.LogWriter.close() methods which produces the log message string was extracted to separate overridable methods in Logging[In|Out]Interceptor, like this: > protected String formatMessage(LoggingMessage message) { > // Use toString as default: > return message.toString(); > } > Another option is to add a factory method for the LoggingMessage such that we could override the toString method. > Or perhaps there are even better ways to meet the need of customized logging formats? -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira