Open
Description
Core system
As a VB.Net app, there is a recommended system of Logging facilities that we could be taking more of an advantage of. We should make sure that we adhere to it as much as possible, in the following ways:
Take advantage of the Application Event Log- EventLog isn't going to work, see notes. Creating a new event log requires administrative privileges, which isn't an easy thing to consider until some part of WinNUT is operating with higher privileges.
- Event Tracing for Windows
- Use EventProviderTraceListener class
- Seems like a fairly complicated system worth looking into later. Stick tor files for now.
- FileLog
- Default VB.Net logging facility with some nice features like log rotation
- Does not provide a concise and detailed amount of information per-write by default. Example:
DefaultSource Information 0 MyApplication_Startup complete.
- XmlWriterTraceListener
- Great amount of information, but lacking in management features that the FileLog has.
Third party solutions?
Consider using a third party (open source) solution.
Additional information in (crash) logs
We need to print somewhere the NUT server and protocol version strings. Perhaps do it both in parameters and log output sections. It would also be helpful to have save a buffer of the last commands sent and received with the NUT server.