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

[ENHANCEMENT] TSDB: Allow to stop waiting for pending queries #14088

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

bboreham
Copy link
Member

If queries take a very long time to finish, perhaps because something has gone wrong, we would prefer operations like `Compact()`` to be interruptible so we can shut down cleanly.

If queries take a very long time to finish, perhaps because something
has gone wrong, we would prefer operations like `Compact()`` to be
interruptible so we can shut down cleanly.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
@bboreham bboreham marked this pull request as draft May 13, 2024 11:15
Copy link
Member

@jesusvazquez jesusvazquez left a comment

Choose a reason for hiding this comment

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

LGTM so far Bryan 👀

@@ -1082,7 +1082,7 @@ func (h *Head) SetMinValidTime(minValidTime int64) {
// Truncate removes old data before mint from the head and WAL.
func (h *Head) Truncate(mint int64) (err error) {
Copy link
Member

Choose a reason for hiding this comment

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

Is there a reason why you did not pass the context here as well?

Copy link
Member Author

Choose a reason for hiding this comment

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

Mainly I couldn't see where this was called except from reload, where we don't seem to have a useful context.
But I can add it for consistency.

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.

None yet

2 participants