日志切割,默认切割按照小时维度切

This commit is contained in:
白茶清欢 2021-03-04 23:25:45 +08:00
parent 5d0428059a
commit e655c031b2

View File

@ -102,7 +102,7 @@ func NewRotateLogConfig(logPath string, logFile string, option ...SetRotateLogCo
return nil, LogPathEmptyError() return nil, LogPathEmptyError()
} }
c := &RotateLogConfig{ c := &RotateLogConfig{
TimeIntervalType: 0, TimeIntervalType: TimeIntervalTypeHour,
LogPath: logPath, LogPath: logPath,
LogFileName: logFile, LogFileName: logFile,
DivisionChar: "", DivisionChar: "",