In this article, we will learn about what is the Difference between Inprocess and outOfprocess service in asp.net core 2.2 step by step
An Asp.net core Applications can be hosted into
- InProcess
- OutofProcess
Asp.net core InProcess Hosting:
Under default the hosting model for your asp.net core applications is InProcess

This means ASP.NET Core Module forwards the requests to IIS HTTP Server. The IIS HTTP Server is a server that runs in-process with IIS

with InProcess hosting application is hosted inside the IIS worker process This response is better performance as compared to the OutOfProcess model.
In-process models bypass the built-in Kestrel web server of ASP.NET Core.
Asp.net core OutOfProcess Hosting:
If you want to use the OutOfProcess hosting model in your asp.net core Application then IIS HTTP Server won’t be used. in the OutOfProcess Hosting, Kestrel web server is used to process your requests.
The Kestrel is an open-source and cross-platform web server for the ASP.NET Core application. That means this Server supports all the platforms like Windows, Linux,macOS
kestrel can be used, by itself as an edge server and the process used to host the app is dotnet.exe

This means ASP.NET Core Module forwards the requests to Kestrel webserver compare to inprocess model outofprocess model in slower performance

kestrel can be used in combination with a reverse proxy with two web server see the following given image

Asp.net core applications are run without kestrel web severer also by default InProcess hosting model will work out of kestrel web server it will use IIS web server like w3wp.exe or iisexpress.exe
Difference between in-process and out-process
InProcess | OutOfProcess |
the request/responds process through is w3wp.exe or iisexpress.exe | the request/responds process through dotnet.exe |
It is using Single web server | it is using two webservers |
great performance | many proxying requests between internal and external web servers |
Introduction about asp.net Core 2.2
- how to create ASP.NET Core 3 Web API Project - January 21, 2022
- JWT Authentication using OAUTH - January 10, 2022
- Ado.net database Transactions - January 9, 2022
Nice article