Open
Description
Versions:
"winston": "^3.2.1",
"winston-daily-rotate-file": "^4.5.0"
Code:
new (transports.DailyRotateFile)({
filename: "%DATE%.log",
datePattern: 'YYYY-MM-DD',
zippedArchive: true,
maxSize: 1m,
maxFiles: 50,
})
After reached the size limit on the same day, it continues to the next logs (2020-06-29.log.1) and zipping the old file (2020-06-29.log.gz).
But, after starting the program again, It will create a new log (2020-06-29.log) again and not continue from the previous counting (2020-06-29.log.1).
Also, after we reach the max size again, It will write to an existing file (2020-06-29.log.1), and it is not zipping the new log (2020-06-29.log) because we already have a zip file on this name.