This repository has been archived by the owner on Jun 13, 2023. It is now read-only.
Add support for an attempt to connect to existing Queue on API side to reduce slow requests number #35
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
problem
The very first request to Queue API is slow due to sending a list of test files from the disk. The bigger the test files list the slower is request. For a few thousand test files it can take 1+ second.
When a lot of requests from parallel CI nodes starting at the same time hit the Knapsack Pro API this can lead to slower performance of the API because requests with a list of test files can be slow. This leads to compound effect and degradation of API performance for very large projects using ~100+ parallel CI nodes.
solution
Thanks to the above we can significantly reduce the number of slow requests and make the overall API more stable.
Related to PR
KnapsackPro/knapsack_pro-ruby#133