.NET (C#) Logging with ILogger | JWT Authentication: Build a Library with me - VII

Опубликовано: 29 Сентябрь 2024
на канале: Code with Saar
7,863
117

Logging is important, and could be challenge. .NET supports logging API that works with variety of build-in and third-party logging providers by providing ILogger. We will dive into it in this video to see how does it address those key scenarios.

For more videos like this:
💡Subscribe: https://www.youtube.com/c/CodewithSaa...

Resources

Discord server for Code w/ Saar:   / discord  

Example code in video: https://github.com/xiaomi7732/CodeWit...

A quick quiz to help understanding ILogger: https://github.com/xiaomi7732/CodeWit...

NuGet packages for various logging providers: https://www.nuget.org/packages?q=Micr...

Logging in .NET official document: https://docs.microsoft.com/en-us/dotn...

Logging in ASP.NET Core 5.0 official doc: https://docs.microsoft.com/en-us/aspn...

Content

00:00 Intro
01:04 Why logging matters
02:08 Logs before ILogger
03:17 ILogger design overview
04:47 Use a logging provider
06:35 Use multiple logging providers
07:16 Understanding logging levels
08:25 Use IConfiguration for logging settings
09:33 Different logging levels for different providers
10:50 Logging categories
12:49 ILogger in ASP.NET Core
15:01 Considerations for library authors
16:30 Extra: Code with Saar Discord Server