Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-dev] Making ProxyServlet more extensible

Well ... uhm ... sorta. ;-)

jetty-centralized-logging [1] does 3 things.
1) route all log4j + commons-logging + java.util.logging to slf4j
2) using internally developed slf4j appender write log to disk.
3) single configuration for all loggers.

Features 2 and 3 are being enhanced in sandbox right now to support an optional shaded log4j for its appenders and use log4j itself for the configuration.

The end result is that the users of jetty-centralized-logging can use the internal appenders or the shaded log4j appenders to manage their logs.

Now, there's another project in sandbox called jetty-webapp-logging [2] which does the webapp specific pieces for the centralized-logging effort.  Such as ...
1) Using the jetty-centralized-logging classes for the 4 popular logging implementations (log4j, commons-logging, java.util.logging, and slf4j), while IGNORING any webapp bundled implementations of those same classes.
2) A webapp context wrapper that uses the slf4j NDC concepts to include context information into the log events (so that the log output can include things like target URI, remote IP address, remote User, security Principal, and context path)

[1] http://dev.eclipse.org/svnroot/rt/org.eclipse.jetty/sandbox/trunk/jetty-centralized-logging
[2] http://dev.eclipse.org/svnroot/rt/org.eclipse.jetty/sandbox/trunk/jetty-webapp-logging

- Joakim

2009/11/23 Eirik Bjørsnøs <eirbjo@xxxxxxxxx>
On Mon, Nov 23, 2009 at 2:27 PM, Jesse McConnell
<jesse.mcconnell@xxxxxxxxx> wrote:
> Joakim,
>
> this might be a good place to call out some of the centralized logging
> work you have done and see if Eirik is interested in giving it a whirl
> as he mentioned that specifically in his original mail

Just to clarify: I was talking about centralized HTTP request logging.
If I understand things correctly, jetty-centralized-logging is more
about centralized application level logging with log4j etc?

The ability to have a single RequestLogHandler log to multiple
RequestLogs based on the request (path etc) would be nice though.
Currently, request logging seems to be an all or nothing thing in
Jetty.

Also, RolloverFileOutputStream is a bit limited in that it is
hard-coded to roll daily. It would be useful if it was configurable to
roll weekly, monthly, on a certain size etc.

Looking at RequestLogHandler with friends it seems to be quite a lot
of work to change them to fit my specific needs for this, so it might
be better if I just implement my own request logging for the proxy
server, reusing Jetty's classes wherever it makes sense.

Thanks,
Eirik.
_______________________________________________
jetty-dev mailing list
jetty-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/jetty-dev


Back to the top