java - How can I Force logback rotation -


ideally logback have option rotate on app startup. since feature absent, how can force logback rotate on app startup? since vendor code, i'll have write own program rotatelb.java. how can yet use same logback.xml vendor app uses. doing rotate when log hits 250mb.

this can done writing own trigger, deriving ch.qos.logback.core.rolling.sizeandtimebasedfnatp , overloading istriggeringevent().

but need edit logback.xml config file.

if not possible, can specify alternate config file -dlogback.configurationfile=...

or, since app using slf4j api, try remove logback , use log4j 2 instead, have option need.


Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -