You are not logged in.
Pages: 1
Happy New Year to everybody!
The TSynLog.Family has the RotateFileNoCompression property in the mORMot1 but I have not found any analogue in the mORMot2.
Is there a way to rotate old logs without compression in mORMot2?
Sergey
Offline
You need to use the LogCompressAlgo global variable.
If you set it to nil, no compression will take place.
I have refined the documentation about LogCompressAlgo
https://github.com/synopse/mORMot2/commit/334a8ad4
Offline
Thank you!
Offline
Unfortunately, this does not work: empty {LogName}.#.synlz files are created.
It looks like I have to either write a custom OnRotate handler, or write a "dummy" TAlgoCompress inherited class and assign its name to LogCompressAlgo.
Offline
Are you sure you have the latest version of the source?
TSynLog.PerformRotation clearly checks LogCompressAlgo, and if nil, won't use AlgoFileExt and call RenameFile() without any compression, using a {logName}.#.log rotation file.
Offline
My fault! I had not pulled the latest version.
Offline
Pages: 1