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

[coordinator] Add mapping rule config support for keeping metrics at different resolutions #2036

Merged
merged 27 commits into from
Jan 3, 2020
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
2d0a0a4
Add mapping rule and rollup rule config support
robskillington Nov 3, 2019
83727d9
Add config ability
robskillington Nov 4, 2019
c5022de
Merge branch 'master' into r/mapping-rule-rollup-rule-config-support
robskillington Nov 4, 2019
0017ede
Address feedback
robskillington Nov 14, 2019
7f8862e
Add mapping rule and rollup rule config support
robskillington Nov 3, 2019
863851a
Add config ability
robskillington Nov 4, 2019
72c5683
Address feedback
robskillington Nov 14, 2019
25c4760
Fix downsampler not using in mem store if using config for rollup/map…
robskillington Nov 14, 2019
4fe4c06
[WIP] Add tests
benraskin92 Nov 15, 2019
033dc0b
Create namespace first
robskillington Nov 15, 2019
7a50808
Merge branch 'r/mapping-rule-rollup-rule-config-support' of github.co…
robskillington Nov 15, 2019
2da1b2f
Add unit tests and update integration test
robskillington Jan 2, 2020
8fc40db
Restore integration test runs
robskillington Jan 2, 2020
827d58d
Merge branch 'master' into r/mapping-rule-rollup-rule-config-support
robskillington Jan 2, 2020
06ebbbe
Fix tests
robskillington Jan 2, 2020
11c654d
Use Go 1.13 for docker integration tests
robskillington Jan 2, 2020
4d27c03
Address feedback
robskillington Jan 2, 2020
1c65e49
Fix codegen CI failures
robskillington Jan 2, 2020
9824631
Add long namespaces to integration test
benraskin92 Jan 3, 2020
6bdfc23
Merge branch 'r/mapping-rule-rollup-rule-config-support' of github.co…
benraskin92 Jan 3, 2020
5a4ffd2
Remove imports from restrict.go
arnikola Jan 3, 2020
ed335f4
Update end time and jq
benraskin92 Jan 3, 2020
ec5ee86
Merge branch 'r/mapping-rule-rollup-rule-config-support' of github.co…
benraskin92 Jan 3, 2020
0f1e48f
Merge branch 'master' into r/mapping-rule-rollup-rule-config-support
robskillington Jan 3, 2020
4476d55
Updates
benraskin92 Jan 3, 2020
33cdac6
Merge branch 'r/mapping-rule-rollup-rule-config-support' of github.co…
benraskin92 Jan 3, 2020
c623742
Address feedback
robskillington Jan 3, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/cmd/services/m3coordinator/downsample/downsampler.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ type SampleAppenderOptions struct {
// use instead of matching against default and dynamic matched rules
// for an ID.
type SamplesAppenderOverrideRules struct {
MappingRules []MappingRule
MappingRules []AutoMappingRule
}

// SamplesAppender is a downsampling samples appender,
Expand Down
14 changes: 7 additions & 7 deletions src/cmd/services/m3coordinator/downsample/downsampler_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,10 @@ import (
"github.com/m3db/m3/src/x/pool"
"github.com/m3db/m3/src/x/serialize"

"go.uber.org/zap"
"github.com/golang/mock/gomock"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
"go.uber.org/zap"
)

var (
Expand All @@ -66,7 +66,7 @@ const (

func TestDownsamplerAggregationWithAutoMappingRules(t *testing.T) {
testDownsampler := newTestDownsampler(t, testDownsamplerOptions{
autoMappingRules: []MappingRule{
autoMappingRules: []AutoMappingRule{
{
Aggregations: []aggregation.Type{testAggregationType},
Policies: testAggregationStoragePolicies,
Expand Down Expand Up @@ -130,7 +130,7 @@ func TestDownsamplerAggregationWithRulesStore(t *testing.T) {
func TestDownsamplerAggregationWithTimedSamples(t *testing.T) {
testDownsampler := newTestDownsampler(t, testDownsamplerOptions{
timedSamples: true,
autoMappingRules: []MappingRule{
autoMappingRules: []AutoMappingRule{
{
Aggregations: []aggregation.Type{testAggregationType},
Policies: testAggregationStoragePolicies,
Expand All @@ -147,7 +147,7 @@ func TestDownsamplerAggregationWithOverrideRules(t *testing.T) {
sampleAppenderOpts: &SampleAppenderOptions{
Override: true,
OverrideRules: SamplesAppenderOverrideRules{
MappingRules: []MappingRule{
MappingRules: []AutoMappingRule{
{
Aggregations: []aggregation.Type{aggregation.Mean},
Policies: []policy.StoragePolicy{
Expand All @@ -161,7 +161,7 @@ func TestDownsamplerAggregationWithOverrideRules(t *testing.T) {
"gauge0": 5.0,
"counter0": 2.0,
},
autoMappingRules: []MappingRule{
autoMappingRules: []AutoMappingRule{
{
Aggregations: []aggregation.Type{testAggregationType},
Policies: testAggregationStoragePolicies,
Expand All @@ -182,7 +182,7 @@ func TestDownsamplerAggregationWithRemoteAggregatorClient(t *testing.T) {
remoteClientMock.EXPECT().Init().Return(nil)

testDownsampler := newTestDownsampler(t, testDownsamplerOptions{
autoMappingRules: []MappingRule{
autoMappingRules: []AutoMappingRule{
{
Aggregations: []aggregation.Type{testAggregationType},
Policies: testAggregationStoragePolicies,
Expand Down Expand Up @@ -460,7 +460,7 @@ type testDownsamplerOptions struct {
instrumentOpts instrument.Options

// Options for the test
autoMappingRules []MappingRule
autoMappingRules []AutoMappingRule
timedSamples bool
sampleAppenderOpts *SampleAppenderOptions
remoteClientMock *client.MockClient
Expand Down
Loading