Jetty provides the NCSARequestLog to log the requests. But this seems to rollover on a daily basis by default.
Is there an option to have this rollover on an hourly basis?
Or is there a way to provide a custom log appender for this?
Jetty provides the NCSARequestLog to log the requests. But this seems to rollover on a daily basis by default.
Is there an option to have this rollover on an hourly basis?
Or is there a way to provide a custom log appender for this?
I am not 100% sure what exactly you mean with rollover, but I see two things worth trying:
Look at the retainDays
setting, to define when old logs may be delted. wiki.eclipse.org/Jetty/Howto/Configure_Request_Logs
Tyr to set the filename template to something that is hour-specific:
<requestLog implementation="org.mortbay.jetty.server.NCSARequestLog"> <filename>target/yyyy_mm_dd_hh.request.log</filename> <retainDays>10</retainDays> <append>true</append> <extended>true</extended> <logTimeZone>GMT+1</logTimeZone> </requestLog>
Please feedback, if this works, since I didn't explicitly try it.