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

scrape: use locks when shutting down the loops #122

Conversation

ridwanmsharif
Copy link
Collaborator

Is rebased on top of #118

This change uses locks in the shutdown path

This config option is quite useful on serverless environments where
we are sensitive to the start up latencies of the scraper. The
serverless instance might only last for a few seconds and may not be
able to afford the minimum 5s reload interval before the scrape pools
are created.

Signed-off-by: Ridwan Sharif <ridwanmsharif@google.com>
This change adds an option that will allow users to skip the initial
wait before sending target sets to the scrape manager. This is
particularly useful in environments where the startup latency is
required to be low just as in serverless deployments.

Signed-off-by: Ridwan Sharif <ridwanmsharif@google.com>
@bwplotka
Copy link
Collaborator

This might work, but proposed some small update after research, WDYT? #123

@bwplotka
Copy link
Collaborator

OK, cleaned up version is not fully working on discovery without wait feature, so let's merge this one in as it's similar semantically (this PR should work too). We can then iterate on cleanup and better way to avoid initial wait on discovery later.

@bwplotka bwplotka merged commit b918f74 into GoogleCloudPlatform:feature/shutdownscrape Nov 22, 2023
17 of 18 checks passed
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.

2 participants