connectInQueue
connectInQueue(
gateway,shardId,gate,options?):Promise<boolean>
Defined in: packages/sharding/src/index.ts:177
Connects one shard inside the IDENTIFY queue: takes a slot, connects, and
gives the slot back once the IDENTIFY is sent, or, with waitForReady
(sequential startup), once the shard is READY. The slot is always released,
also when connecting fails.
Parameters
Section titled “Parameters”gateway
Section titled “gateway”shardId
Section titled “shardId”number
options?
Section titled “options?”cancelled?
Section titled “cancelled?”() => boolean
Checked after the slot is granted: true skips connecting (a stale start).
handshakeTimeout?
Section titled “handshakeTimeout?”number
readyTimeout?
Section titled “readyTimeout?”number
waitForReady?
Section titled “waitForReady?”boolean
Returns
Section titled “Returns”Promise<boolean>
Whether the shard became READY in time (true without waitForReady).