Table of Contents

Class ConnectionStoreOptions

Namespace
Virtufin.WebSocketManager.Configuration
Assembly
Virtufin.WebSocketManager.dll

Tuning for connection record state-store TTL. The WSM sets a Dapr ttlInSeconds on every connection record write. ConnectionHeartbeatService refreshes it for every locally-owned, connected connection every TTL/3 seconds (floored at 10s), independent of send traffic; a successful Send/SendRaw also refreshes it as a side effect. Records whose TTL elapses (e.g. a pod that died without a clean disconnect, so nothing is heartbeating them anymore) are removed by the state store without explicit reclaimer intervention.

public sealed record ConnectionStoreOptions : IEquatable<ConnectionStoreOptions>
Inheritance
ConnectionStoreOptions
Implements
Inherited Members

Fields

ConnectionRecordTtlSecondsEnvVar

public const string ConnectionRecordTtlSecondsEnvVar = "CONNECTION_RECORD_TTL_SECONDS"

Field Value

string

DefaultConnectionRecordTtlSeconds

Default connection record TTL (5 minutes).

public const int DefaultConnectionRecordTtlSeconds = 300

Field Value

int

MaxConnectionRecordTtlSeconds

Maximum allowed TTL in seconds. Upper bound to keep state growth bounded if the reclaimer sweep is disabled.

public const int MaxConnectionRecordTtlSeconds = 3600

Field Value

int

MinConnectionRecordTtlSeconds

Minimum allowed TTL in seconds. Lower bound to keep connections from disappearing during normal long-polling activity.

public const int MinConnectionRecordTtlSeconds = 30

Field Value

int

Properties

ConnectionRecordTtlSeconds

Connection record TTL in seconds.

public int ConnectionRecordTtlSeconds { get; init; }

Property Value

int

Methods

FromEnvironment(Func<string, string?>)

public static ConnectionStoreOptions FromEnvironment(Func<string, string?> getEnvironment)

Parameters

getEnvironment Func<string, string>

Returns

ConnectionStoreOptions