Kestrel:net Core cross-platform server

Source: Internet
Author: User

Overview

Kestrel is a LIBUV-based, cross-platform ASP. NET Core Web server, LIBUV is a cross-platform asynchronous I/O library. The ASP. NET Core Project uses Kestrel as the Web server by default .

Users can use the kestrel alone, or with IIS, Nginx, Apache and other reverse proxy Server a piece of use; Microsoft has suggested that the latter be used, implicitly speaking

Program.cs

 Public Static void Main (string[] args) {    buildwebhost (args). Build (). Run ();}  Public Static Iwebhostbuilder buildwebhost (string[] args) =    webhost.createdefaultbuilder (args)        . Usestartup<Startup> ();

. Usekestrel (options ={options. Limits.maxconcurrentconnections= -; Options. Limits.maxconcurrentupgradedconnections= -; Options. Limits.maxrequestbodysize=Ten*1024x768; Options. Limits.minrequestbodydatarate=NewMindatarate (Bytespersecond: -, GracePeriod:TimeSpan.FromSeconds (Ten)); Options. Limits.minresponsedatarate=NewMindatarate (Bytespersecond: -, GracePeriod:TimeSpan.FromSeconds (Ten)); Options. Listen (Ipaddress.loopback, the); Options. Listen (Ipaddress.loopback,5001, listenoptions ={Listenoptions.usehttps ("testcert.pfx","Testpassword"); });});

Document:

Microsoft Official:

https://docs.microsoft.com/en-us/aspnet/core/fundamentals/servers/kestrel?view=aspnetcore-2.1&tabs= Aspnetcore2x

Nginx, or Apache

Kestrel:net Core cross-platform server

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.