Package ch.qos.logback.core.rolling

Examples of ch.qos.logback.core.rolling.TimeBasedRollingPolicy.start()


    TimeBasedRollingPolicy tbrp = new TimeBasedRollingPolicy();
   
    tbrp.setContext(loggerContext);
    tbrp.setFileNamePattern(filename+"-%d{"+DATE_PATTERN+"}.log");
    tbrp.setParent(rfa);
    tbrp.start();
 
    rfa.setRollingPolicy(tbrp);

   
    rfa.start();
View Full Code Here


            TimeBasedRollingPolicy policy = new TimeBasedRollingPolicy();
            policy.setContext(loggerContext);
            policy.setMaxHistory(((LogFileOutput) output).getKeepDays());
            policy.setFileNamePattern(basePath + ((LogFileOutput) output).getFileName() + ".%d{yyyy-MM-dd}.gz");
            policy.setParent((FileAppender) appender);
            policy.start();

            ((RollingFileAppender) appender).setRollingPolicy(policy);

            PatternLayoutEncoder pl = new PatternLayoutEncoder();
            pl.setContext(loggerContext);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.