views:

203

answers:

2

Does anyone know how to set EntLib in order to purge the log files generated by the rolling flat file trace listener?

I've seen the "MaximumLogFilesBeforePurge" option in a tutorial for entlib 2.0 but it seems it is not there anymore in 4.1

Thanks in advance!

A: 

This was something that was left out when they created version 4.

It is however possible to get this functionality by extending EntLib. See:

http://www.worldolio.com/derek/wordpress/?p=149

Shiraz Bhaiji
A: 

The Rolling Flat File Trace Listener in Enterprise Library 5.0 now has an additional property that enables you to specify the number of log files to keep, and can automatically purge older files based on this setting.

Grigori Melnik