Search in sources :

Example 1 with SimpleLogFormatter

use of com.creditease.agent.log.PLogger.SimpleLogFormatter in project uavstack by uavorg.

the class SystemLogger method newLogger.

private static ISystemLogger newLogger(String logName, String rootpath, String logFileFormat, String logLevel, Boolean debugEnable, int bufferSize, int fileSize, int fileCountLimit) {
    ISystemLogger mainLog = new SystemLogger(logName, rootpath, logFileFormat, bufferSize, fileSize, fileCountLimit, false, new SimpleLogFormatter());
    // set log level
    if (null == logLevel) {
        logLevel = "INFO";
    }
    mainLog.setLevel(LogLevel.valueOf(logLevel));
    // set debug enable
    if (null == debugEnable) {
        debugEnable = false;
    }
    mainLog.enableDebug(debugEnable);
    return mainLog;
}
Also used : ISystemLogger(com.creditease.agent.log.api.ISystemLogger) ISystemLogger(com.creditease.agent.log.api.ISystemLogger) SimpleLogFormatter(com.creditease.agent.log.PLogger.SimpleLogFormatter)

Aggregations

SimpleLogFormatter (com.creditease.agent.log.PLogger.SimpleLogFormatter)1 ISystemLogger (com.creditease.agent.log.api.ISystemLogger)1