When it comes to microservice architecture, sometimes all you wanted is to perform cross cutting concerns ( logging, authentication , caching, CORS, Routing, load balancing , exception handling , tracing, resiliency etc..) and also there might be a scenario where you wanted to perform certain manipulations on your request payload before hitting into your actual handler. And this should not be a repetitive code in each of the services , so all you might need is a single place to orchestrate all these concerns and that is where Middleware comes into the picture. In the demo I will be covering how to orchestrate these cross cutting concerns by using Azure functions as a Serverless model.
5. • Handle HTTP Request or Response
• Holds HTTP context and Requestdelegate
• In ASP .NET core we have 3 middleware options
• Use()
• Run()
• Map()
• Process an incoming HTTP request, modify it,
and pass it on to another piece of middleware.
• Handle an incoming HTTP request by generating
an HTTP response.
• Reroute an incoming HTTP request to another
middleware or web server
Middleware & Configuration options
6. ASP.NET Core in Action - What is middleware?
Andrew
https://andrewlock.net/asp-net-core-in-action-what-is-middleware/
9. Serverless to the Max: Doing Big Things for Small Dollars with Cloudflare Workers
and Azure Functions
- Troy
https://www.troyhunt.com/serverless-to-the-max-doing-big-things-for-small-
dollars-with-cloudflare-workers-and-azure-functions/
Don’t use Azure Functions as a web application
- Maarten
https://blog.maartenballiauw.be/post/2019/10/02/dont-use-azure-functions-as-
a-web-application.html
17. ASP.NET Core In Process Hosting on IIS with ASP.NET Core
- Rick
https://weblog.west-wind.com/posts/2019/Mar/16/ASPNET-Core-Hosting-on-IIS-
with-ASPNET-Core-22