跳转到内容
简体中文

TcpSocketOptionsBuilder

此内容尚不支持你的语言。

Defined in: src/io/broker/TcpSocketOptions.ts:30

new TcpSocketOptionsBuilder(): TcpSocketOptionsBuilder

TcpSocketOptionsBuilder

BrokerOptionsBuilder<TcpSocketOptionsType>.constructor

build(): Partial<T>

Defined in: src/util/OptionsBuilder.ts:51

Snapshot the set fields as an independent Partial<T> (own props only).

Partial<T>

BrokerOptionsBuilder.build


withCircuitBreaker(failureThreshold, resetMs): this

Defined in: src/io/broker/BrokerOptions.ts:125

Circuit breaker around connect attempts.

number

number

this

BrokerOptionsBuilder.withCircuitBreaker


withFraming(framing): this

Defined in: src/io/broker/TcpSocketOptions.ts:47

Frame extraction strategy. Default { kind: 'bytes' }.

TcpFraming

this


withHost(host): this

Defined in: src/io/broker/TcpSocketOptions.ts:37

Remote host.

string

this


withOutboundBuffer(limit): this

Defined in: src/io/broker/BrokerOptions.ts:130

Outbound buffer size (messages held while disconnected). Default 1000; 0 = fail-fast.

number

this

BrokerOptionsBuilder.withOutboundBuffer


withPort(port): this

Defined in: src/io/broker/TcpSocketOptions.ts:42

Remote port.

number

this


withReconnect(policy): this

Defined in: src/io/broker/BrokerOptions.ts:120

Reconnect policy (or false to disable auto-reconnect).

false | { factor?: number; initialDelayMs?: number; maxAttempts?: number; maxDelayMs?: number; } | undefined

false


{ factor?: number; initialDelayMs?: number; maxAttempts?: number; maxDelayMs?: number; }

number

number

number

Cap on retry attempts. Default: Infinity (retry forever).

number


undefined

this

BrokerOptionsBuilder.withReconnect


withTarget(target): this

Defined in: src/io/broker/TcpSocketOptions.ts:52

Subscriber that receives every inbound frame. Required.

ActorRef<unknown>

this


static create(): TcpSocketOptionsBuilder

Defined in: src/io/broker/TcpSocketOptions.ts:32

Start a fresh builder. Equivalent to new TcpSocketOptionsBuilder().

TcpSocketOptionsBuilder