See log4js-node/log4js-node#842 - when previous log files exist, their size is not taken into account for log rolling. Instead the file size counter starts from zero on stream opening.
Actual behaviour: something.log is 77k, max log size is 100k. When the app starts, something.log will be moved to something.log.1 when it reaches a size of 177k instead of 100k. Additionally, if there was a backup file (something.log.1) then that will be overwritten instead of being moved to something.log.2.
Expected behaviour: something.log should be moved to something.log.1 when it reaches a size of 100k, regardless of initial size. something.log.1, if it already exists, should be moved to something.log.2.
See log4js-node/log4js-node#842 - when previous log files exist, their size is not taken into account for log rolling. Instead the file size counter starts from zero on stream opening.
Actual behaviour:
something.logis 77k, max log size is 100k. When the app starts,something.logwill be moved tosomething.log.1when it reaches a size of 177k instead of 100k. Additionally, if there was a backup file (something.log.1) then that will be overwritten instead of being moved tosomething.log.2.Expected behaviour:
something.logshould be moved tosomething.log.1when it reaches a size of 100k, regardless of initial size.something.log.1, if it already exists, should be moved tosomething.log.2.