mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-17 03:53:29 +01:00
feat(ws): metrics (#9005)
* feat(WebSocketManager): fetch status * feat(WebSocketShard): heartbeat event * chore: ci Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
This commit is contained in:
@@ -70,4 +70,11 @@ export class SimpleShardingStrategy implements IShardingStrategy {
|
||||
if (!shard) throw new Error(`Shard ${shardId} not found`);
|
||||
return shard.send(payload);
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritDoc IShardingStrategy.fetchStatus}
|
||||
*/
|
||||
public async fetchStatus() {
|
||||
return this.shards.mapValues((shard) => shard.status);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user