Browse Source

Introduced correct descriptions in HttpSysOptions (#44380)

Davide Donadio 3 years ago
parent
commit
4d000f63ce
1 changed files with 18 additions and 17 deletions
  1. 18 17
      src/Servers/HttpSys/src/HttpSysOptions.cs

+ 18 - 17
src/Servers/HttpSys/src/HttpSysOptions.cs

@@ -38,6 +38,7 @@ public class HttpSysOptions
 
     /// <summary>
     /// The name of the Http.Sys request queue
+    /// The default is `null` (Anonymous queue).
     /// </summary>
     public string? RequestQueueName
     {
@@ -55,8 +56,9 @@ public class HttpSysOptions
     }
 
     /// <summary>
-    /// Indicates if this server instance is responsible for creating and configuring the request queue,
-    /// of if it should attach to an existing queue. The default is to create.
+    /// This indicates whether the server is responsible for creating and configuring the request queue, or if it should attach to an existing queue.
+    /// Most existing configuration options do not apply when attaching to an existing queue.
+    /// The default is `RequestQueueMode.Create`.
     /// </summary>
     public RequestQueueMode RequestQueueMode { get; set; }
 
@@ -68,17 +70,16 @@ public class HttpSysOptions
     public ClientCertificateMethod ClientCertificateMethod { get; set; } = ClientCertificateMethod.AllowCertificate;
 
     /// <summary>
-    /// Gets or sets the number of concurrent workers draining requests from the Http.sys queue.
+    /// The maximum number of concurrent accepts.
+    /// The default is 5 times the number of processors as returned by <see cref="Environment.ProcessorCount" />.
     /// </summary>
-    /// <remarks>
-    /// Defaults to 5 times the number of processors as returned by <see cref="Environment.ProcessorCount" />.
-    /// </remarks>
     public int MaxAccepts { get; set; } = DefaultMaxAccepts;
 
     /// <summary>
-    /// Attempts kernel mode caching for responses with eligible headers. The response may not include
-    /// Set-Cookie, Vary, or Pragma headers. It must include a Cache-Control header with Public and
-    /// either a Shared-Max-Age or Max-Age value, or an Expires header.
+    /// Attempt kernel-mode caching for responses with eligible headers.
+    /// The response may not include Set-Cookie, Vary, or Pragma headers.
+    /// It must include a Cache-Control header that's public and either a shared-max-age or max-age value, or an Expires header.
+    /// The default is `true`.
     /// </summary>
     public bool EnableResponseCaching { get; set; } = true;
 
@@ -104,14 +105,15 @@ public class HttpSysOptions
 
     /// <summary>
     /// Gets or Sets if response body writes that fail due to client disconnects should throw exceptions or
-    /// complete normally. The default is false.
+    /// complete normally.
+    /// The default is `false` (complete normally).
     /// </summary>
     public bool ThrowWriteExceptions { get; set; }
 
     /// <summary>
-    /// Gets or sets the maximum number of concurrent connections to accept, -1 for infinite, or null to
-    /// use the machine wide setting from the registry. The default value is null.
-    /// This settings does not apply when attaching to an existing queue.
+    /// Gets or sets the maximum number of concurrent connections to accept. Set `-1` for infinite.
+    /// Set to `null` to use the registry's machine-wide setting.
+    /// The default value is `null` (machine-wide setting).
     /// </summary>
     public long? MaxConnections
     {
@@ -135,6 +137,7 @@ public class HttpSysOptions
     /// <summary>
     /// Gets or sets the maximum number of requests that will be queued up in Http.Sys.
     /// This settings does not apply when attaching to an existing queue.
+    /// The default is 1000.
     /// </summary>
     public long RequestQueueLimit
     {
@@ -163,10 +166,8 @@ public class HttpSysOptions
     /// When set to null, the maximum request body size is unlimited.
     /// This limit has no effect on upgraded connections which are always unlimited.
     /// This can be overridden per-request via <see cref="IHttpMaxRequestBodySizeFeature"/>.
+    /// The default is set to 30,000,000 bytes, which is approximately 28.6MB.
     /// </summary>
-    /// <remarks>
-    /// Defaults to 30,000,000 bytes, which is approximately 28.6MB.
-    /// </remarks>
     public long? MaxRequestBodySize
     {
         get => _maxRequestBodySize;
@@ -181,7 +182,7 @@ public class HttpSysOptions
     }
 
     /// <summary>
-    /// Gets or sets a value that controls whether synchronous IO is allowed for the HttpContext.Request.Body and HttpContext.Response.Body.
+    /// Control whether synchronous input/output is allowed for the HttpContext.Request.Body and HttpContext.Response.Body.
     /// The default is `false`.
     /// </summary>
     public bool AllowSynchronousIO { get; set; }