port 4000 on cluster

so my bot is in more than 8k servers and it requires clustering so when i start the bot i get this Error: listen EADDRINUSE: address already in use :::4000 i dont want to use any ports at all
Solution:
In your API options in client options set automaticallyConnect to false and then in some event like ready or similar start it just once and on one shard by calling client.server.start
Jump to solution
2 Replies
Solution
Favna
Favna2y ago
In your API options in client options set automaticallyConnect to false and then in some event like ready or similar start it just once and on one shard by calling client.server.start
Favna
Favna2y ago
Sapphire Framework
Starting on a single cluster or shard | Sapphire
Once your bot grows to a lot of servers, you will want to implement sharding, process clustering, or another form of
Want results from more Discord servers?
Add your server