Using dependency injection in a .Net Core console application

One of the key features of ASP.NET Core is baked in dependency injection. Whether you choose to use the built in container or a third party container will likely come down to whether the built in container is powerful enough for your given project. For small projects it may be fine, but if you need convention based registration, logging/debugging tools, or more esoteric approaches like property injection, then you’ll need to look elsewhere. Why use the built-in container? One question that’s come up a few times, is whether you can…

From Installation to Advanced Configuration: Setting Up Serilog for C# Success

Logging and road

In the ever-evolving landscape of software development, effective logging is crucial for maintaining robust and reliable applications. Serilog has emerged as a leading tool for C# developers, offering a flexible and powerful logging solution tailored to modern needs. This comprehensive guide will walk you through the installation and advanced configuration of Serilog in your C# projects, ensuring that you harness its full potential. From setting up various sinks for diverse output channels to integrating custom logging classes that capture detailed runtime data, you’ll discover best practices for enhancing application maintainability…