Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-users] Jetty 12.x request log rotation based on size

Use the `Slf4jRequestLog` implementation and have the logs routed to your logger of choice. (logback, log4j2, java.util.logging, etc)

You can even use your logger of choice to split the log files based on logger name, customize your rollover triggers (when to trigger the rollover, based on size, date, time, age, count of records, etc), customize your rollover behavior (lazy, strict, caching, async, etc), customize your rollover post processing (eg: compression, removal of old logs, submitting logs for processing, etc)

Point is, Jetty doesn't do any of this, it just emits logging events.
It's up to you, and your logging configuration to handle those events how you need to.

- Joakim


On Mon, Feb 17, 2025 at 1:05 PM umesh kudale via jetty-users <jetty-users@xxxxxxxxxxx> wrote:
Hi,

Is there a way to rotate Jetty request logs based on size? I am using Jetty 12.0.15 in standalone mode and assuming the change might be as simple as changing Jetty-requestlog.xml. This document is talking about configuring logback of log4j2 in jetty custom logging section, however I am specifically looking for something in the request logs.

Thanks,
Umesh.
_______________________________________________
jetty-users mailing list
jetty-users@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/jetty-users

Back to the top