Skip to content

[Bug] RotateTime.level() #121

Open
Open
@ly020044

Description

System (please complete the following information):

  • OS: macOS
  • GO Version: 1.21.0
  • Pkg Version: 0.5.4

Describe the bug

当我配置按日期的方式来滚动日志时,当大于 1 天时只能按 1 天来滚动日志。

To Reproduce

seconds := 604800 // 7天
handler.NewTimeRotateFileHandler(
		logFile,
		rotatefile.RotateTime(seconds),
		handler.WithLogLevels(parseLevels(log.level)),
		handler.WithBuffSize(log.bufferSize),
		handler.WithBackupNum(log.maxBackups),
		handler.WithCompress(log.compress),
		handler.WithFilePerm(log.filePerm),

请查看一下这个方法 RotateTime.level

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions