Skip to content
This repository has been archived by the owner on Feb 12, 2024. It is now read-only.

feat: randomly pick preload node #2194

Merged
merged 2 commits into from
Jun 28, 2019
Merged

Conversation

alanshaw
Copy link
Member

This PR updates the preloader to randomly pick a node when preloading data.

It actually shuffles the list of available preload nodes for every preload
request, and works its way through. This helps spread the load between available
preload nodes.

It also updates the tests to disable preload where it's not needed.

refs #2155 (comment)
closes #1819
resolves #1815

@alanshaw alanshaw requested a review from lidel June 24, 2019 11:24
Copy link
Contributor

@dirkmc dirkmc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

alanshaw and others added 2 commits June 28, 2019 00:15
This PR updates the preloader to randomly pick a node when preloading data.

It actually shuffles the list of _available_ preload nodes for every preload
request, and works its way through. This helps spread the load between available
preload nodes.

License: MIT
Signed-off-by: Alan Shaw <alan@tableflip.io>
License: MIT
Signed-off-by: Alan Shaw <alan.shaw@protocol.ai>
@alanshaw alanshaw force-pushed the feat/random-preload-selection branch from 57eab30 to 6d81d08 Compare June 27, 2019 22:15
@alanshaw alanshaw mentioned this pull request Jun 27, 2019
54 tasks
@alanshaw alanshaw merged commit f596b01 into master Jun 28, 2019
@alanshaw alanshaw deleted the feat/random-preload-selection branch June 28, 2019 06:04
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Disable preloading in test environments
2 participants