How to run recommended ("auto") shard count all in one thread?

As far as I can tell, the shard manager is always either multi-process or multi-threaded. But I can't find any other way to run multiple shards, so I'm not sure how to do that in a single thread.
7 Replies
d.js toolkit
d.js toolkit3mo ago
- What's your exact discord.js npm list discord.js and node node -v version? - Not a discord.js issue? Check out #other-js-ts. - Consider reading #how-to-get-help to improve your question! - Explain what exactly your issue is. - Post the full error stack trace, not just the top part! - Show your code! - Issue solved? Press the button! - Marked as resolved by OP
ElJay
ElJayOP3mo ago
To explain why I want to do this, I have a small shard count that doesn't require multiple threads. And I would like to avoid the overhead and restrictions that come with multiple threads.
monbrey
monbrey3mo ago
Just use internal sharding without the sharding manager
ElJay
ElJayOP3mo ago
How do I do that? I wasn't able to spot a client option
monbrey
monbrey3mo ago
How small are we talking? How many guilds are you managing
d.js docs
d.js docs3mo ago
:propertysignature: ClientOptions#shards @14.16.3 The shard's id to run, or an array of shard ids. If not specified, the client will spawn shardCount shards. If set to auto, it will fetch the recommended amount of shards from Discord and spawn that amount
ElJay
ElJayOP3mo ago
ah I guess I'm blind, thanks
Want results from more Discord servers?
Add your server