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

query/api: properly pass downsampling param #1144

Merged
merged 2 commits into from
May 15, 2019

Conversation

GiedriusS
Copy link
Member

As compact.ResolutionLevel{Raw,5m,1h} says the resolution levels are
expressed in milliseconds. Currently, parseDownsamplingParam() calls
parseDuration() and friends which express this value in nanoseconds.
Thus, we need to divide the value by 1000*1000 to have them in
milliseconds.

Add test cases to check all of this.

As compact.ResolutionLevel{Raw,5m,1h} says the resolution levels are
expressed in milliseconds. Currently, parseDownsamplingParam() calls
parseDuration() and friends which express this value in nanoseconds.
Thus, we need to divide the value by 1000*1000 to have them in
milliseconds.

Add test cases to check all of this.
@brancz
Copy link
Member

brancz commented May 15, 2019

this lgtm, but we should note this change in the changelog

Copy link
Member

@povilasv povilasv left a comment

Choose a reason for hiding this comment

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

Please add changelog, nice job on tests! 🎖️

@brancz brancz merged commit 7a767ef into thanos-io:master May 15, 2019
@bwplotka
Copy link
Member

bwplotka commented May 15, 2019

Wow 😱

@bwplotka
Copy link
Member

I think we should close like at least 3 tickets mentioning that choosing downsampling does not always work ;p

@bwplotka
Copy link
Member

bwplotka commented May 16, 2019

This is wrong change IMO - the time is being divided to match miliseconds further down in stack ): And we are trying to somehow adjust unit in vatiable with unit agnostic type - time.Duration ):

Hopefully we are on it here: #1146

Consequence is that downsampling is technically never working now.

Should we revert this maybe? Unless I am wrong @GiedriusS (:

bwplotka added a commit that referenced this pull request May 16, 2019
This reverts commit 7a767ef.

# Conflicts:
#	CHANGELOG.md
bwplotka added a commit that referenced this pull request May 17, 2019
This reverts commit 7a767ef.

# Conflicts:
#	CHANGELOG.md
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.

4 participants