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

statistics/histogram: init histogram #2331

Merged
merged 14 commits into from Sep 26, 2017

Conversation

Projects
None yet
4 participants
Show outdated Hide outdated src/coprocessor/statistics/histogram.rs Outdated
Show outdated Hide outdated src/coprocessor/statistics/histogram.rs Outdated
Show outdated Hide outdated src/coprocessor/statistics/histogram.rs Outdated
Show outdated Hide outdated src/coprocessor/statistics/histogram.rs Outdated
Show outdated Hide outdated src/coprocessor/statistics/histogram.rs Outdated
Show outdated Hide outdated src/coprocessor/statistics/histogram.rs Outdated
Show outdated Hide outdated src/coprocessor/statistics/histogram.rs Outdated
Show outdated Hide outdated src/coprocessor/statistics/histogram.rs Outdated
Show outdated Hide outdated src/coprocessor/statistics/histogram.rs Outdated
Show outdated Hide outdated src/coprocessor/statistics/histogram.rs Outdated
Show outdated Hide outdated src/coprocessor/statistics/histogram.rs Outdated
Show outdated Hide outdated src/coprocessor/statistics/histogram.rs Outdated
Show outdated Hide outdated src/coprocessor/statistics/histogram.rs Outdated
Show outdated Hide outdated src/coprocessor/statistics/histogram.rs Outdated
}
// It merges every two neighbor buckets.
fn merge_buckets(&mut self) {

This comment has been minimized.

@BusyJay

BusyJay Sep 25, 2017

Contributor

Do we need to check if self.buckets_num > 1?

@BusyJay

BusyJay Sep 25, 2017

Contributor

Do we need to check if self.buckets_num > 1?

This comment has been minimized.

@AndreMouche

AndreMouche Sep 26, 2017

Member

address comments

@AndreMouche

AndreMouche Sep 26, 2017

Member

address comments

left[id].repeats = right[1].repeats;
}
self.buckets.drain(bucket_num..);
self.per_bucket_limit *= 2;

This comment has been minimized.

@hicqu

hicqu Sep 26, 2017

Contributor

If self.buckets_num == 1, merge will causes per_bucket_limit * 2 instead of no effect. Is it expected?

@hicqu

hicqu Sep 26, 2017

Contributor

If self.buckets_num == 1, merge will causes per_bucket_limit * 2 instead of no effect. Is it expected?

This comment has been minimized.

@AndreMouche
@AndreMouche

AndreMouche Sep 26, 2017

Member

yes @hicqu

@hicqu

This comment has been minimized.

Show comment
Hide comment
@hicqu

hicqu Sep 26, 2017

Contributor

rest LGTM.

Contributor

hicqu commented Sep 26, 2017

rest LGTM.

@hicqu

hicqu approved these changes Sep 26, 2017

@BusyJay

This comment has been minimized.

Show comment
Hide comment
@BusyJay

BusyJay Sep 26, 2017

Contributor

LGTM

Contributor

BusyJay commented Sep 26, 2017

LGTM

@AndreMouche AndreMouche merged commit 104bfd5 into master Sep 26, 2017

3 checks passed

ci/circleci Your tests passed on CircleCI!
Details
jenkins-ci-tikv/build Jenkins job succeeded.
Details
license/cla Contributor License Agreement is signed.
Details

@AndreMouche AndreMouche deleted the shirly/histogram branch Sep 26, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment