JLogger Update (1.1.2)
-
I update my logging NuGet package. It is free to use, and has free support by email. The NuGet package is at NuGet Gallery | Jeff.Jones.JLogger 1.1.2[^] The publicly available demo code and documentation is located at GitHub - MSBassSinger/JLogger_Demo: Demo of how to use the JLogger NuGet package[^] Features: - Made for simplicity, multi-threaded .NET (Framework or Core) applications. Targeted to .NEDT Standard 2.0 - Creates logs to a file (tab delimited that can be opened in Excel) - Creates logs to a SQL Server table (T-SQL code provided for table and stored procedures) - Option for SQL Server to audit changes to the log table - High throughput (file or DB writes are handled on a separate thread in the background) - User defined log fields (in addition to a number of fixed log fields - Log retention is user settable - Optional email sent, specified per log entry. Sample log entries (UDF 1 and UDF 2 are user defined columns; column names can be anything the programmer sets):
Time Log Type Message Addtl Info Entity Name Device Exception Data Stack Info Module Method Line No. ThreadID UDF 1 UDF 2
19:42:56.731 StartupShutdown Default Debug Options Bitset Value: [000A18CA]. Unit Tests JJONES-DEV CreateDebugLogFile 0 1
19:42:58.929 Informational Initial Log entry Log Testers Anonymous frmMain.cs btnRunTest_Click 350 1
19:42:58.945 Error Type: [Error] - Attempted to divide by zero.; Source=[LoggingDemo] Division by zero was intentional Log Testers Anonymous JJONES-DEV [Exception Data:] [x]=[100]; [y]=[0]; N/A frmMain Void TestMethod(Int32) 464 12 Sample value for UDF 1. Sample value for UDF 2.
19:42:58.955 Error, SendEmail Type: [Error, SendEmail] - Attempted to divide by zero.; Source=[LoggingDemo] Division by zero was intentional Log Testers Anonymous JJONES-DEV [Exception Data:] [x]=[100]; [y]=[0]; N/A frmMain Void TestMethod(Int32) 464 1 Sample value for UDF 1. Sample value for UDF 2.
19:42:58.957 StartupShutdown Last line in the log This denotes the last log entry for the logging session. Log Testers Anonymous JJONES-DEV N/A N/A Logger Boolean StopLog() 23 1If you have any questions, please let me know.