- Re-add the [PluginName] tag to plugin log messages
- Remove source prepending from the SerilogEventSink
- Force a filter refresh on enabling/disabling log filtering
- Convert ModuleLog to properly tag its messages with SourceContext
- Remove the "Reload All Plugins" MenuItem from /xldev
- Remove the /xldreloadplugins Command
- Mark `PluginManager.ReloadAllPluginsAsync()` as obsolete for removal
This commit adds first-pass support for more robust plugin log filtering. No changes were made that affect PluginLog's APIs nor log format. This change works by making use of Serilog's "SourceContext" property to attach plugin information to all log messages. The in-game log UI can then be used to filter based on this property.
Future expansions for this system include the ability to set different plugins to different log levels (something that already can technically be done, but requires those plugins be hard-coded through MinimumLevel.Override), creating new root loggers for each plugin (thereby giving plugin devs more control over their logging should they want to use it), plus other potential improvements in the way of adding context or rich information.
- Update PluginLog to attach a "SourceContext" property to all log messages.
- Tweak the SerilogEventSink to pass the original log event around.
- Suppress Info/Debug/Verbose exceptions from Troubleshooting reports.
- Fix the ConsoleWindow log filter to use _all_ filters, rather than just one.
- Add ConsoleWindow dropdown to select plugins to filter logs by
- Add support for multiple log levels to ConsoleWindow filtering