How to log data to the Windows Event Log in C#

How to log data to the Windows Event Log in C#

Take advantage of the Windows Event Log to store the log data of your .NET Core applications running on Windows

Use multiple implementations of an interface in ASP.NET Core

Use multiple implementations of an interface in ASP.NET Core

How to register multiple implementations of an interface with the IoC container in ASP.NET Core and retrieve a specific service at runtime

How to use RecyclableMemoryStream in .NET Core

How to use RecyclableMemoryStream in .NET Core

Take advantage of Microsoft.IO.RecyclableMemoryStream to eliminate LOH allocations and avoid memory fragmentation and memory leaks in your .NET Core applications.

How to use ArrayPool and MemoryPool in C#

How to use ArrayPool and MemoryPool in C#

Take advantage of array pooling and memory pooling in C# to reduce allocations and improve the performance of your applications

How to use the Buffer class in C#

How to use the Buffer class in C#

Take advantage of the Buffer class in .NET to improve application performance through faster access to data in memory

How to use HashSet in C#

How to use HashSet in C#

Take advantage of high-performance HashSet collections for storing unique elements to speed up searches in your applications.

How to use IHttpClientFactory in ASP.NET Core

How to use IHttpClientFactory in ASP.NET Core

Take advantage of IHttpClientFactory to create HttpClient instances seamlessly and avoid having to manage their lifetimes manually

How to use the ProblemDetails middleware in ASP.NET Core

How to use the ProblemDetails middleware in ASP.NET Core

Take advantage of the open source ProblemDetails middleware in ASP.NET Core to send clients standardized, machine-readable error messages when exceptions occur

How to create route constraints in ASP.NET Core

How to create route constraints in ASP.NET Core

You can take advantage of custom route constraints in ASP.NET Core to validate route values and avoid passing unwanted or unnecessary requests to action methods.

How to manage user secrets in ASP.NET Core

How to manage user secrets in ASP.NET Core

Take advantage of user secrets management in ASP.NET Core to prevent the sharing of sensitive application data in your projects

How to use named and optional parameters in C#

How to use named and optional parameters in C#

Take advantage of named and optional parameters in C# for improved readability, flexibility, and COM interoperability

How to benchmark C# code using BenchmarkDotNet

How to benchmark C# code using BenchmarkDotNet

Take advantage of this lightweight, open source benchmarking library to transform your methods into benchmarks and track their performance

How to use fluent interfaces and method chaining in C#

How to use fluent interfaces and method chaining in C#

Take advantage of fluent interfaces and method chaining to make your code simple, readable, and understandable

How to build gRPC applications in ASP.NET Core

How to build gRPC applications in ASP.NET Core

Learn how to use gRPC, a language-agnostic, high-performance RPC framework, to build lightweight, high-performance services in ASP.NET Core 3.0

How to unit test static methods in C#

How to unit test static methods in C#

Learn when static methods can’t be unit tested and how to use wrapper classes and the Moq and xUnit frameworks to unit test them when they can

How to redirect a request in ASP.NET Core MVC

How to redirect a request in ASP.NET Core MVC

Take advantage of redirect action results in ASP.NET Core MVC to elegantly redirect a request to a specified URL

How to refactor God objects in C#

How to refactor God objects in C#

Follow these best practices to eliminate God objects and design classes that are loosely coupled, cohesive, and easy to maintain

How to use attribute routing in ASP.NET Core

How to use attribute routing in ASP.NET Core

Take advantage of attribute-based routing in ASP.NET Core to decouple the controller and action names from the route template and allow more flexibility in your routing

How to pass parameters to action methods in ASP.NET Core MVC

How to pass parameters to action methods in ASP.NET Core MVC

Explore the various ways in which you can pass parameters to action methods in ASP.NET Core MVC

How to use API Analyzers in ASP.NET Core

How to use API Analyzers in ASP.NET Core

Take advantage of API Analyzers and Swagger to improve the documentation of your ASP.NET Core APIs

Load More