Closed ilkerfindik closed 7 years ago
Apologies for the time getting back to you. Your reproduction was very helpful, thank you.
It turns out the level
option on the streams needs to be moved up a level. It's not a property of the RotatingFileStream
, it a property at the same level as type: 'raw'
.
To set up the info stream it would be something like this instead:
var traceStreamerRotatedByLength = {
type:'raw',
level: debugLogLevel,
stream: new RotatingFileStream({
path: './log/ROTATINGFILESTREAM_'+applicationName + dateStringOrEmptyString + '.info.log',
period: '60000ms', // daily rotation
totalFiles: 1000, // keep 10 back copies
threshold: '100m', // Rotate log files larger than 10 megabytes
totalSize: '8g', // Don't keep more than 20mb of archived log files
rotateExisting: true, // Give ourselves a clean file when we start up, based on period
gzip: true // Compress the archive log files to save space
})
};
Once that's in place, filtering the different logs to the different log streams should work fine.
Cheers
This is the setup code I am using
This creates zip files but all of them contain a single (empty) file and the sizes of zip files are always the same.