Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

POC: Setting thread affinity on indexer threads #2152

Open
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

ChillFish8
Copy link
Contributor

Recently I wanted to test some smarter ways of balancing a large number of indexers in a multi-tenant situation without affecting searchers and decided to test out specifying specifically what CPU set the indexers could run on, giving searchers their own unaffected CPU set.

This is mostly an idea rather than a super useful feature, I've not included specifying the searcher CPU set as I'm not sure the best way to implement that in a way that doesn't result in extra calls when it doesn't need to be (i.e. SingleThreaded)

@fulmicoton
Copy link
Collaborator

Have you measured a benefit?

@ChillFish8
Copy link
Contributor Author

@fulmicoton I have yet to get around to testing the general performance change this has, I wanted this particular feature to allow some better control over the indexing threads preventing indexers from interfering with searchers since tantivy spawns its own set of threads internally unlike the searchers.

The main advantage of this change is that you could spawn say 30 indexers all using 1 thread but constrain them to 6 CPU cores letting the OS load balance the indexers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants