RFC: "Instant" logging

Moderators: Gully, peteru

Post Reply
User avatar
adoxa
Wizard
Posts: 1490
Joined: Thu Feb 23, 2017 22:58
Location: CQ
Contact:

RFC: "Instant" logging

Post by adoxa » Thu Oct 15, 2020 17:14

Here's a patch (with source) that allows logging to be toggled without requiring a restart. It's enabled via Log setting "Instant logging" (off by default). I did it as an option, since doing it always might not be desired when you want to restart, anyway (namely, if logging is off, then you turn logging on before restarting for whatever reason, you'd have a small log between turning on and restarting; conversely, if logging is on, then you turn it off and restart, you'd not have the exit information). If you start without logging, each time it's turned on you'll get a separate file; otherwise it "pauses" the log file. It'd be no problem to only create a single file and continue using it.

For the devs: it's currently all done within UsageConfig. It should perhaps be moved to a function somewhere else, probably LogManager.
Attachments
instant-logging.zip
(29.22 KiB) Downloaded 81 times

Post Reply

Return to “Bug Reporting and Feature Requests”