0

I am new to nodejs and I am trying to compress the backup log files with DateRolling File appended using log4js with nodejs. "appenders": [ { "type": "dateFile", "pattern":"_yyyy_MM_dd.zip", alwaysIncludePattern":false, } I am getting zip files but they are not actually compressed.

1 Answers1

0

ok..so i found the solution for this. Look like in the new implementation of log4js (version 1.0.0) they have compression feature included.

https://github.com/nomiddlename/log4js-node/pull/171

  • log4js.configure({ "appenders": [ { "type": "dateFile", "filename": "blah.log", "pattern": "-yyyy-MM-dd", "alwaysIncludePattern": false, "compress": true // new option } ] }); – user3391699 Mar 21 '17 at 16:36