Configuration: HTTP



Http.MinDataRateBytesPerSec

  • Set Kestrel's minimum required data rate in bytes per second.

  • This option must be configured together with Http.MinDataRateGracePeriod.


Http.MinDataRateGracePeriodInSec

  • Set Kestrel's allowed request and response grace period in seconds.
    This option must be configured together with Http.MinDataRateBytesPerSec

  • Kestrel checks every second if data is coming in at the specified rate in bytes/second.
    If the rate drops below the minimum set by MinResponseDataRate, the connection is timed out.

  • The grace period Http.MinDataRateGracePeriodInSec is the amount of time that Kestrel gives the client to increase its send rate up to the minimum. The rate is not checked during that time. The grace period helps avoid dropping connections that are initially sending data at a slow rate due to TCP slow-start.

  • When set to null then rates are unlimited, no minimum data rate will be enforced.


If either one of Http.MinDataRateBytesPerSec or Http.MinDataRateGracePeriodInSec is Not set or set to null,
then both Kestrel's properties ( MinResponseDataRate & MinRequestBodyDataRate ) will be set to null.

Http.MaxRequestBufferSizeInKb

  • Set the maximum size of the response buffer before write calls begin to block or return tasks that don't complete until the buffer size drops below the configured limit.

  • If not set, or set to null, then the size of the request buffer is unlimited.


  • Type: int
  • Default: null
  • Scope: Server-wide only
  • Used for setting Kestrel property: MaxRequestBufferSize

Http.MaxRequestLineSizeInKb

Set the maximum allowed size for the HTTP request line.

  • Type: int
  • Default: 16
  • Scope: Server-wide only
  • Used for setting Kestrel property: MaxRequestLineSize

Http.Http2.KeepAlivePingTimeoutInSec

Set Kestrel's HTTP2 keep alive ping timeout.

  • Type: int
  • Default: null
  • Scope: Server-wide only
  • Used for setting Kestrel property: KeepAlivePingTimeout

Http.Http2.KeepAlivePingDelayInSec

Set Kestrel's HTTP2 keep alive ping delay.

  • Type: int
  • Default: null
  • Scope: Server-wide only
  • Used for setting Kestrel property: KeepAlivePingDelay

Http.Http2.MaxStreamsPerConnection

  • Set Kestrel's HTTP2 max streams per connection.

  • This limits the number of concurrent request streams per HTTP/2 connection.
    Excess streams will be refused.

  • When Http.Http2.MaxStreamsPerConnection is null or not set,
    RavenDB assigns int.MaxValue to MaxStreamsPerConnection.


  • Type: int
  • Default: null (no limit)
  • Scope: Server-wide only
  • Used for setting Kestrel property: MaxStreamsPerConnection

Http.UseResponseCompression

  • Set whether Raven's HTTP server should compress its responses.

  • Using compression lowers the network bandwidth usage.
    However, setting to false is needed in order to debug or view the response via sniffer tools.


  • Type: bool
  • Default: true
  • Scope: Server-wide only

Http.AllowResponseCompressionOverHttps

  • Set whether Raven's HTTP server should allow response compression to happen when HTTPS is enabled.

  • Please see http://breachattack.com/ before enabling this.


  • Type: bool
  • Default: true
  • Scope: Server-wide only
  • Used for setting Kestrel property: EnableForHttps

Http.GzipResponseCompressionLevel

Set the compression level to be used when compressing HTTP responses with GZip.

  • Type: enum CompressionLevel (Optimal, Fastest, NoCompression, SmallestSize)
  • Default: Fastest
  • Scope: Server-wide only
  • Used for setting Kestrel property: Level

Http.DeflateResponseCompressionLevel

Set the compression level to be used when compressing HTTP responses with Deflate.

  • Type: enum CompressionLevel (Optimal, Fastest, NoCompression, SmallestSize)
  • Default: Fastest
  • Scope: Server-wide only
  • Used for setting Kestrel property: Level

Http.ZstdResponseCompressionLevel

Set the compression level to be used when compressing HTTP responses with Zstd.

  • Type: enum CompressionLevel (Optimal, Fastest, NoCompression, SmallestSize)
  • Default: Fastest
  • Scope: Server-wide only
  • Used for setting Kestrel property: Level

Http.StaticFilesResponseCompressionLevel

Set the compression level to be used when compressing static files.

  • Type: enum CompressionLevel (Optimal, Fastest, NoCompression, SmallestSize)
  • Default: Optimal
  • Scope: Server-wide only

Http.Protocols

  • Set HTTP protocols that should be supported by the server.

  • By default, the HTTP protocol is set by the constructor of class HttpConfiguration
    (that is what is meant by the value "DefaultValueSetInConstructor").

  • If the platform running RavenDB is either Windows 10 or higher, Windows Server 2016 or newer, or POSIX,
    the constructor sets Http.Protocols to Http1AndHttp2. Otherwise, it is set to Http1.


  • Type: enum HttpProtocols ( None, Http1, Http2, Http1AndHttp2, Http3, Http1AndHttp2AndHttp3)
  • Default: DefaultValueSetInConstructor
  • Scope: Server-wide only

Http.AllowSynchronousIO

Set a value that controls whether synchronous IO is allowed for the Request and Response.

  • Type: bool
  • Default: false
  • Scope: Server-wide only
  • Used for setting Kestrel property: AllowSynchronousIO