Search Results for

    Show / Hide Table of Contents

    Class ProxyTimeoutOptions

    Immutable, validated snapshot of every deadline the proxy enforces across a request's lifetime, expressed consistently as TimeSpan rather than the mixture of "seconds as int" properties this replaces (ConnectionTimeOutSeconds, ConnectTimeOutSeconds, ...). A deadline that can be legitimately unbounded is nullable, with null meaning "no deadline" as an explicit state rather than Zero or a magic sentinel duration.

    This type only holds values; it does not decide which deadline fired first when several are composed for one request. That is the responsibility of the per-request deadline registry described in the plan's "Deadline composition" section, introduced alongside the header-parsing deadlines in a later item so it can be exercised by a real caller instead of landing as unused scaffolding.

    Inheritance
    object
    ProxyTimeoutOptions
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Titanium.Web.Proxy.Options
    Assembly: Titanium.Web.Proxy.dll
    Syntax
    public sealed class ProxyTimeoutOptions

    Properties

    | Edit this page View Source

    CallbackTimeout

    Deadline after which a user callback (BeforeRequest, BeforeResponse, etc.) that has not returned is abandoned and reported as orphaned. null means callbacks are never timed out - not recommended, since .NET cannot forcibly stop an uncooperative callback and this is the only backstop against one hanging a connection indefinitely.

    Declaration
    public TimeSpan? CallbackTimeout { get; }
    Property Value
    Type Description
    TimeSpan?
    | Edit this page View Source

    ClientHeaderTimeout

    Deadline for a client to finish sending the request line and headers.

    Declaration
    public TimeSpan ClientHeaderTimeout { get; }
    Property Value
    Type Description
    TimeSpan
    | Edit this page View Source

    ConnectTimeout

    Deadline for establishing the upstream TCP (and TLS, where applicable) connection.

    Declaration
    public TimeSpan ConnectTimeout { get; }
    Property Value
    Type Description
    TimeSpan
    | Edit this page View Source

    Default

    Today's shipped values, carried forward per the plan's rollout section: 60-second connection timeout, 20-second connect timeout. Deadlines newly introduced by the hardening plan (client-header, response-header, callback, drain, stream, total-request) are set to conservative values pending benchmark-driven tuning.

    Declaration
    public static ProxyTimeoutOptions Default { get; }
    Property Value
    Type Description
    ProxyTimeoutOptions
    | Edit this page View Source

    DrainTimeout

    Deadline for draining a connection's in-flight work during an orderly shutdown.

    Declaration
    public TimeSpan DrainTimeout { get; }
    Property Value
    Type Description
    TimeSpan
    | Edit this page View Source

    IdleReadTimeout

    Deadline for a single read to make forward progress once a connection is established.

    Declaration
    public TimeSpan IdleReadTimeout { get; }
    Property Value
    Type Description
    TimeSpan
    | Edit this page View Source

    IdleWriteTimeout

    Deadline for a single write to make forward progress once a connection is established.

    Declaration
    public TimeSpan IdleWriteTimeout { get; }
    Property Value
    Type Description
    TimeSpan
    | Edit this page View Source

    ResponseHeaderTimeout

    Deadline for the origin to finish sending the response status line and headers.

    Declaration
    public TimeSpan ResponseHeaderTimeout { get; }
    Property Value
    Type Description
    TimeSpan
    | Edit this page View Source

    StreamTimeout

    Deadline for a single HTTP/2 or HTTP/3 stream to complete once opened. null disables the per-stream deadline.

    Declaration
    public TimeSpan? StreamTimeout { get; }
    Property Value
    Type Description
    TimeSpan?
    | Edit this page View Source

    TotalRequestTimeout

    Deadline for an entire request/response exchange, end to end. null disables the total-request deadline.

    Declaration
    public TimeSpan? TotalRequestTimeout { get; }
    Property Value
    Type Description
    TimeSpan?

    Methods

    | Edit this page View Source

    Create(TimeSpan, TimeSpan, TimeSpan, TimeSpan, TimeSpan, TimeSpan?, TimeSpan, TimeSpan?, TimeSpan?)

    Validates and constructs a ProxyTimeoutOptions snapshot. Every supplied duration - including a nullable one, when present - must be strictly positive.

    Declaration
    public static ProxyTimeoutOptions Create(TimeSpan clientHeaderTimeout, TimeSpan connectTimeout, TimeSpan responseHeaderTimeout, TimeSpan idleReadTimeout, TimeSpan idleWriteTimeout, TimeSpan? callbackTimeout, TimeSpan drainTimeout, TimeSpan? streamTimeout, TimeSpan? totalRequestTimeout)
    Parameters
    Type Name Description
    TimeSpan clientHeaderTimeout
    TimeSpan connectTimeout
    TimeSpan responseHeaderTimeout
    TimeSpan idleReadTimeout
    TimeSpan idleWriteTimeout
    TimeSpan? callbackTimeout
    TimeSpan drainTimeout
    TimeSpan? streamTimeout
    TimeSpan? totalRequestTimeout
    Returns
    Type Description
    ProxyTimeoutOptions
    Exceptions
    Type Condition
    ArgumentOutOfRangeException

    A supplied duration is zero or negative.

    • Edit this page
    • View Source
    In this article
    Back to top Generated by DocFX