Skip to content

AgentOptions

[<Interface>]
type AgentOptions =
    abstract member agentKeepAliveTimeoutBuffer: float option with get, set
    abstract member keepAliveMsecs: float option with get, set
    abstract member maxFreeSockets: float option with get, set
    abstract member maxSockets: float option with get, set
    abstract member maxTotalSockets: float option with get, set
    abstract member scheduling: Scheduling option with get, set
    abstract member timeout: float option with get, set
    static member Create (?keepAlive: bool, ?keepAliveMsecs: float, ?agentKeepAliveTimeoutBuffer: float, ?maxSockets: float, ?maxTotalSockets: float, ?maxFreeSockets: float, ?timeout: float, ?scheduling: Scheduling, ?port: float, ?host: string, ?localAddress: string, ?localPort: float, ?hints: float, ?family: float, ?lookup: LookupFunction, ?noDelay: bool, ?keepAliveInitialDelay: float, ?autoSelectFamily: bool, ?autoSelectFamilyAttemptTimeout: float, ?blockList: BlockList) : AgentOptions
AssemblyXantham.Fable.Node
ImplementsBase
Attributes[<Interface>]

Declared inside

Base
Scheduling

Properties

abstract member agentKeepAliveTimeoutBuffer: float option with get, set

Milliseconds to subtract from the server-provided keep-alive: timeout=... hint when determining socket expiration time. This buffer helps ensure the agent closes the socket slightly before the server does, reducing the chance of sending a request on a socket that’s about to be closed by the server.

@since v22.20.0

abstract member keepAliveMsecs: float option with get, set

When using HTTP KeepAlive, how often to send TCP KeepAlive packets over sockets being kept alive. Default = 1000. Only relevant if keepAlive is set to true.

abstract member maxFreeSockets: float option with get, set

Maximum number of sockets to leave open in a free state. Only relevant if keepAlive is set to true. Default = 256.

abstract member maxSockets: float option with get, set

Maximum number of sockets to allow per host. Default for Node 0.10 is 5, default for Node 0.12 is Infinity

abstract member maxTotalSockets: float option with get, set

Maximum number of sockets allowed for all hosts in total. Each request will use a new socket until the maximum is reached. Default: Infinity.

abstract member scheduling: Scheduling option with get, set

Scheduling strategy to apply when picking the next free socket to use.

abstract member timeout: float option with get, set

Socket timeout in milliseconds. This will set the timeout after the socket is connected.

Methods

static member Create (?keepAlive: bool, ?keepAliveMsecs: float, ?agentKeepAliveTimeoutBuffer: float, ?maxSockets: float, ?maxTotalSockets: float, ?maxFreeSockets: float, ?timeout: float, ?scheduling: Scheduling, ?port: float, ?host: string, ?localAddress: string, ?localPort: float, ?hints: float, ?family: float, ?lookup: LookupFunction, ?noDelay: bool, ?keepAliveInitialDelay: float, ?autoSelectFamily: bool, ?autoSelectFamilyAttemptTimeout: float, ?blockList: BlockList) : AgentOptions