Hi Christopher,

Changing the existing AccessLogValve to use a logger would have an impact
on performances with the creation of intermediate String objects and
keeping backward compatibility on the access logs files management (naming,
rotation, ...) with a new "LogFactory.getLogger()" approach would require
substantial efforts.

Cyrille


On Thu, Dec 12, 2013 at 2:56 PM, Christopher Schultz <
ch...@christopherschultz.net> wrote:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA256
>
> Cyrille,
>
> On 12/12/13, 3:56 AM, Cyrille Le Clerc wrote:
> > Hello Christopher,
> >
> > Delegating to log4j/logback/java.util.logging could be an option
> > but it would still greatly benefit of a refactoring to split the
> > existing AccessLogValve into an AbstractAccessLogValve with the
> > formatting logic and an AccessLogValve that would keep the logic to
> > write in the file.
> >
> > With this split, the <MyLoggingFramework>AccessLogValve would
> > extend the AbstractAccessLogValve.
>
> I'm not sure that's even necessary (since the current class could be
> merely changed-over to use a logger directly), although the
> AccessLogValve was designed to be "fast" which I believe it why it
> does not use a "regular" logger but rather its own write-to-disk logger.
>
> > Regarding the existing Syslog implementations in Log4j and Logback,
> > they don't yet allow user to customise the syslog header fields but
> > I plan to propose to contribute these enhancements.
>
> Great!
>
> > Finally, regarding the idea of injecting a logging framework jar in
> > Tomcat classloader, I feel it makes things pretty difficult to
> > understand with the risk of collision of the jars.
>
> I'm not sure that's much of a problem. First, Tomcat uses
> commons-logging and (modified) java.logging out of the box so they
> don't need to be "added"... just the logger that knows how to contact
> connect to syslog. Tomcat also supports using log4j which has a syslog
> appender already in it.
>
> > As a conclusion, I would be very happy to contribute to the Tomcat
> > project either the full SyslogAccessLogValve or just the split of
> > the existing AccessLogValve into an AbstractAccessLogValve with the
> > formatting logic and a AccessLogValve with the logic to write in
> > files.
>
> I'll let others comment, of course.
>
> - -chris
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.15 (Darwin)
> Comment: GPGTools - http://gpgtools.org
> Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/
>
> iQIcBAEBCAAGBQJSqcChAAoJEBzwKT+lPKRYK/kQAJ3EXU+AzaPFOFptiR4ORDad
> ouNxYec6VMQcsTbOUdQVvjPWFdXsXP370qLINR5rfXNabkrZH+xIgDiPqbwM1Uwd
> IritRUNeXdh6hSOPdXK1MDJx8lYfbopjYNC9DfP46lsOQZlU491RLN/eNW+UGkWA
> BsEu9Hk2LPwsIzdgpz7RCbuzgJmURitcpyAGtyHxkw6e/20lhvZo/SjkCGcGK3tS
> qqqWYPzoJBoWrkJYnaVi1eREcNW5mdx8kssFkdeNHSHLYyDzsb6LyrNWSDWqUYFC
> Hn0ej/NNFyJjW/I2X4MIvU30ZuhYw80Oa/ybYyP2Jss+l7gnLltS1ijeXmCoN7pn
> 2JfPqHtpxNp4czQB9WfmgdUvHoYn2uMKt0lQJ13EHU/L6ATHW6zhdzGOJ1LSMfrz
> hPPS4VCxq8miE9gt+j+Q4MgguJxSTHcjlLuObWZifCqh8plWSKlyE8o50nzxn0NQ
> KtwUpsQUUlwha1PNJKWhX/XTBPYbRu0OG+aA+xrFPdJU//68ApXTICcPife05Bc0
> Et/VGgLtJt/q4KnQuIVK7uPD9dOOndMkKAhDSGCZ56TxdxWO0juR1j1lgCi+kC2C
> n0EfsuCe+JUvd5MWmBalcFno09w1tpbTSfxpspmIzwJ8Cx181P5ffDOG9lGlV2nN
> N8H6Bd+kajS9EH3BchTs
> =VgKF
> -----END PGP SIGNATURE-----
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
>
>


-- 
Cyrille Le Clerc
email & gtalk : clecl...@cloudbees.com / mob: +33-6.61.33.69.86 / skype:
cyrille.leclerc
CloudBees, Inc
www.cloudbees.com

Reply via email to