-
Notifications
You must be signed in to change notification settings - Fork 151
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
Reduce size of pods_selector by using replica prefixes #67
Conversation
Signed-off-by: Megrez Lu <lujiajing1126@gmail.com>
Hello and sorry for long time waiting on response :) We've been working a lot with performance issues and also trying your solution. It resulted in using even more memory load on prometheus to execute that query, as well as longer loading time. Additionally, I've been thinging on fully rewriting regex to fully utilize the format for pod names, but there is a concern that there might be special cases where it fails. In any case thank you so much for the PR, I will keep it for reference and will close it as soon as we have a solution that satisfies everyone |
I am closing this PR as #97 should have fixed the issue Still, reopen it if you feel like it improves anything else, but I will keep this possibility in mind in any case Thank you very much for participating in a project ❤️ |
I've tested this solution on VictoriaMetrics (a cluster w/ 4 vmstorage), but it failed to return data and throws timeout. Probably it is too complicated. I don't know if anyone else can make another test.
Sure. I forgot to mention this. We've modified site-package to make use of POST. But besides that, I would like to remind (for VM users) that
The maximum query length is 16KiB. So we still have a limit even for POST. |
Closes #60, #62, #66
This PR intends to reduce the size of pod_selector, by picking the
<deployment>-<pod-template-hash>
as the prefix.This could significantly reduce the size of the querystring in the case that there are hundreds of pods for a single deployment.
300
may be a magic number here:pod-template-hash
normally contains 8 bytes, with 5 chars pod hash. The default max http header that nginx can accept is ~4K, so with >300 pods it must exceed the threshold.