StackExchange / StackExchange/StackExchange.Redis
[Question] Is it possible to limit client connections to a shard?
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 6.2k
- Forks
- 1.6k
- Avg merge
- 1d 15h
- Merged PRs (30d)
- 43
Description
Hey!
I have a MemoryDB cluster consisting of two shards, I noticed that when connecting to it a connection is established with all the nodes in this cluster (both shards/all nodes), the problem with that is it creates a connection with nodes that it will never interact with because each client will only be able to access a subset of keys residing in a single shard (using hashtags).
Is there a way to make the client only connect to a single shard or a subset of nodes within this shard ( I have a lot of clients so I want to distribute their connections).
To give more context I am running into the limitation of 64k connections per node so I want clients to connect to the least needed amount of nodes.
Thanks!
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue names no repository files, tests, or entry points. Start by tracing how StackExchange.Redis discovers and opens connections for a MemoryDB cluster, then determine whether shard- or node-limited connections are supported. Done means a clear documented answer or a well-scoped implementation plan for reducing unnecessary connections.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp, redis
- Domain
- databases
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100