I am trying to find difference between inproc and outproc in c#. If I have a dll running on the server and my question is will it run in both inproc and outproc? Performance-wise which process is better?

有帮助吗?

解决方案

An inproc server runs in the same process as the calling application. It's close to a normal function call on a dll. Calling an outproc server, data needs to be marshalled across the process boundry which is an expensive operation. An inproc server is fast but it can bring down your application.

其他提示

From MSDN

ASP.NET session state supports several different storage options for session data. Each option is identified by a value in the SessionStateMode enumeration. The following list describes the available session state modes:

InProc mode, which stores session state in memory on the Web server. This is the default.

StateServer mode/OutProc, which stores session state in a separate process called the ASP.NET state service. This ensures that session state is preserved if the Web application is restarted and also makes session state available to multiple Web servers in a Web farm.

SQLServer mode stores session state in a SQL Server database. This ensures that session state is preserved if the Web application is restarted and also makes session state available to multiple Web servers in a Web farm.

Custom mode, which enables you to specify a custom storage provider. Off mode, which disables session state.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top