Run(), Use() and Next() Method in Asp.net Core Application | What is IApplicationBuilder.



Run(), Use() and Next() Method in Asp.net Core Application | What is IApplicationBuilder.

Run(), Use() and Next() Method in Asp.net Core Application | What is IApplicationBuilder.

Run, Use and Next Method in Asp.net Core Application . What is IApplicationBuilder.
what is App.Run() extension method , App.Use Extension method in asp.net core.
IApplicationBuilder :
IApplicationBuilder An object that provides the mechanisms to configure an application’s request pipeline.
Use :
The Use Extension Method in ASP.NET Core is used to add a new Middleware component to the Request Processing Pipeline whereas the Next Extension Method in ASP.NET Core is used to call the next middleware component configured in the request processing pipeline.
Run :
The Run method in ASP.NET Core Application is used to complete the Middleware Execution. That means the Run extension method allows us to add the terminating middleware component. Terminating middleware means the middleware which will not call the next middleware components in the request processing pipeline