Skip to content
This repository was archived by the owner on Dec 18, 2018. It is now read-only.
This repository was archived by the owner on Dec 18, 2018. It is now read-only.

Support UNIX sockets #156

Closed
Closed
@Daniel15

Description

@Daniel15

The common use-case for Kestrel in production will be behind a reverse proxy such as Nginx. In cases where the reverse proxy is located on the same machine as the application, connecting via a UNIX socket is more efficient than a TCP socket, as it avoids going through the network layer. Accessing 127.0.0.1 through TCP still needs to initiate a TCP connection and perform handshaking, checksumming, etc, all of which is avoided by using UNIX sockets.

Please add support for UNIX sockets to Kestrel. Current solutions for running ASP.NET on Linux (Mono's FastCGI server) already support UNIX sockets so it would be good to get this into Kestrel too. As far as I know, libuv does support UNIX sockets as Node.js supports them.

More references:

UNIX domain sockets should offer better performance than TCP sockets over loopback interface (less copying of data, fewer context switches).

(http://unix.stackexchange.com/questions/91774/performance-of-unix-sockets-vs-tcp-ports)

The Unix domain sockets are always more efficient and the efficiency benefit is in the 2-3x range.

(https://nicisdigital.wordpress.com/2014/03/03/unix-domain-sockets-vs-loopback-tcp-sockets/)

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions