3
Best Approaches for Middleware
Middleware is one of the most powerful concepts in ASP.NET Core. For legacy ASP.NET developers, Middleware is a relatively new term. Before middleware, there were HTTP handlers and modules, which required separate code to configure through a web.config. Middleware is now considered a first-class citizen in an ASP.NET application, making it easier to maintain in a single code base. First introduced in ASP.NET Core 1.0, the common request and response concepts are considered pipelines for your applications with the ability to control a request and response’s body. This opens up a number of possibilities to create amazing features for your ASP.NET Core web applications.
At the beginning of this chapter, we’ll examine ...
Get ASP.NET 8 Best Practices now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.