-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Do /metrics/find queries in parallel #1072
Do /metrics/find queries in parallel #1072
Conversation
Based on what was done to fetchData() in graphite-project#1026
We've got to cut off any more commits to |
fwiw, I still think using a threadpool makes the code easier to read: These would do mostly the same as the current PR, but with much less boiler plate code. (if we remove all the if USE_THREAD stuff) |
I'd also really like to see this against master |
As I've said in another thread a few month ago, we don't currently have an environment to test master, but we do have multiple 0.9.x clusters... So for the short term, I'm not sure I'll be able to help with forward porting this kind of patches to master. As for the performance, with a 10 node cluster where 4 nodes are 80ms away from the cluster head, the original code takes ~400ms to return results for a Regarding the commit cutoff to 0.9.x, I'm currently updating our fork to the latest code (with threads), and I planned to cleanup my prefetch cache patch from issue #1045 since, in our case, using that patch makes queries with multiple targets more than twice as fast. |
After |
What are your thoughts on merging this into 0.9.x @obfuscurity? |
@SEJeff I'm an idiot when it comes to threaded Python (or any threaded code, tbh) but if it looks ok to you, I'm ok with it being merged. |
Didn't test it on our clusters (because of vacations and production freeze), but looks perfectly legit to merge (and complement to #1026). 👍 |
This also looks fine to me, though I haven't tested it. It closely follows the pattern in #1026. |
Do /metrics/find queries in parallel
Based on what was done to fetchData() in #1026.
/metrics/find/
queries are used less often since #1010 went in, but the composer still uses them.This makes browsing metrics through the composer much less painful :-)
The code has been very lightly tested (it is December 30th code after all), but it works on a 10 node cluster.
cc @bmhatfield