From cf419d1cb83f4664c2298abe1ee41bfbfab98710 Mon Sep 17 00:00:00 2001 From: Dylan Guedes Date: Wed, 2 Feb 2022 18:11:11 -0300 Subject: [PATCH] Implement `LegacySample`, `LegacyLabelPair` proto messages (#5301) * Add LegacySample and modify protos to use it. * [Skip this commit] Regenerate protos. * Modify codebase to use LegacySample instead of Sample. For reference, take a look at PR https://github.com/grafana/loki/pull/5151. * Implement LegacyLabelPair. * Use new Legacy implementations accordingly. * Use LegacySample in compat tests. - Since `compat.go` was forked from Cortex, we can reliably change all mentions from `Sample` to `LegacySample` there. --- pkg/ingester/checkpoint.pb.go | 68 +- pkg/ingester/checkpoint.proto | 2 +- pkg/ingester/client/ingester.pb.go | 122 +-- pkg/ingester/client/ingester.proto | 2 +- pkg/logproto/compat.go | 36 +- pkg/logproto/compat_test.go | 14 +- pkg/logproto/logproto.pb.go | 720 +++++++++++++++--- pkg/logproto/logproto.proto | 10 + pkg/logproto/metrics.pb.go | 89 +-- pkg/logproto/metrics.proto | 6 +- pkg/logproto/timeseries.go | 2 +- pkg/logproto/timeseries_test.go | 2 +- .../base/distributor_queryable_test.go | 48 +- pkg/querier/base/duplicates_test.go | 54 +- pkg/querier/base/timeseries_series_set.go | 4 +- .../base/timeseries_series_set_test.go | 26 +- pkg/querier/queryrange/codec.go | 14 +- pkg/querier/queryrange/codec_test.go | 12 +- pkg/querier/queryrange/downstreamer.go | 4 +- pkg/querier/queryrange/downstreamer_test.go | 28 +- pkg/querier/queryrange/prometheus.go | 2 +- pkg/querier/queryrange/prometheus_test.go | 20 +- .../queryrangebase/marshaling_test.go | 8 +- .../queryrange/queryrangebase/query_range.go | 24 +- .../queryrangebase/query_range_test.go | 62 +- .../queryrangebase/queryable_test.go | 46 +- .../queryrangebase/queryrange.pb.go | 122 +-- .../queryrangebase/queryrange.proto | 4 +- .../queryrangebase/querysharding_test.go | 20 +- .../queryrangebase/results_cache.go | 4 +- .../queryrangebase/results_cache_test.go | 14 +- .../queryrange/queryrangebase/series_test.go | 22 +- .../queryrange/queryrangebase/value.go | 18 +- .../queryrange/queryrangebase/value_test.go | 38 +- pkg/querier/queryrange/querysharding_test.go | 8 +- pkg/ruler/base/compat.go | 8 +- pkg/ruler/base/compat_test.go | 2 +- pkg/ruler/base/ruler.pb.go | 86 +-- pkg/ruler/base/ruler.proto | 4 +- pkg/ruler/rulespb/rules.pb.go | 62 +- pkg/ruler/rulespb/rules.proto | 4 +- pkg/util/http_test.go | 8 +- 42 files changed, 1186 insertions(+), 663 deletions(-) diff --git a/pkg/ingester/checkpoint.pb.go b/pkg/ingester/checkpoint.pb.go index 2dea22e289..1748aa0db7 100644 --- a/pkg/ingester/checkpoint.pb.go +++ b/pkg/ingester/checkpoint.pb.go @@ -242,40 +242,40 @@ func init() { func init() { proto.RegisterFile("pkg/ingester/checkpoint.proto", fileDescriptor_00f4b7152db9bdb5) } var fileDescriptor_00f4b7152db9bdb5 = []byte{ - // 518 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x52, 0xbd, 0x8e, 0xd3, 0x40, - 0x10, 0xf6, 0x26, 0x8e, 0x2f, 0xd9, 0x40, 0xb3, 0x20, 0xb4, 0x0a, 0x62, 0x13, 0x5d, 0x95, 0x06, - 0x5b, 0x04, 0x0a, 0x68, 0x90, 0x2e, 0x87, 0x90, 0x90, 0xae, 0x40, 0xe6, 0x68, 0x68, 0xd0, 0xc6, - 0x5e, 0xff, 0x28, 0x8e, 0xd7, 0xda, 0x5d, 0x17, 0xd7, 0xf1, 0x04, 0xe8, 0x1e, 0x83, 0x47, 0xb9, - 0x32, 0xe5, 0x09, 0xa4, 0x83, 0x38, 0x0d, 0xe5, 0x3d, 0x02, 0xda, 0xb5, 0x9d, 0x0b, 0xdd, 0xa5, - 0x9b, 0x6f, 0x66, 0xbe, 0x99, 0xdd, 0x6f, 0x3e, 0xf8, 0xac, 0x58, 0xc6, 0x5e, 0x9a, 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 0xac, 0xeb, 0x0d, 0xb1, 0x6e, 0x37, 0x04, - 0x7c, 0xab, 0x08, 0xf8, 0x51, 0x11, 0x70, 0x55, 0x11, 0xb0, 0xae, 0x08, 0xf8, 0x53, 0x11, 0xf0, - 0xb7, 0x22, 0xd6, 0x6d, 0x45, 0xc0, 0xe5, 0x96, 0x58, 0xeb, 0x2d, 0xb1, 0xae, 0xb7, 0xc4, 0xfa, - 0xd2, 0x6f, 0x35, 0x58, 0x38, 0x66, 0xd1, 0xcb, 0x7f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x53, 0xc7, - 0x0e, 0x63, 0xd2, 0x03, 0x00, 0x00, + // 523 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x52, 0x31, 0x8f, 0xd3, 0x30, + 0x14, 0x8e, 0xdb, 0x34, 0xd7, 0xba, 0xb0, 0x58, 0x08, 0x99, 0x22, 0xdc, 0xea, 0xa6, 0x2e, 0x24, + 0xa2, 0x30, 0xc0, 0x82, 0x74, 0x3d, 0x84, 0x84, 0xd4, 0x01, 0x85, 0x63, 0x61, 0x41, 0x6e, 0xe2, + 0x26, 0x51, 0xd3, 0x38, 0xb2, 0x9d, 0xa1, 0x1b, 0x3f, 0xe1, 0x06, 0x7e, 0x04, 0x3f, 0xe5, 0xc6, + 0x8e, 0x27, 0x90, 0x0e, 0x9a, 0x2e, 0x8c, 0xf7, 0x13, 0x90, 0x9d, 0xa4, 0x57, 0xb6, 0xeb, 0xf6, + 0xbe, 0xf7, 0xde, 0xf7, 0x9e, 0xfd, 0xbd, 0x0f, 0x3e, 0xcb, 0x97, 0x91, 0x97, 0x64, 0x11, 0x93, + 0x8a, 0x09, 0x2f, 0x88, 0x59, 0xb0, 0xcc, 0x79, 0x92, 0x29, 0x37, 0x17, 0x5c, 0x71, 0xf4, 0x30, + 0xe5, 0xcb, 0xe4, 0x6b, 0x53, 0x1f, 0x0c, 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, 0x24, 0xe0, 0x6f, 0x49, 0xac, 0xdb, 0x92, 0x80, 0xcb, 0x1d, 0xb1, 0x36, 0x3b, + 0x62, 0x5d, 0xef, 0x88, 0xf5, 0xa5, 0xdb, 0x68, 0x30, 0x77, 0xcc, 0xa2, 0x97, 0xff, 0x02, 0x00, + 0x00, 0xff, 0xff, 0xee, 0x20, 0xe0, 0x2d, 0xd8, 0x03, 0x00, 0x00, } func (this *Chunk) Equal(that interface{}) bool { diff --git a/pkg/ingester/checkpoint.proto b/pkg/ingester/checkpoint.proto index c142346604..b1f530dd1a 100644 --- a/pkg/ingester/checkpoint.proto +++ b/pkg/ingester/checkpoint.proto @@ -28,7 +28,7 @@ message Series { string userID = 1; // post mapped fingerprint is necessary because subsequent wal writes will reference it. uint64 fingerprint = 2; - repeated logproto.LabelPair labels = 3 [(gogoproto.nullable) = false, (gogoproto.customtype) = "github.com/grafana/loki/pkg/logproto.LabelAdapter"]; + repeated logproto.LegacyLabelPair labels = 3 [(gogoproto.nullable) = false, (gogoproto.customtype) = "github.com/grafana/loki/pkg/logproto.LabelAdapter"]; repeated Chunk chunks = 4 [(gogoproto.nullable) = false]; // most recently pushed timestamp. google.protobuf.Timestamp to = 5 [(gogoproto.stdtime) = true, (gogoproto.nullable) = false]; diff --git a/pkg/ingester/client/ingester.pb.go b/pkg/ingester/client/ingester.pb.go index c0a127650d..62ad942052 100644 --- a/pkg/ingester/client/ingester.pb.go +++ b/pkg/ingester/client/ingester.pb.go @@ -1348,38 +1348,38 @@ func init() { } var fileDescriptor_5b6c87318632a5b2 = []byte{ - // 1276 bytes of a gzipped FileDescriptorProto + // 1280 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x57, 0xcf, 0x6f, 0x1b, 0xc5, 0x17, 0xdf, 0x49, 0x9c, 0x1f, 0x7e, 0x76, 0x5c, 0x67, 0xd2, 0x1f, 0xe9, 0xf6, 0xd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 0x80, 0x1b, 0x5b, 0x9b, 0x3e, + 0xf5, 0x98, 0x4c, 0x6c, 0xd9, 0x2e, 0x4b, 0xcb, 0x16, 0xf5, 0xd8, 0x90, 0xfc, 0x8f, 0xbd, 0x42, + 0xfe, 0xc7, 0x5f, 0x9a, 0xff, 0xd2, 0x05, 0x74, 0xdc, 0xfc, 0x7f, 0x08, 0x73, 0xb9, 0x33, 0xe8, + 0xb8, 0x5c, 0x84, 0xaa, 0x3a, 0xc4, 0xd7, 0xd2, 0x2e, 0x23, 0x53, 0xb6, 0x2b, 0x6e, 0x1f, 0x4a, + 0x0e, 0x60, 0x76, 0x23, 0x39, 0x15, 0x7f, 0xc3, 0xd5, 0x4d, 0xae, 0xea, 0x50, 0xeb, 0xcd, 0xb4, 0xca, 0x05, 0xa8, 0xf4, 0x43, 0x9d, 0x88, 0x84, 0x34, 0xd6, 0x9c, 0x60, 0xa8, 0xdf, 0xe7, 0x2c, 0xdc, 0x16, 0x54, 0x24, 0x12, 0xc9, 0xef, 0x08, 0x66, 0x33, 0x46, 0x4d, 0xf5, 0x16, 0xd4, 0x54, 0xb4, 0x9c, 0xc0, 0x6f, 0x86, 0x54, 0xa8, 0xcc, 0x21, 0x7b, 0x26, 0xb5, 0xda, 0x54, 0xb0, 0x38, @@ -1390,45 +1390,45 @@ var fileDescriptor_5b6c87318632a5b2 = []byte{ 0x8c, 0x97, 0xeb, 0x6d, 0x7c, 0x19, 0x4a, 0x6d, 0x2a, 0xa8, 0x94, 0x59, 0x59, 0x3e, 0x9f, 0x2d, 0x87, 0x81, 0x00, 0xd8, 0x12, 0x4a, 0x6e, 0x03, 0x8e, 0x5d, 0x3c, 0xbf, 0xc3, 0x55, 0x98, 0xe0, 0xb1, 0x41, 0x5f, 0x90, 0x85, 0x22, 0x53, 0x41, 0x91, 0xad, 0xd0, 0xe4, 0x37, 0x04, 0xd6, 0xa6, - 0xea, 0x2c, 0x37, 0x83, 0x30, 0x5f, 0x81, 0xc7, 0xfc, 0x1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+ 0x1b, 0xdd, 0xfd, 0x88, 0x81, 0xb7, 0xa0, 0xba, 0xe2, 0xba, 0xc7, 0xa5, 0xb3, 0x8a, 0x5e, 0x5e, + 0xe4, 0x13, 0xe9, 0xe3, 0x5e, 0xec, 0x21, 0xf8, 0x52, 0xee, 0x7e, 0x8e, 0x6c, 0x90, 0xe6, 0x3b, + 0xc7, 0xc2, 0xa6, 0xbb, 0x7e, 0x05, 0x27, 0x0a, 0x2d, 0x05, 0x93, 0x23, 0x18, 0x0a, 0x9d, 0xc8, + 0xfc, 0xff, 0x48, 0x4c, 0xca, 0x7e, 0x1f, 0x6a, 0xf9, 0x77, 0x0d, 0x8f, 0x1a, 0xe2, 0xcd, 0xdc, + 0xce, 0x43, 0x1e, 0x44, 0x63, 0x11, 0xdd, 0xb8, 0xfe, 0xf8, 0x99, 0x65, 0x3c, 0x79, 0x66, 0x19, + 0x2f, 0x9e, 0x59, 0xe8, 0xdb, 0x9e, 0x85, 0x7e, 0xed, 0x59, 0xe8, 0x51, 0xcf, 0x42, 0x8f, 0x7b, + 0x16, 0xfa, 0xab, 0x67, 0xa1, 0xbf, 0x7b, 0x96, 0xf1, 0xa2, 0x67, 0xa1, 0x1f, 0x9e, 0x5b, 0xc6, + 0xe3, 0xe7, 0x96, 0xf1, 0xe4, 0xb9, 0x65, 0x7c, 0x39, 0xa9, 0xfe, 0x13, 0xef, 0x4e, 0xca, 0x3b, + 0x7a, 0xe5, 0xdf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x1c, 0xdf, 0x44, 0xc1, 0x31, 0x0f, 0x00, 0x00, } func (x MatchType) String() string { diff --git a/pkg/ingester/client/ingester.proto b/pkg/ingester/client/ingester.proto index 658af62444..c1cecc1a17 100644 --- a/pkg/ingester/client/ingester.proto +++ b/pkg/ingester/client/ingester.proto @@ -120,7 +120,7 @@ message MetricsMetadataResponse { message TimeSeriesChunk { string from_ingester_id = 1; string user_id = 2; - repeated logproto.LabelPair labels = 3 [(gogoproto.nullable) = false, (gogoproto.customtype) = "github.com/grafana/loki/pkg/logproto.LabelAdapter"]; + repeated logproto.LegacyLabelPair labels = 3 [(gogoproto.nullable) = false, (gogoproto.customtype) = "github.com/grafana/loki/pkg/logproto.LabelAdapter"]; repeated Chunk chunks = 4 [(gogoproto.nullable) = false]; } diff --git a/pkg/logproto/compat.go b/pkg/logproto/compat.go index fa25addc53..baaa5ae866 100644 --- a/pkg/logproto/compat.go +++ b/pkg/logproto/compat.go @@ -19,7 +19,7 @@ import ( // ToWriteRequest converts matched slices of Labels, Samples and Metadata into a WriteRequest proto. // It gets timeseries from the pool, so ReuseSlice() should be called when done. -func ToWriteRequest(lbls []labels.Labels, samples []Sample, metadata []*MetricMetadata, source WriteRequest_SourceEnum) *WriteRequest { +func ToWriteRequest(lbls []labels.Labels, samples []LegacySample, metadata []*MetricMetadata, source WriteRequest_SourceEnum) *WriteRequest { req := &WriteRequest{ Timeseries: PreallocTimeseriesSliceFromPool(), Metadata: metadata, @@ -126,12 +126,12 @@ func (s byLabel) Swap(i, j int) { s[i], s[j] = s[j], s[i] } var isTesting = false // MarshalJSON implements json.Marshaler. -func (s Sample) MarshalJSON() ([]byte, error) { +func (s LegacySample) MarshalJSON() ([]byte, error) { if isTesting && math.IsNaN(s.Value) { return nil, fmt.Errorf("test sample") } - t, err := jsoniter.ConfigCompatibleWithStandardLibrary.Marshal(model.Time(s.Timestamp)) + t, err := jsoniter.ConfigCompatibleWithStandardLibrary.Marshal(model.Time(s.TimestampMs)) if err != nil { return nil, err } @@ -143,14 +143,14 @@ func (s Sample) MarshalJSON() ([]byte, error) { } // UnmarshalJSON implements json.Unmarshaler. -func (s *Sample) UnmarshalJSON(b []byte) error { +func (s *LegacySample) UnmarshalJSON(b []byte) error { var t model.Time var v model.SampleValue vs := [...]stdjson.Unmarshaler{&t, &v} if err := jsoniter.ConfigCompatibleWithStandardLibrary.Unmarshal(b, &vs); err != nil { return err } - s.Timestamp = int64(t) + s.TimestampMs = int64(t) s.Value = float64(v) if isTesting && math.IsNaN(float64(v)) { @@ -160,30 +160,30 @@ func (s *Sample) UnmarshalJSON(b []byte) error { } func SampleJsoniterEncode(ptr unsafe.Pointer, stream *jsoniter.Stream) { - sample := (*Sample)(ptr) + legacySample := (*LegacySample)(ptr) - if isTesting && math.IsNaN(sample.Value) { + if isTesting && math.IsNaN(legacySample.Value) { stream.Error = fmt.Errorf("test sample") return } stream.WriteArrayStart() - stream.WriteFloat64(float64(sample.Timestamp) / float64(time.Second/time.Millisecond)) + stream.WriteFloat64(float64(legacySample.TimestampMs) / float64(time.Second/time.Millisecond)) stream.WriteMore() - stream.WriteString(model.SampleValue(sample.Value).String()) + stream.WriteString(model.SampleValue(legacySample.Value).String()) stream.WriteArrayEnd() } func SampleJsoniterDecode(ptr unsafe.Pointer, iter *jsoniter.Iterator) { if !iter.ReadArray() { - iter.ReportError("logproto.Sample", "expected [") + iter.ReportError("logproto.LegacySample", "expected [") return } t := model.Time(iter.ReadFloat64() * float64(time.Second/time.Millisecond)) if !iter.ReadArray() { - iter.ReportError("logproto.Sample", "expected ,") + iter.ReportError("logproto.LegacySample", "expected ,") return } @@ -191,7 +191,7 @@ func SampleJsoniterDecode(ptr unsafe.Pointer, iter *jsoniter.Iterator) { ss := *(*string)(unsafe.Pointer(&bs)) v, err := strconv.ParseFloat(ss, 64) if err != nil { - iter.ReportError("logproto.Sample", err.Error()) + iter.ReportError("logproto.LegacySample", err.Error()) return } @@ -201,16 +201,16 @@ func SampleJsoniterDecode(ptr unsafe.Pointer, iter *jsoniter.Iterator) { } if iter.ReadArray() { - iter.ReportError("logproto.Sample", "expected ]") + iter.ReportError("logproto.LegacySample", "expected ]") } - *(*Sample)(ptr) = Sample{ - Timestamp: int64(t), - Value: v, + *(*LegacySample)(ptr) = LegacySample{ + TimestampMs: int64(t), + Value: v, } } func init() { - jsoniter.RegisterTypeEncoderFunc("logproto.Sample", SampleJsoniterEncode, func(unsafe.Pointer) bool { return false }) - jsoniter.RegisterTypeDecoderFunc("logproto.Sample", SampleJsoniterDecode) + jsoniter.RegisterTypeEncoderFunc("logproto.LegacySample", SampleJsoniterEncode, func(unsafe.Pointer) bool { return false }) + jsoniter.RegisterTypeDecoderFunc("logproto.LegacySample", SampleJsoniterDecode) } diff --git a/pkg/logproto/compat_test.go b/pkg/logproto/compat_test.go index ce12e8e58e..5828731c17 100644 --- a/pkg/logproto/compat_test.go +++ b/pkg/logproto/compat_test.go @@ -20,23 +20,23 @@ func TestJsoniterMarshalForSample(t *testing.T) { } func TestStdlibJsonMarshalForSample(t *testing.T) { - testMarshalling(t, stdlibjson.Marshal, "json: error calling MarshalJSON for type logproto.Sample: test sample") + testMarshalling(t, stdlibjson.Marshal, "json: error calling MarshalJSON for type logproto.LegacySample: test sample") } func testMarshalling(t *testing.T, marshalFn func(v interface{}) ([]byte, error), expectedError string) { isTesting = true defer func() { isTesting = false }() - out, err := marshalFn(Sample{Value: 12345, Timestamp: 98765}) + out, err := marshalFn(LegacySample{Value: 12345, TimestampMs: 98765}) require.NoError(t, err) require.Equal(t, `[98.765,"12345"]`, string(out)) - _, err = marshalFn(Sample{Value: math.NaN(), Timestamp: 0}) + _, err = marshalFn(LegacySample{Value: math.NaN(), TimestampMs: 0}) require.EqualError(t, err, expectedError) // If not testing, we get normal output. isTesting = false - out, err = marshalFn(Sample{Value: math.NaN(), Timestamp: 0}) + out, err = marshalFn(LegacySample{Value: math.NaN(), TimestampMs: 0}) require.NoError(t, err) require.Equal(t, `[0,"NaN"]`, string(out)) } @@ -55,11 +55,11 @@ func testUnmarshalling(t *testing.T, unmarshalFn func(data []byte, v interface{} isTesting = true defer func() { isTesting = false }() - sample := Sample{} + sample := LegacySample{} err := unmarshalFn([]byte(`[98.765,"12345"]`), &sample) require.NoError(t, err) - require.Equal(t, Sample{Value: 12345, Timestamp: 98765}, sample) + require.Equal(t, LegacySample{Value: 12345, TimestampMs: 98765}, sample) err = unmarshalFn([]byte(`[0.0,"NaN"]`), &sample) require.EqualError(t, err, expectedError) @@ -67,7 +67,7 @@ func testUnmarshalling(t *testing.T, unmarshalFn func(data []byte, v interface{} isTesting = false err = unmarshalFn([]byte(`[0.0,"NaN"]`), &sample) require.NoError(t, err) - require.Equal(t, int64(0), sample.Timestamp) + require.Equal(t, int64(0), sample.TimestampMs) require.True(t, math.IsNaN(sample.Value)) } diff --git a/pkg/logproto/logproto.pb.go b/pkg/logproto/logproto.pb.go index e1579cd3f8..169b4da745 100644 --- a/pkg/logproto/logproto.pb.go +++ b/pkg/logproto/logproto.pb.go @@ -639,6 +639,57 @@ func (m *Sample) GetHash() uint64 { return 0 } +type LegacySample struct { + Value float64 `protobuf:"fixed64,1,opt,name=value,proto3" json:"value,omitempty"` + TimestampMs int64 `protobuf:"varint,2,opt,name=timestamp_ms,json=timestampMs,proto3" json:"timestamp_ms,omitempty"` +} + +func (m *LegacySample) Reset() { *m = LegacySample{} } +func (*LegacySample) ProtoMessage() {} +func (*LegacySample) Descriptor() ([]byte, []int) { + return fileDescriptor_c28a5f14f1f4c79a, []int{11} +} +func (m *LegacySample) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *LegacySample) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_LegacySample.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *LegacySample) XXX_Merge(src proto.Message) { + xxx_messageInfo_LegacySample.Merge(m, src) +} +func (m *LegacySample) XXX_Size() int { + return m.Size() +} +func (m *LegacySample) XXX_DiscardUnknown() { + xxx_messageInfo_LegacySample.DiscardUnknown(m) +} + +var xxx_messageInfo_LegacySample proto.InternalMessageInfo + +func (m *LegacySample) GetValue() float64 { + if m != nil { + return m.Value + } + return 0 +} + +func (m *LegacySample) GetTimestampMs() int64 { + if m != nil { + return m.TimestampMs + } + return 0 +} + type Series struct { Labels string `protobuf:"bytes,1,opt,name=labels,proto3" json:"labels"` Samples []Sample `protobuf:"bytes,2,rep,name=samples,proto3" json:"samples"` @@ -647,7 +698,7 @@ type Series struct { func (m *Series) Reset() { *m = Series{} } func (*Series) ProtoMessage() {} func (*Series) Descriptor() ([]byte, []int) { - return fileDescriptor_c28a5f14f1f4c79a, []int{11} + return fileDescriptor_c28a5f14f1f4c79a, []int{12} } func (m *Series) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -700,7 +751,7 @@ type TailRequest struct { func (m *TailRequest) Reset() { *m = TailRequest{} } func (*TailRequest) ProtoMessage() {} func (*TailRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_c28a5f14f1f4c79a, []int{12} + return fileDescriptor_c28a5f14f1f4c79a, []int{13} } func (m *TailRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -765,7 +816,7 @@ type TailResponse struct { func (m *TailResponse) Reset() { *m = TailResponse{} } func (*TailResponse) ProtoMessage() {} func (*TailResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_c28a5f14f1f4c79a, []int{13} + return fileDescriptor_c28a5f14f1f4c79a, []int{14} } func (m *TailResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -811,7 +862,7 @@ type SeriesRequest struct { func (m *SeriesRequest) Reset() { *m = SeriesRequest{} } func (*SeriesRequest) ProtoMessage() {} func (*SeriesRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_c28a5f14f1f4c79a, []int{14} + return fileDescriptor_c28a5f14f1f4c79a, []int{15} } func (m *SeriesRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -875,7 +926,7 @@ type SeriesResponse struct { func (m *SeriesResponse) Reset() { *m = SeriesResponse{} } func (*SeriesResponse) ProtoMessage() {} func (*SeriesResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_c28a5f14f1f4c79a, []int{15} + return fileDescriptor_c28a5f14f1f4c79a, []int{16} } func (m *SeriesResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -918,7 +969,7 @@ type SeriesIdentifier struct { func (m *SeriesIdentifier) Reset() { *m = SeriesIdentifier{} } func (*SeriesIdentifier) ProtoMessage() {} func (*SeriesIdentifier) Descriptor() ([]byte, []int) { - return fileDescriptor_c28a5f14f1f4c79a, []int{16} + return fileDescriptor_c28a5f14f1f4c79a, []int{17} } func (m *SeriesIdentifier) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -963,7 +1014,7 @@ type DroppedStream struct { func (m *DroppedStream) Reset() { *m = DroppedStream{} } func (*DroppedStream) ProtoMessage() {} func (*DroppedStream) Descriptor() ([]byte, []int) { - return fileDescriptor_c28a5f14f1f4c79a, []int{17} + return fileDescriptor_c28a5f14f1f4c79a, []int{18} } func (m *DroppedStream) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1023,7 +1074,7 @@ type TimeSeriesChunk struct { func (m *TimeSeriesChunk) Reset() { *m = TimeSeriesChunk{} } func (*TimeSeriesChunk) ProtoMessage() {} func (*TimeSeriesChunk) Descriptor() ([]byte, []int) { - return fileDescriptor_c28a5f14f1f4c79a, []int{18} + return fileDescriptor_c28a5f14f1f4c79a, []int{19} } func (m *TimeSeriesChunk) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1088,7 +1139,7 @@ type LabelPair struct { func (m *LabelPair) Reset() { *m = LabelPair{} } func (*LabelPair) ProtoMessage() {} func (*LabelPair) Descriptor() ([]byte, []int) { - return fileDescriptor_c28a5f14f1f4c79a, []int{19} + return fileDescriptor_c28a5f14f1f4c79a, []int{20} } func (m *LabelPair) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1131,6 +1182,57 @@ func (m *LabelPair) GetValue() string { return "" } +type LegacyLabelPair struct { + Name []byte `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` + Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` +} + +func (m *LegacyLabelPair) Reset() { *m = LegacyLabelPair{} } +func (*LegacyLabelPair) ProtoMessage() {} +func (*LegacyLabelPair) Descriptor() ([]byte, []int) { + return fileDescriptor_c28a5f14f1f4c79a, []int{21} +} +func (m *LegacyLabelPair) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *LegacyLabelPair) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_LegacyLabelPair.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *LegacyLabelPair) XXX_Merge(src proto.Message) { + xxx_messageInfo_LegacyLabelPair.Merge(m, src) +} +func (m *LegacyLabelPair) XXX_Size() int { + return m.Size() +} +func (m *LegacyLabelPair) XXX_DiscardUnknown() { + xxx_messageInfo_LegacyLabelPair.DiscardUnknown(m) +} + +var xxx_messageInfo_LegacyLabelPair proto.InternalMessageInfo + +func (m *LegacyLabelPair) GetName() []byte { + if m != nil { + return m.Name + } + return nil +} + +func (m *LegacyLabelPair) GetValue() []byte { + if m != nil { + return m.Value + } + return nil +} + type Chunk struct { Data []byte `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"` } @@ -1138,7 +1240,7 @@ type Chunk struct { func (m *Chunk) Reset() { *m = Chunk{} } func (*Chunk) ProtoMessage() {} func (*Chunk) Descriptor() ([]byte, []int) { - return fileDescriptor_c28a5f14f1f4c79a, []int{20} + return fileDescriptor_c28a5f14f1f4c79a, []int{22} } func (m *Chunk) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1180,7 +1282,7 @@ type TransferChunksResponse struct { func (m *TransferChunksResponse) Reset() { *m = TransferChunksResponse{} } func (*TransferChunksResponse) ProtoMessage() {} func (*TransferChunksResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_c28a5f14f1f4c79a, []int{21} + return fileDescriptor_c28a5f14f1f4c79a, []int{23} } func (m *TransferChunksResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1215,7 +1317,7 @@ type TailersCountRequest struct { func (m *TailersCountRequest) Reset() { *m = TailersCountRequest{} } func (*TailersCountRequest) ProtoMessage() {} func (*TailersCountRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_c28a5f14f1f4c79a, []int{22} + return fileDescriptor_c28a5f14f1f4c79a, []int{24} } func (m *TailersCountRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1251,7 +1353,7 @@ type TailersCountResponse struct { func (m *TailersCountResponse) Reset() { *m = TailersCountResponse{} } func (*TailersCountResponse) ProtoMessage() {} func (*TailersCountResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_c28a5f14f1f4c79a, []int{23} + return fileDescriptor_c28a5f14f1f4c79a, []int{25} } func (m *TailersCountResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1296,7 +1398,7 @@ type GetChunkIDsRequest struct { func (m *GetChunkIDsRequest) Reset() { *m = GetChunkIDsRequest{} } func (*GetChunkIDsRequest) ProtoMessage() {} func (*GetChunkIDsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_c28a5f14f1f4c79a, []int{24} + return fileDescriptor_c28a5f14f1f4c79a, []int{26} } func (m *GetChunkIDsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1353,7 +1455,7 @@ type GetChunkIDsResponse struct { func (m *GetChunkIDsResponse) Reset() { *m = GetChunkIDsResponse{} } func (*GetChunkIDsResponse) ProtoMessage() {} func (*GetChunkIDsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_c28a5f14f1f4c79a, []int{25} + return fileDescriptor_c28a5f14f1f4c79a, []int{27} } func (m *GetChunkIDsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1402,6 +1504,7 @@ func init() { proto.RegisterType((*StreamAdapter)(nil), "logproto.StreamAdapter") proto.RegisterType((*EntryAdapter)(nil), "logproto.EntryAdapter") proto.RegisterType((*Sample)(nil), "logproto.Sample") + proto.RegisterType((*LegacySample)(nil), "logproto.LegacySample") proto.RegisterType((*Series)(nil), "logproto.Series") proto.RegisterType((*TailRequest)(nil), "logproto.TailRequest") proto.RegisterType((*TailResponse)(nil), "logproto.TailResponse") @@ -1412,6 +1515,7 @@ func init() { proto.RegisterType((*DroppedStream)(nil), "logproto.DroppedStream") proto.RegisterType((*TimeSeriesChunk)(nil), "logproto.TimeSeriesChunk") proto.RegisterType((*LabelPair)(nil), "logproto.LabelPair") + proto.RegisterType((*LegacyLabelPair)(nil), "logproto.LegacyLabelPair") proto.RegisterType((*Chunk)(nil), "logproto.Chunk") proto.RegisterType((*TransferChunksResponse)(nil), "logproto.TransferChunksResponse") proto.RegisterType((*TailersCountRequest)(nil), "logproto.TailersCountRequest") @@ -1423,95 +1527,98 @@ func init() { func init() { proto.RegisterFile("pkg/logproto/logproto.proto", fileDescriptor_c28a5f14f1f4c79a) } var fileDescriptor_c28a5f14f1f4c79a = []byte{ - // 1404 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xc4, 0x57, 0x49, 0x8f, 0x13, 0x47, - 0x14, 0x76, 0x79, 0xe9, 0xb1, 0x9f, 0x17, 0xac, 0x9a, 0x61, 0xc6, 0x31, 0xd0, 0xb6, 0x4a, 0x08, - 0xac, 0x40, 0xec, 0x30, 0xd9, 0x58, 0xb2, 0x68, 0xcc, 0x84, 0x30, 0x04, 0x05, 0x68, 0x90, 0x90, - 0x90, 0x22, 0xd4, 0x63, 0xd7, 0xd8, 0xad, 0xb1, 0xdd, 0xa6, 0xab, 0x8c, 0x34, 0x52, 0xa4, 0xe4, - 0x07, 0x24, 0x12, 0xb7, 0x1c, 0x72, 0xcd, 0x21, 0xca, 0x21, 0xbf, 0x83, 0xdc, 0x50, 0x4e, 0x28, - 0x07, 0x27, 0x98, 0x4b, 0x34, 0xca, 0x81, 0x9f, 0x10, 0xd5, 0xd2, 0xed, 0xb2, 0x99, 0x49, 0x30, - 0x97, 0x5c, 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 0x13, 0x4d, 0x4b, 0x59, 0x34, 0xad, 0x55, 0x20, 0x25, 0x91, 0x92, 0xe6, 0x50, 0x33, 0xb3, - 0x3f, 0xae, 0xa8, 0x09, 0x47, 0xfd, 0x08, 0x77, 0x5d, 0x97, 0x75, 0x65, 0x71, 0x93, 0xca, 0x9d, - 0x90, 0x1d, 0xf9, 0x25, 0x1e, 0x68, 0xde, 0xbd, 0x12, 0xae, 0x97, 0x60, 0x89, 0xc9, 0xe0, 0x42, - 0x5c, 0x4d, 0x3a, 0xcb, 0x85, 0x29, 0xa2, 0x5a, 0xd1, 0x09, 0x07, 0xe4, 0x7b, 0x04, 0xd9, 0x3b, - 0xae, 0x17, 0x51, 0x74, 0x05, 0x52, 0x0f, 0xc4, 0x59, 0xd1, 0x1c, 0x55, 0x82, 0x68, 0x43, 0x6d, - 0xda, 0x73, 0xf7, 0xae, 0xf8, 0x81, 0x0c, 0x39, 0xef, 0x44, 0xf2, 0xb4, 0x55, 0x27, 0x0f, 0x6c, - 0xd5, 0xa9, 0x85, 0x9b, 0xd3, 0xb5, 0x64, 0x3a, 0x5e, 0x4c, 0x90, 0x6f, 0x11, 0xe4, 0x54, 0x64, - 0x9a, 0x8c, 0x97, 0xc0, 0x52, 0x4d, 0x40, 0x57, 0xfa, 0xd0, 0xde, 0x01, 0x46, 0xdf, 0xd0, 0x5b, - 0xf0, 0x27, 0x50, 0x68, 0x07, 0xfe, 0x70, 0x48, 0xdb, 0xb7, 0x75, 0x03, 0x8a, 0xcf, 0x37, 0xa0, - 0x4d, 0x73, 0xdd, 0x99, 0x53, 0x27, 0xbf, 0x22, 0xc8, 0xeb, 0x66, 0xa0, 0xa1, 0x8a, 0x52, 0x44, - 0xaf, 0xdd, 0x7f, 0xe3, 0x8b, 0xf6, 0xdf, 0x55, 0xb0, 0x3a, 0x81, 0x3f, 0x1a, 0xb2, 0x52, 0x42, - 0x1d, 0x48, 0x25, 0x2d, 0xd8, 0x97, 0xaf, 0x41, 0x21, 0x4c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 0x71, 0x03, 0x77, 0xc7, 0x1d, - 0xb8, 0x8d, 0x9e, 0xbf, 0xeb, 0x35, 0xcc, 0xff, 0xd0, 0xdb, 0x96, 0xfc, 0x79, 0xe7, 0x9f, 0x00, - 0x00, 0x00, 0xff, 0xff, 0x7b, 0x53, 0xc1, 0x06, 0x5a, 0x0f, 0x00, 0x00, + // 1446 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xc4, 0x57, 0x49, 0x8f, 0x13, 0xc7, + 0x17, 0x77, 0x79, 0xe9, 0xb1, 0x9f, 0x97, 0xb1, 0x6a, 0x86, 0x19, 0xff, 0x0d, 0xb4, 0xfd, 0x6f, + 0x21, 0xb0, 0x02, 0xb1, 0xc3, 0x64, 0x63, 0xc9, 0xa2, 0x31, 0x13, 0x60, 0x08, 0x09, 0xd0, 0x20, + 0x21, 0x21, 0x45, 0xa8, 0xc7, 0xae, 0xb1, 0x5b, 0xe3, 0x76, 0x9b, 0xae, 0x36, 0xd2, 0x48, 0x91, + 0x92, 0x0f, 0x90, 0x48, 0xdc, 0x72, 0xc8, 0x35, 0x87, 0x28, 0x87, 0x7c, 0x0e, 0x72, 0x43, 0x39, + 0xa1, 0x1c, 0x9c, 0x60, 0x2e, 0xd1, 0x28, 0x07, 0x3e, 0x42, 0x54, 0x5b, 0xbb, 0x6c, 0x3c, 0x09, + 0xe6, 0x92, 0x4b, 0xbb, 0xde, 0xab, 0xb7, 0xbf, 0x5f, 0xbd, 0x2a, 0xc3, 0xd1, 0xc1, 0x5e, 0xa7, + 0xd1, 0xf3, 0x3b, 0x83, 0xc0, 0x0f, 0xfd, 0x68, 0x51, 0xe7, 0x5f, 0x9c, 0x56, 0x74, 0xb9, 0xd2, + 0xf1, 0xfd, 0x4e, 0x8f, 0x34, 0x38, 0xb5, 0x33, 0xdc, 0x6d, 0x84, 0xae, 0x47, 0x68, 0xe8, 0x78, + 0x03, 0x21, 0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ff, 0x21, 0x17, 0x79, 0xbc, 0xef, 0x09, 0xfc, 0x24, 0xec, 0x6c, + 0xc4, 0xfb, 0x8c, 0x5a, 0x2e, 0x48, 0x00, 0xbf, 0x52, 0x83, 0x2e, 0xc2, 0x12, 0xe5, 0x0e, 0x55, + 0x83, 0xf4, 0x73, 0xc1, 0x37, 0x26, 0xad, 0x91, 0x82, 0xb6, 0x5a, 0x58, 0xdf, 0x21, 0xc8, 0xde, + 0x71, 0xdc, 0x08, 0xeb, 0xab, 0x90, 0x7a, 0xc0, 0x0e, 0x9d, 0x04, 0xbb, 0x20, 0xd8, 0x3c, 0x6b, + 0x93, 0x9e, 0xb3, 0x7f, 0xd9, 0x0f, 0x78, 0xee, 0x79, 0x3b, 0xa2, 0x27, 0x33, 0x3f, 0x39, 0x77, + 0xe6, 0xa7, 0x16, 0x9e, 0x72, 0xd7, 0x92, 0xe9, 0x78, 0x31, 0x61, 0x7d, 0x83, 0x20, 0x27, 0x22, + 0x93, 0xa8, 0xbe, 0x08, 0x86, 0x98, 0x26, 0x12, 0x32, 0x87, 0x0e, 0x21, 0xd0, 0x06, 0x90, 0x54, + 0xc1, 0x1f, 0x43, 0xa1, 0x1d, 0xf8, 0x83, 0x01, 0x69, 0xdf, 0x96, 0x93, 0x2c, 0x3e, 0x3b, 0xc9, + 0xb6, 0xf4, 0x7d, 0x7b, 0x46, 0xdc, 0xfa, 0x05, 0x41, 0x5e, 0x4e, 0x15, 0x59, 0xaa, 0x28, 0x45, + 0xf4, 0xda, 0x83, 0x3c, 0xbe, 0xe8, 0x20, 0x5f, 0x03, 0xa3, 0x13, 0xf8, 0xc3, 0x01, 0x2d, 0x25, + 0xc4, 0xc9, 0x16, 0xd4, 0x82, 0x03, 0xfe, 0x1a, 0x14, 0x54, 0x2a, 0x87, 0x8c, 0xd6, 0xf2, 0xec, + 0x68, 0xdd, 0x6e, 0x93, 0x7e, 0xe8, 0xee, 0xba, 0xd1, 0xb0, 0x94, 0xf2, 0xd6, 0xb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0x7a, 0xfe, 0x9e, 0xdb, + 0xd0, 0xff, 0xc9, 0xef, 0x18, 0xfc, 0xe7, 0xed, 0xbf, 0x03, 0x00, 0x00, 0xff, 0xff, 0xe8, 0x71, + 0x40, 0x74, 0xe0, 0x0f, 0x00, 0x00, } func (x Direction) String() string { @@ -1876,6 +1983,33 @@ func (this *Sample) Equal(that interface{}) bool { } return true } +func (this *LegacySample) Equal(that interface{}) bool { + if that == nil { + return this == nil + } + + that1, ok := that.(*LegacySample) + if !ok { + that2, ok := that.(LegacySample) + if ok { + that1 = &that2 + } else { + return false + } + } + if that1 == nil { + return this == nil + } else if this == nil { + return false + } + if this.Value != that1.Value { + return false + } + if this.TimestampMs != that1.TimestampMs { + return false + } + return true +} func (this *Series) Equal(that interface{}) bool { if that == nil { return this == nil @@ -2178,6 +2312,33 @@ func (this *LabelPair) Equal(that interface{}) bool { } return true } +func (this *LegacyLabelPair) Equal(that interface{}) bool { + if that == nil { + return this == nil + } + + that1, ok := that.(*LegacyLabelPair) + if !ok { + that2, ok := that.(LegacyLabelPair) + if ok { + that1 = &that2 + } else { + return false + } + } + if that1 == nil { + return this == nil + } else if this == nil { + return false + } + if !bytes.Equal(this.Name, that1.Name) { + return false + } + if !bytes.Equal(this.Value, that1.Value) { + return false + } + return true +} func (this *Chunk) Equal(that interface{}) bool { if that == nil { return this == nil @@ -2459,6 +2620,17 @@ func (this *Sample) GoString() string { s = append(s, "}") return strings.Join(s, "") } +func (this *LegacySample) GoString() string { + if this == nil { + return "nil" + } + s := make([]string, 0, 6) + s = append(s, "&logproto.LegacySample{") + s = append(s, "Value: "+fmt.Sprintf("%#v", this.Value)+",\n") + s = append(s, "TimestampMs: "+fmt.Sprintf("%#v", this.TimestampMs)+",\n") + s = append(s, "}") + return strings.Join(s, "") +} func (this *Series) GoString() string { if this == nil { return "nil" @@ -2593,6 +2765,17 @@ func (this *LabelPair) GoString() string { s = append(s, "}") return strings.Join(s, "") } +func (this *LegacyLabelPair) GoString() string { + if this == nil { + return "nil" + } + s := make([]string, 0, 6) + s = append(s, "&logproto.LegacyLabelPair{") + s = append(s, "Name: "+fmt.Sprintf("%#v", this.Name)+",\n") + s = append(s, "Value: "+fmt.Sprintf("%#v", this.Value)+",\n") + s = append(s, "}") + return strings.Join(s, "") +} func (this *Chunk) GoString() string { if this == nil { return "nil" @@ -3705,6 +3888,40 @@ func (m *Sample) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *LegacySample) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *LegacySample) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *LegacySample) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.TimestampMs != 0 { + i = encodeVarintLogproto(dAtA, i, uint64(m.TimestampMs)) + i-- + dAtA[i] = 0x10 + } + if m.Value != 0 { + i -= 8 + encoding_binary.LittleEndian.PutUint64(dAtA[i:], uint64(math.Float64bits(float64(m.Value)))) + i-- + dAtA[i] = 0x9 + } + return len(dAtA) - i, nil +} + func (m *Series) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) @@ -4130,6 +4347,43 @@ func (m *LabelPair) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *LegacyLabelPair) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *LegacyLabelPair) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *LegacyLabelPair) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Value) > 0 { + i -= len(m.Value) + copy(dAtA[i:], m.Value) + i = encodeVarintLogproto(dAtA, i, uint64(len(m.Value))) + i-- + dAtA[i] = 0x12 + } + if len(m.Name) > 0 { + i -= len(m.Name) + copy(dAtA[i:], m.Name) + i = encodeVarintLogproto(dAtA, i, uint64(len(m.Name))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + func (m *Chunk) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) @@ -4524,6 +4778,21 @@ func (m *Sample) Size() (n int) { return n } +func (m *LegacySample) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Value != 0 { + n += 9 + } + if m.TimestampMs != 0 { + n += 1 + sovLogproto(uint64(m.TimestampMs)) + } + return n +} + func (m *Series) Size() (n int) { if m == nil { return 0 @@ -4703,6 +4972,23 @@ func (m *LabelPair) Size() (n int) { return n } +func (m *LegacyLabelPair) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Name) + if l > 0 { + n += 1 + l + sovLogproto(uint64(l)) + } + l = len(m.Value) + if l > 0 { + n += 1 + l + sovLogproto(uint64(l)) + } + return n +} + func (m *Chunk) Size() (n int) { if m == nil { return 0 @@ -4915,6 +5201,17 @@ func (this *Sample) String() string { }, "") return s } +func (this *LegacySample) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&LegacySample{`, + `Value:` + fmt.Sprintf("%v", this.Value) + `,`, + `TimestampMs:` + fmt.Sprintf("%v", this.TimestampMs) + `,`, + `}`, + }, "") + return s +} func (this *Series) String() string { if this == nil { return "nil" @@ -5054,6 +5351,17 @@ func (this *LabelPair) String() string { }, "") return s } +func (this *LegacyLabelPair) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&LegacyLabelPair{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `Value:` + fmt.Sprintf("%v", this.Value) + `,`, + `}`, + }, "") + return s +} func (this *Chunk) String() string { if this == nil { return "nil" @@ -6507,6 +6815,89 @@ func (m *Sample) Unmarshal(dAtA []byte) error { } return nil } +func (m *LegacySample) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowLogproto + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: LegacySample: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: LegacySample: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 1 { + return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) + } + var v uint64 + if (iNdEx + 8) > l { + return io.ErrUnexpectedEOF + } + v = uint64(encoding_binary.LittleEndian.Uint64(dAtA[iNdEx:])) + iNdEx += 8 + m.Value = float64(math.Float64frombits(v)) + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field TimestampMs", wireType) + } + m.TimestampMs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowLogproto + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.TimestampMs |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipLogproto(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthLogproto + } + if (iNdEx + skippy) < 0 { + return ErrInvalidLengthLogproto + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func (m *Series) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 @@ -7808,6 +8199,127 @@ func (m *LabelPair) Unmarshal(dAtA []byte) error { } return nil } +func (m *LegacyLabelPair) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowLogproto + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: LegacyLabelPair: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: LegacyLabelPair: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowLogproto + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthLogproto + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthLogproto + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = append(m.Name[:0], dAtA[iNdEx:postIndex]...) + if m.Name == nil { + m.Name = []byte{} + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowLogproto + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthLogproto + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthLogproto + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Value = append(m.Value[:0], dAtA[iNdEx:postIndex]...) + if m.Value == nil { + m.Value = []byte{} + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipLogproto(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthLogproto + } + if (iNdEx + skippy) < 0 { + return ErrInvalidLengthLogproto + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func (m *Chunk) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 diff --git a/pkg/logproto/logproto.proto b/pkg/logproto/logproto.proto index a0cb9f102e..9efb2aee69 100644 --- a/pkg/logproto/logproto.proto +++ b/pkg/logproto/logproto.proto @@ -95,6 +95,11 @@ message Sample { uint64 hash = 3 [(gogoproto.jsontag) = "hash"]; } +message LegacySample { + double value = 1; + int64 timestamp_ms = 2; +} + message Series { string labels = 1 [(gogoproto.jsontag) = "labels"]; repeated Sample samples = 2 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "samples"]; @@ -146,6 +151,11 @@ message LabelPair { string value = 2; } +message LegacyLabelPair { + bytes name = 1; + bytes value = 2; +} + message Chunk { bytes data = 1; } diff --git a/pkg/logproto/metrics.pb.go b/pkg/logproto/metrics.pb.go index a97b0ddc05..5649d4af01 100644 --- a/pkg/logproto/metrics.pb.go +++ b/pkg/logproto/metrics.pb.go @@ -184,7 +184,7 @@ var xxx_messageInfo_WriteResponse proto.InternalMessageInfo type TimeSeries struct { Labels []LabelAdapter `protobuf:"bytes,1,rep,name=labels,proto3,customtype=LabelAdapter" json:"labels"` // Sorted by time, oldest sample first. - Samples []Sample `protobuf:"bytes,2,rep,name=samples,proto3" json:"samples"` + Samples []LegacySample `protobuf:"bytes,2,rep,name=samples,proto3" json:"samples"` } func (m *TimeSeries) Reset() { *m = TimeSeries{} } @@ -219,7 +219,7 @@ func (m *TimeSeries) XXX_DiscardUnknown() { var xxx_messageInfo_TimeSeries proto.InternalMessageInfo -func (m *TimeSeries) GetSamples() []Sample { +func (m *TimeSeries) GetSamples() []LegacySample { if m != nil { return m.Samples } @@ -342,46 +342,47 @@ func init() { func init() { proto.RegisterFile("pkg/logproto/metrics.proto", fileDescriptor_d2388e514bd0aa0e) } var fileDescriptor_d2388e514bd0aa0e = []byte{ - // 624 bytes of a gzipped FileDescriptorProto + // 631 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x53, 0xcd, 0x6e, 0xd3, 0x40, - 0x10, 0xf6, 0x26, 0x69, 0x92, 0x4e, 0x7f, 0xb0, 0x96, 0x4a, 0x58, 0x41, 0xda, 0x14, 0xc3, 0xa1, - 0x07, 0x48, 0x50, 0x39, 0x20, 0x10, 0x17, 0x07, 0xa5, 0xa5, 0x6a, 0xf3, 0xa3, 0xb5, 0x43, 0x45, - 0x2f, 0xd1, 0x26, 0xdd, 0xa6, 0xab, 0xda, 0xb1, 0xb1, 0x1d, 0xa4, 0xdc, 0xe0, 0x0d, 0x38, 0xf3, - 0x04, 0x3c, 0x01, 0xcf, 0xd0, 0x63, 0x8f, 0x15, 0x87, 0x8a, 0xba, 0x97, 0x1e, 0xfb, 0x08, 0xc8, - 0x6b, 0x27, 0x4e, 0x0f, 0xdc, 0x38, 0x65, 0xe6, 0xfb, 0xe6, 0x9b, 0x99, 0x7c, 0xe3, 0x85, 0x8a, - 0x77, 0x36, 0xaa, 0xdb, 0xee, 0xc8, 0xf3, 0xdd, 0xd0, 0xad, 0x3b, 0x3c, 0xf4, 0xc5, 0x30, 0xa8, - 0xc9, 0x0c, 0x97, 0x67, 0x78, 0xe5, 0xc5, 0x48, 0x84, 0xa7, 0x93, 0x41, 0x6d, 0xe8, 0x3a, 0xf5, - 0x91, 0x3b, 0x72, 0xeb, 0x12, 0x1e, 0x4c, 0x4e, 0x64, 0x96, 0x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, 0x52, 0xd7, 0x20, 0x04, 0x00, 0x00, } func (x WriteRequest_SourceEnum) String() string { @@ -593,7 +594,7 @@ func (this *TimeSeries) GoString() string { s = append(s, "&logproto.TimeSeries{") s = append(s, "Labels: "+fmt.Sprintf("%#v", this.Labels)+",\n") if this.Samples != nil { - vs := make([]*Sample, len(this.Samples)) + vs := make([]*LegacySample, len(this.Samples)) for i := range vs { vs[i] = &this.Samples[i] } @@ -1005,7 +1006,7 @@ func (this *TimeSeries) String() string { if this == nil { return "nil" } - repeatedStringForSamples := "[]Sample{" + repeatedStringForSamples := "[]LegacySample{" for _, f := range this.Samples { repeatedStringForSamples += fmt.Sprintf("%v", f) + "," } @@ -1353,7 +1354,7 @@ func (m *TimeSeries) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Samples = append(m.Samples, Sample{}) + m.Samples = append(m.Samples, LegacySample{}) if err := m.Samples[len(m.Samples)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } diff --git a/pkg/logproto/metrics.proto b/pkg/logproto/metrics.proto index 7c5079da53..97e85ce5c7 100644 --- a/pkg/logproto/metrics.proto +++ b/pkg/logproto/metrics.proto @@ -25,9 +25,9 @@ message WriteRequest { message WriteResponse {} message TimeSeries { - repeated LabelPair labels = 1 [(gogoproto.nullable) = false, (gogoproto.customtype) = "LabelAdapter"]; + repeated LegacyLabelPair labels = 1 [(gogoproto.nullable) = false, (gogoproto.customtype) = "LabelAdapter"]; // Sorted by time, oldest sample first. - repeated Sample samples = 2 [(gogoproto.nullable) = false]; + repeated LegacySample samples = 2 [(gogoproto.nullable) = false]; // repeated Exemplar exemplars = 3 [(gogoproto.nullable) = false]; } @@ -50,5 +50,5 @@ message MetricMetadata { } message Metric { - repeated LabelPair labels = 1 [(gogoproto.nullable) = false, (gogoproto.customtype) = "LabelAdapter"]; + repeated LegacyLabelPair labels = 1 [(gogoproto.nullable) = false, (gogoproto.customtype) = "LabelAdapter"]; } \ No newline at end of file diff --git a/pkg/logproto/timeseries.go b/pkg/logproto/timeseries.go index 869eda1a96..2bf4ae15ae 100644 --- a/pkg/logproto/timeseries.go +++ b/pkg/logproto/timeseries.go @@ -31,7 +31,7 @@ var ( New: func() interface{} { return &TimeSeries{ Labels: make([]LabelAdapter, 0, expectedLabels), - Samples: make([]Sample, 0, expectedSamplesPerSeries), + Samples: make([]LegacySample, 0, expectedSamplesPerSeries), } }, } diff --git a/pkg/logproto/timeseries_test.go b/pkg/logproto/timeseries_test.go index 7e1b9fd709..94a8c89e1c 100644 --- a/pkg/logproto/timeseries_test.go +++ b/pkg/logproto/timeseries_test.go @@ -56,7 +56,7 @@ func TestTimeseriesFromPool(t *testing.T) { t.Run("instance is cleaned before reusing", func(t *testing.T) { ts := TimeseriesFromPool() ts.Labels = []LabelAdapter{{Name: "foo", Value: "bar"}} - ts.Samples = []Sample{{Value: 1, Timestamp: 2}} + ts.Samples = []LegacySample{{Value: 1, TimestampMs: 2}} ReuseTimeseries(ts) reused := TimeseriesFromPool() diff --git a/pkg/querier/base/distributor_queryable_test.go b/pkg/querier/base/distributor_queryable_test.go index 707b63538b..d2bff5d8b4 100644 --- a/pkg/querier/base/distributor_queryable_test.go +++ b/pkg/querier/base/distributor_queryable_test.go @@ -219,28 +219,28 @@ func TestIngesterStreamingMixedResults(t *testing.T) { mint = 0 maxt = 10000 ) - s1 := []logproto.Sample{ - {Value: 1, Timestamp: 1000}, - {Value: 2, Timestamp: 2000}, - {Value: 3, Timestamp: 3000}, - {Value: 4, Timestamp: 4000}, - {Value: 5, Timestamp: 5000}, + s1 := []logproto.LegacySample{ + {Value: 1, TimestampMs: 1000}, + {Value: 2, TimestampMs: 2000}, + {Value: 3, TimestampMs: 3000}, + {Value: 4, TimestampMs: 4000}, + {Value: 5, TimestampMs: 5000}, } - s2 := []logproto.Sample{ - {Value: 1, Timestamp: 1000}, - {Value: 2.5, Timestamp: 2500}, - {Value: 3, Timestamp: 3000}, - {Value: 5.5, Timestamp: 5500}, + s2 := []logproto.LegacySample{ + {Value: 1, TimestampMs: 1000}, + {Value: 2.5, TimestampMs: 2500}, + {Value: 3, TimestampMs: 3000}, + {Value: 5.5, TimestampMs: 5500}, } - mergedSamplesS1S2 := []logproto.Sample{ - {Value: 1, Timestamp: 1000}, - {Value: 2, Timestamp: 2000}, - {Value: 2.5, Timestamp: 2500}, - {Value: 3, Timestamp: 3000}, - {Value: 4, Timestamp: 4000}, - {Value: 5, Timestamp: 5000}, - {Value: 5.5, Timestamp: 5500}, + mergedSamplesS1S2 := []logproto.LegacySample{ + {Value: 1, TimestampMs: 1000}, + {Value: 2, TimestampMs: 2000}, + {Value: 2.5, TimestampMs: 2500}, + {Value: 3, TimestampMs: 3000}, + {Value: 4, TimestampMs: 4000}, + {Value: 5, TimestampMs: 5000}, + {Value: 5.5, TimestampMs: 5500}, } d := &MockDistributor{} @@ -291,7 +291,7 @@ func TestIngesterStreamingMixedResults(t *testing.T) { require.NoError(t, seriesSet.Err()) } -func verifySeries(t *testing.T, series storage.Series, l labels.Labels, samples []logproto.Sample) { +func verifySeries(t *testing.T, series storage.Series, l labels.Labels, samples []logproto.LegacySample) { require.Equal(t, l, series.Labels()) it := series.Iterator() @@ -300,7 +300,7 @@ func verifySeries(t *testing.T, series storage.Series, l labels.Labels, samples require.Nil(t, it.Err()) ts, v := it.At() require.Equal(t, s.Value, v) - require.Equal(t, s.Timestamp, ts) + require.Equal(t, s.TimestampMs, ts) } require.False(t, it.Next()) require.Nil(t, it.Err()) @@ -330,20 +330,20 @@ func TestDistributorQuerier_LabelNames(t *testing.T) { }) } -func convertToChunks(t *testing.T, samples []logproto.Sample) []client.Chunk { +func convertToChunks(t *testing.T, samples []logproto.LegacySample) []client.Chunk { // We need to make sure that there is atleast one chunk present, // else no series will be selected. promChunk, err := encoding.NewForEncoding(encoding.Bigchunk) require.NoError(t, err) for _, s := range samples { - c, err := promChunk.Add(model.SamplePair{Value: model.SampleValue(s.Value), Timestamp: model.Time(s.Timestamp)}) + c, err := promChunk.Add(model.SamplePair{Value: model.SampleValue(s.Value), Timestamp: model.Time(s.TimestampMs)}) require.NoError(t, err) require.Nil(t, c) } clientChunks, err := chunkcompat.ToChunks([]chunk.Chunk{ - chunk.NewChunk("", 0, nil, promChunk, model.Time(samples[0].Timestamp), model.Time(samples[len(samples)-1].Timestamp)), + chunk.NewChunk("", 0, nil, promChunk, model.Time(samples[0].TimestampMs), model.Time(samples[len(samples)-1].TimestampMs)), }) require.NoError(t, err) diff --git a/pkg/querier/base/duplicates_test.go b/pkg/querier/base/duplicates_test.go index 213847a158..eac37f09d1 100644 --- a/pkg/querier/base/duplicates_test.go +++ b/pkg/querier/base/duplicates_test.go @@ -24,27 +24,27 @@ func TestDuplicatesSamples(t *testing.T) { Value: "val", }, }, - Samples: []logproto.Sample{ - {Value: 0.948569891, Timestamp: 1583946731937}, - {Value: 0.948569891, Timestamp: 1583946731937}, - {Value: 0.949927461, Timestamp: 1583946751878}, - {Value: 0.949927461, Timestamp: 1583946751878}, - {Value: 0.951334505, Timestamp: 1583946769353}, - {Value: 0.951334505, Timestamp: 1583946769353}, - {Value: 0.951334505, Timestamp: 1583946779855}, - {Value: 0.951334505, Timestamp: 1583946779855}, - {Value: 0.952676231, Timestamp: 1583946820080}, - {Value: 0.952676231, Timestamp: 1583946820080}, - {Value: 0.954158847, Timestamp: 1583946844857}, - {Value: 0.954158847, Timestamp: 1583946844857}, - {Value: 0.955572384, Timestamp: 1583946858609}, - {Value: 0.955572384, Timestamp: 1583946858609}, - {Value: 0.955572384, Timestamp: 1583946869878}, - {Value: 0.955572384, Timestamp: 1583946869878}, - {Value: 0.955572384, Timestamp: 1583946885903}, - {Value: 0.955572384, Timestamp: 1583946885903}, - {Value: 0.956823037, Timestamp: 1583946899767}, - {Value: 0.956823037, Timestamp: 1583946899767}, + Samples: []logproto.LegacySample{ + {Value: 0.948569891, TimestampMs: 1583946731937}, + {Value: 0.948569891, TimestampMs: 1583946731937}, + {Value: 0.949927461, TimestampMs: 1583946751878}, + {Value: 0.949927461, TimestampMs: 1583946751878}, + {Value: 0.951334505, TimestampMs: 1583946769353}, + {Value: 0.951334505, TimestampMs: 1583946769353}, + {Value: 0.951334505, TimestampMs: 1583946779855}, + {Value: 0.951334505, TimestampMs: 1583946779855}, + {Value: 0.952676231, TimestampMs: 1583946820080}, + {Value: 0.952676231, TimestampMs: 1583946820080}, + {Value: 0.954158847, TimestampMs: 1583946844857}, + {Value: 0.954158847, TimestampMs: 1583946844857}, + {Value: 0.955572384, TimestampMs: 1583946858609}, + {Value: 0.955572384, TimestampMs: 1583946858609}, + {Value: 0.955572384, TimestampMs: 1583946869878}, + {Value: 0.955572384, TimestampMs: 1583946869878}, + {Value: 0.955572384, TimestampMs: 1583946885903}, + {Value: 0.955572384, TimestampMs: 1583946885903}, + {Value: 0.956823037, TimestampMs: 1583946899767}, + {Value: 0.956823037, TimestampMs: 1583946899767}, }, } @@ -70,16 +70,16 @@ func TestDuplicatesSamples(t *testing.T) { } } -func dedupeSorted(samples []logproto.Sample) []logproto.Sample { - out := []logproto.Sample(nil) +func dedupeSorted(samples []logproto.LegacySample) []logproto.LegacySample { + out := []logproto.LegacySample(nil) lastTs := int64(0) for _, s := range samples { - if s.Timestamp == lastTs { + if s.TimestampMs == lastTs { continue } out = append(out, s) - lastTs = s.Timestamp + lastTs = s.TimestampMs } return out } @@ -93,8 +93,8 @@ func runPromQLAndGetJSONResult(t *testing.T, query string, ts logproto.TimeSerie MaxSamples: 1e6, }) - start := model.Time(ts.Samples[0].Timestamp).Time() - end := model.Time(ts.Samples[len(ts.Samples)-1].Timestamp).Time() + start := model.Time(ts.Samples[0].TimestampMs).Time() + end := model.Time(ts.Samples[len(ts.Samples)-1].TimestampMs).Time() q, err := engine.NewRangeQuery(tq, query, start, end, step) require.NoError(t, err) diff --git a/pkg/querier/base/timeseries_series_set.go b/pkg/querier/base/timeseries_series_set.go index 037b3ed22d..ed5f143259 100644 --- a/pkg/querier/base/timeseries_series_set.go +++ b/pkg/querier/base/timeseries_series_set.go @@ -82,7 +82,7 @@ func (t *timeSeriesSeriesIterator) Seek(s int64) bool { } t.i = sort.Search(len(t.ts.series.Samples[offset:]), func(i int) bool { - return t.ts.series.Samples[offset+i].Timestamp >= s + return t.ts.series.Samples[offset+i].TimestampMs >= s }) + offset return t.i < len(t.ts.series.Samples) @@ -93,7 +93,7 @@ func (t *timeSeriesSeriesIterator) At() (int64, float64) { if t.i < 0 || t.i >= len(t.ts.series.Samples) { return 0, 0 } - return t.ts.series.Samples[t.i].Timestamp, t.ts.series.Samples[t.i].Value + return t.ts.series.Samples[t.i].TimestampMs, t.ts.series.Samples[t.i].Value } // Next implements the SeriesIterator interface diff --git a/pkg/querier/base/timeseries_series_set_test.go b/pkg/querier/base/timeseries_series_set_test.go index 06a6d12f76..80340607d7 100644 --- a/pkg/querier/base/timeseries_series_set_test.go +++ b/pkg/querier/base/timeseries_series_set_test.go @@ -18,10 +18,10 @@ func TestTimeSeriesSeriesSet(t *testing.T) { Value: "value1", }, }, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 3.14, - Timestamp: 1234, + Value: 3.14, + TimestampMs: 1234, }, }, }, @@ -43,9 +43,9 @@ func TestTimeSeriesSeriesSet(t *testing.T) { require.False(t, ss.Next()) // Append a new sample to seek to - timeseries[0].Samples = append(timeseries[0].Samples, logproto.Sample{ - Value: 1.618, - Timestamp: 2345, + timeseries[0].Samples = append(timeseries[0].Samples, logproto.LegacySample{ + Value: 1.618, + TimestampMs: 2345, }) ss = newTimeSeriesSeriesSet(timeseries) @@ -66,18 +66,18 @@ func TestTimeSeriesIterator(t *testing.T) { Value: "value1", }, }, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 3.14, - Timestamp: 1234, + Value: 3.14, + TimestampMs: 1234, }, { - Value: 3.14, - Timestamp: 1235, + Value: 3.14, + TimestampMs: 1235, }, { - Value: 3.14, - Timestamp: 1236, + Value: 3.14, + TimestampMs: 1236, }, }, }, diff --git a/pkg/querier/queryrange/codec.go b/pkg/querier/queryrange/codec.go index b74a5c6a76..ae90f1a8c4 100644 --- a/pkg/querier/queryrange/codec.go +++ b/pkg/querier/queryrange/codec.go @@ -737,11 +737,11 @@ func toProtoMatrix(m loghttp.Matrix) []queryrangebase.SampleStream { } for _, stream := range m { - samples := make([]logproto.Sample, 0, len(stream.Values)) + samples := make([]logproto.LegacySample, 0, len(stream.Values)) for _, s := range stream.Values { - samples = append(samples, logproto.Sample{ - Value: float64(s.Value), - Timestamp: int64(s.Timestamp), + samples = append(samples, logproto.LegacySample{ + Value: float64(s.Value), + TimestampMs: int64(s.Timestamp), }) } res = append(res, queryrangebase.SampleStream{ @@ -760,9 +760,9 @@ func toProtoVector(v loghttp.Vector) []queryrangebase.SampleStream { } for _, s := range v { res = append(res, queryrangebase.SampleStream{ - Samples: []logproto.Sample{{ - Value: float64(s.Value), - Timestamp: int64(s.Timestamp), + Samples: []logproto.LegacySample{{ + Value: float64(s.Value), + TimestampMs: int64(s.Timestamp), }}, Labels: logproto.FromMetricsToLabelAdapters(s.Metric), }) diff --git a/pkg/querier/queryrange/codec_test.go b/pkg/querier/queryrange/codec_test.go index 85617f0346..aa5075be45 100644 --- a/pkg/querier/queryrange/codec_test.go +++ b/pkg/querier/queryrange/codec_test.go @@ -966,11 +966,11 @@ var ( sampleStreams = []queryrangebase.SampleStream{ { Labels: []logproto.LabelAdapter{{Name: "filename", Value: "/var/hostlog/apport.log"}, {Name: "job", Value: "varlogs"}}, - Samples: []logproto.Sample{{Value: 0.013333333333333334, Timestamp: 1568404331324}}, + Samples: []logproto.LegacySample{{Value: 0.013333333333333334, TimestampMs: 1568404331324}}, }, { Labels: []logproto.LabelAdapter{{Name: "filename", Value: "/var/hostlog/syslog"}, {Name: "job", Value: "varlogs"}}, - Samples: []logproto.Sample{{Value: 3.45, Timestamp: 1568404331324}, {Value: 4.45, Timestamp: 1568404331339}}, + Samples: []logproto.LegacySample{{Value: 3.45, TimestampMs: 1568404331324}, {Value: 4.45, TimestampMs: 1568404331339}}, }, } streamsString = `{ @@ -1247,12 +1247,12 @@ func generateMatrix() (res []queryrangebase.SampleStream) { for i := 0; i < 100; i++ { s := queryrangebase.SampleStream{ Labels: []logproto.LabelAdapter{}, - Samples: []logproto.Sample{}, + Samples: []logproto.LegacySample{}, } for j := 0; j < 1000; j++ { - s.Samples = append(s.Samples, logproto.Sample{ - Value: float64(j), - Timestamp: int64(j), + s.Samples = append(s.Samples, logproto.LegacySample{ + Value: float64(j), + TimestampMs: int64(j), }) } res = append(res, s) diff --git a/pkg/querier/queryrange/downstreamer.go b/pkg/querier/queryrange/downstreamer.go index de417f5ec0..976e878f2f 100644 --- a/pkg/querier/queryrange/downstreamer.go +++ b/pkg/querier/queryrange/downstreamer.go @@ -157,7 +157,7 @@ func sampleStreamToMatrix(streams []queryrangebase.SampleStream) parser.Value { x.Points = make([]promql.Point, 0, len(stream.Samples)) for _, sample := range stream.Samples { x.Points = append(x.Points, promql.Point{ - T: sample.Timestamp, + T: sample.TimestampMs, V: sample.Value, }) } @@ -177,7 +177,7 @@ func sampleStreamToVector(streams []queryrangebase.SampleStream) parser.Value { } x.Point = promql.Point{ - T: stream.Samples[0].Timestamp, + T: stream.Samples[0].TimestampMs, V: stream.Samples[0].Value, } diff --git a/pkg/querier/queryrange/downstreamer_test.go b/pkg/querier/queryrange/downstreamer_test.go index 76f6d0b567..80cd7d946c 100644 --- a/pkg/querier/queryrange/downstreamer_test.go +++ b/pkg/querier/queryrange/downstreamer_test.go @@ -23,35 +23,35 @@ func testSampleStreams() []queryrangebase.SampleStream { return []queryrangebase.SampleStream{ { Labels: []logproto.LabelAdapter{{Name: "foo", Value: "bar"}}, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 0, - Timestamp: 0, + Value: 0, + TimestampMs: 0, }, { - Value: 1, - Timestamp: 1, + Value: 1, + TimestampMs: 1, }, { - Value: 2, - Timestamp: 2, + Value: 2, + TimestampMs: 2, }, }, }, { Labels: []logproto.LabelAdapter{{Name: "bazz", Value: "buzz"}}, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 4, - Timestamp: 4, + Value: 4, + TimestampMs: 4, }, { - Value: 5, - Timestamp: 5, + Value: 5, + TimestampMs: 5, }, { - Value: 6, - Timestamp: 6, + Value: 6, + TimestampMs: 6, }, }, }, diff --git a/pkg/querier/queryrange/prometheus.go b/pkg/querier/queryrange/prometheus.go index 9f4bfa66c2..7733c5d52f 100644 --- a/pkg/querier/queryrange/prometheus.go +++ b/pkg/querier/queryrange/prometheus.go @@ -79,7 +79,7 @@ func (p *LokiPromResponse) marshalVector() ([]byte, error) { } vec[i] = model.Sample{ Metric: model.Metric(lbs), - Timestamp: model.Time(v.Samples[0].Timestamp), + Timestamp: model.Time(v.Samples[0].TimestampMs), Value: model.SampleValue(v.Samples[0].Value), } } diff --git a/pkg/querier/queryrange/prometheus_test.go b/pkg/querier/queryrange/prometheus_test.go index d7ab1a5ebe..261b042079 100644 --- a/pkg/querier/queryrange/prometheus_test.go +++ b/pkg/querier/queryrange/prometheus_test.go @@ -75,18 +75,18 @@ func Test_encodePromResponse(t *testing.T) { Labels: []logproto.LabelAdapter{ {Name: "foo", Value: "bar"}, }, - Samples: []logproto.Sample{ - {Value: 1, Timestamp: 1000}, - {Value: 1, Timestamp: 2000}, + Samples: []logproto.LegacySample{ + {Value: 1, TimestampMs: 1000}, + {Value: 1, TimestampMs: 2000}, }, }, { Labels: []logproto.LabelAdapter{ {Name: "foo", Value: "buzz"}, }, - Samples: []logproto.Sample{ - {Value: 4, Timestamp: 1000}, - {Value: 5, Timestamp: 2000}, + Samples: []logproto.LegacySample{ + {Value: 4, TimestampMs: 1000}, + {Value: 5, TimestampMs: 2000}, }, }, }, @@ -123,16 +123,16 @@ func Test_encodePromResponse(t *testing.T) { Labels: []logproto.LabelAdapter{ {Name: "foo", Value: "bar"}, }, - Samples: []logproto.Sample{ - {Value: 1, Timestamp: 1000}, + Samples: []logproto.LegacySample{ + {Value: 1, TimestampMs: 1000}, }, }, { Labels: []logproto.LabelAdapter{ {Name: "foo", Value: "buzz"}, }, - Samples: []logproto.Sample{ - {Value: 4, Timestamp: 1000}, + Samples: []logproto.LegacySample{ + {Value: 4, TimestampMs: 1000}, }, }, }, diff --git a/pkg/querier/queryrange/queryrangebase/marshaling_test.go b/pkg/querier/queryrange/queryrangebase/marshaling_test.go index 0d936b433d..60814d910a 100644 --- a/pkg/querier/queryrange/queryrangebase/marshaling_test.go +++ b/pkg/querier/queryrange/queryrangebase/marshaling_test.go @@ -60,11 +60,11 @@ func mockPrometheusResponse(numSeries, numSamplesPerSeries int) *PrometheusRespo stream := make([]SampleStream, numSeries) for s := 0; s < numSeries; s++ { // Generate random samples. - samples := make([]logproto.Sample, numSamplesPerSeries) + samples := make([]logproto.LegacySample, numSamplesPerSeries) for i := 0; i < numSamplesPerSeries; i++ { - samples[i] = logproto.Sample{ - Value: rand.Float64(), - Timestamp: int64(i), + samples[i] = logproto.LegacySample{ + Value: rand.Float64(), + TimestampMs: int64(i), } } diff --git a/pkg/querier/queryrange/queryrangebase/query_range.go b/pkg/querier/queryrange/queryrangebase/query_range.go index 2730838896..9e608485e7 100644 --- a/pkg/querier/queryrange/queryrangebase/query_range.go +++ b/pkg/querier/queryrange/queryrangebase/query_range.go @@ -138,7 +138,7 @@ func (resp *PrometheusResponse) minTime() int64 { if len(result[0].Samples) == 0 { return -1 } - return result[0].Samples[0].Timestamp + return result[0].Samples[0].TimestampMs } // NewEmptyPrometheusResponse returns an empty successful Prometheus query range response. @@ -357,8 +357,8 @@ func (prometheusCodec) EncodeResponse(ctx context.Context, res Response) (*http. // UnmarshalJSON implements json.Unmarshaler. func (s *SampleStream) UnmarshalJSON(data []byte) error { var stream struct { - Metric model.Metric `json:"metric"` - Values []logproto.Sample `json:"values"` + Metric model.Metric `json:"metric"` + Values []logproto.LegacySample `json:"values"` } if err := json.Unmarshal(data, &stream); err != nil { return err @@ -371,8 +371,8 @@ func (s *SampleStream) UnmarshalJSON(data []byte) error { // MarshalJSON implements json.Marshaler. func (s *SampleStream) MarshalJSON() ([]byte, error) { stream := struct { - Metric model.Metric `json:"metric"` - Values []logproto.Sample `json:"values"` + Metric model.Metric `json:"metric"` + Values []logproto.LegacySample `json:"values"` }{ Metric: logproto.FromLabelAdaptersToMetric(s.Labels), Values: s.Samples, @@ -394,12 +394,12 @@ func matrixMerge(resps []*PrometheusResponse) []SampleStream { // We need to make sure we don't repeat samples. This causes some visualisations to be broken in Grafana. // The prometheus API is inclusive of start and end timestamps. if len(existing.Samples) > 0 && len(stream.Samples) > 0 { - existingEndTs := existing.Samples[len(existing.Samples)-1].Timestamp - if existingEndTs == stream.Samples[0].Timestamp { + existingEndTs := existing.Samples[len(existing.Samples)-1].TimestampMs + if existingEndTs == stream.Samples[0].TimestampMs { // Typically this the cases where only 1 sample point overlap, // so optimize with simple code. stream.Samples = stream.Samples[1:] - } else if existingEndTs > stream.Samples[0].Timestamp { + } else if existingEndTs > stream.Samples[0].TimestampMs { // Overlap might be big, use heavier algorithm to remove overlap. stream.Samples = sliceSamples(stream.Samples, existingEndTs) } // else there is no overlap, yay! @@ -427,17 +427,17 @@ func matrixMerge(resps []*PrometheusResponse) []SampleStream { // return a sub slice whose first element's is the smallest timestamp that is strictly // bigger than the given minTs. Empty slice is returned if minTs is bigger than all the // timestamps in samples. -func sliceSamples(samples []logproto.Sample, minTs int64) []logproto.Sample { - if len(samples) <= 0 || minTs < samples[0].Timestamp { +func sliceSamples(samples []logproto.LegacySample, minTs int64) []logproto.LegacySample { + if len(samples) <= 0 || minTs < samples[0].TimestampMs { return samples } - if len(samples) > 0 && minTs > samples[len(samples)-1].Timestamp { + if len(samples) > 0 && minTs > samples[len(samples)-1].TimestampMs { return samples[len(samples):] } searchResult := sort.Search(len(samples), func(i int) bool { - return samples[i].Timestamp > minTs + return samples[i].TimestampMs > minTs }) return samples[searchResult:] diff --git a/pkg/querier/queryrange/queryrangebase/query_range_test.go b/pkg/querier/queryrange/queryrangebase/query_range_test.go index 81b7f81595..5604e59dcd 100644 --- a/pkg/querier/queryrange/queryrangebase/query_range_test.go +++ b/pkg/querier/queryrange/queryrangebase/query_range_test.go @@ -187,9 +187,9 @@ func TestMergeAPIResponses(t *testing.T) { Result: []SampleStream{ { Labels: []logproto.LabelAdapter{}, - Samples: []logproto.Sample{ - {Value: 0, Timestamp: 0}, - {Value: 1, Timestamp: 1}, + Samples: []logproto.LegacySample{ + {Value: 0, TimestampMs: 0}, + {Value: 1, TimestampMs: 1}, }, }, }, @@ -201,9 +201,9 @@ func TestMergeAPIResponses(t *testing.T) { Result: []SampleStream{ { Labels: []logproto.LabelAdapter{}, - Samples: []logproto.Sample{ - {Value: 2, Timestamp: 2}, - {Value: 3, Timestamp: 3}, + Samples: []logproto.LegacySample{ + {Value: 2, TimestampMs: 2}, + {Value: 3, TimestampMs: 3}, }, }, }, @@ -217,11 +217,11 @@ func TestMergeAPIResponses(t *testing.T) { Result: []SampleStream{ { Labels: []logproto.LabelAdapter{}, - Samples: []logproto.Sample{ - {Value: 0, Timestamp: 0}, - {Value: 1, Timestamp: 1}, - {Value: 2, Timestamp: 2}, - {Value: 3, Timestamp: 3}, + Samples: []logproto.LegacySample{ + {Value: 0, TimestampMs: 0}, + {Value: 1, TimestampMs: 1}, + {Value: 2, TimestampMs: 2}, + {Value: 3, TimestampMs: 3}, }, }, }, @@ -242,11 +242,11 @@ func TestMergeAPIResponses(t *testing.T) { Result: []SampleStream{ { Labels: []logproto.LabelAdapter{{Name: "a", Value: "b"}, {Name: "c", Value: "d"}}, - Samples: []logproto.Sample{ - {Value: 0, Timestamp: 0}, - {Value: 1, Timestamp: 1000}, - {Value: 2, Timestamp: 2000}, - {Value: 3, Timestamp: 3000}, + Samples: []logproto.LegacySample{ + {Value: 0, TimestampMs: 0}, + {Value: 1, TimestampMs: 1000}, + {Value: 2, TimestampMs: 2000}, + {Value: 3, TimestampMs: 3000}, }, }, }, @@ -267,10 +267,10 @@ func TestMergeAPIResponses(t *testing.T) { Result: []SampleStream{ { Labels: []logproto.LabelAdapter{{Name: "a", Value: "b"}, {Name: "c", Value: "d"}}, - Samples: []logproto.Sample{ - {Value: 1, Timestamp: 1000}, - {Value: 2, Timestamp: 2000}, - {Value: 3, Timestamp: 3000}, + Samples: []logproto.LegacySample{ + {Value: 1, TimestampMs: 1000}, + {Value: 2, TimestampMs: 2000}, + {Value: 3, TimestampMs: 3000}, }, }, }, @@ -290,12 +290,12 @@ func TestMergeAPIResponses(t *testing.T) { Result: []SampleStream{ { Labels: []logproto.LabelAdapter{{Name: "a", Value: "b"}, {Name: "c", Value: "d"}}, - Samples: []logproto.Sample{ - {Value: 1, Timestamp: 1000}, - {Value: 2, Timestamp: 2000}, - {Value: 3, Timestamp: 3000}, - {Value: 4, Timestamp: 4000}, - {Value: 5, Timestamp: 5000}, + Samples: []logproto.LegacySample{ + {Value: 1, TimestampMs: 1000}, + {Value: 2, TimestampMs: 2000}, + {Value: 3, TimestampMs: 3000}, + {Value: 4, TimestampMs: 4000}, + {Value: 5, TimestampMs: 5000}, }, }, }, @@ -315,11 +315,11 @@ func TestMergeAPIResponses(t *testing.T) { Result: []SampleStream{ { Labels: []logproto.LabelAdapter{{Name: "a", Value: "b"}, {Name: "c", Value: "d"}}, - Samples: []logproto.Sample{ - {Value: 2, Timestamp: 2000}, - {Value: 3, Timestamp: 3000}, - {Value: 4, Timestamp: 4000}, - {Value: 5, Timestamp: 5000}, + Samples: []logproto.LegacySample{ + {Value: 2, TimestampMs: 2000}, + {Value: 3, TimestampMs: 3000}, + {Value: 4, TimestampMs: 4000}, + {Value: 5, TimestampMs: 5000}, }, }, }, diff --git a/pkg/querier/queryrange/queryrangebase/queryable_test.go b/pkg/querier/queryrange/queryrangebase/queryable_test.go index b0193a86c4..a1325a86c8 100644 --- a/pkg/querier/queryrange/queryrangebase/queryable_test.go +++ b/pkg/querier/queryrange/queryrangebase/queryable_test.go @@ -95,14 +95,14 @@ func TestSelect(t *testing.T) { {Name: "a", Value: "a1"}, {Name: "b", Value: "b1"}, }, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 1, - Timestamp: 1, + Value: 1, + TimestampMs: 1, }, { - Value: 2, - Timestamp: 2, + Value: 2, + TimestampMs: 2, }, }, }, @@ -111,14 +111,14 @@ func TestSelect(t *testing.T) { {Name: "a", Value: "a1"}, {Name: "b", Value: "b1"}, }, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 8, - Timestamp: 1, + Value: 8, + TimestampMs: 1, }, { - Value: 9, - Timestamp: 2, + Value: 9, + TimestampMs: 2, }, }, }, @@ -145,14 +145,14 @@ func TestSelect(t *testing.T) { {Name: "a", Value: "a1"}, {Name: "b", Value: "b1"}, }, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 1, - Timestamp: 1, + Value: 1, + TimestampMs: 1, }, { - Value: 2, - Timestamp: 2, + Value: 2, + TimestampMs: 2, }, }, }, @@ -161,14 +161,14 @@ func TestSelect(t *testing.T) { {Name: "a", Value: "a1"}, {Name: "b", Value: "b1"}, }, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 8, - Timestamp: 1, + Value: 8, + TimestampMs: 1, }, { - Value: 9, - Timestamp: 2, + Value: 9, + TimestampMs: 2, }, }, }, @@ -222,10 +222,10 @@ func TestSelectConcurrent(t *testing.T) { Labels: []logproto.LabelAdapter{ {Name: "a", Value: "1"}, }, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 1, - Timestamp: 1, + Value: 1, + TimestampMs: 1, }, }, }, diff --git a/pkg/querier/queryrange/queryrangebase/queryrange.pb.go b/pkg/querier/queryrange/queryrangebase/queryrange.pb.go index 057d8e8d8b..dd5ff378e1 100644 --- a/pkg/querier/queryrange/queryrangebase/queryrange.pb.go +++ b/pkg/querier/queryrange/queryrangebase/queryrange.pb.go @@ -361,7 +361,7 @@ func (m *PrometheusData) GetResult() []SampleStream { type SampleStream struct { Labels []github_com_grafana_loki_pkg_logproto.LabelAdapter `protobuf:"bytes,1,rep,name=labels,proto3,customtype=github.com/grafana/loki/pkg/logproto.LabelAdapter" json:"metric"` - Samples []logproto.Sample `protobuf:"bytes,2,rep,name=samples,proto3" json:"values"` + Samples []logproto.LegacySample `protobuf:"bytes,2,rep,name=samples,proto3" json:"values"` } func (m *SampleStream) Reset() { *m = SampleStream{} } @@ -396,7 +396,7 @@ func (m *SampleStream) XXX_DiscardUnknown() { var xxx_messageInfo_SampleStream proto.InternalMessageInfo -func (m *SampleStream) GetSamples() []logproto.Sample { +func (m *SampleStream) GetSamples() []logproto.LegacySample { if m != nil { return m.Samples } @@ -582,62 +582,62 @@ func init() { } var fileDescriptor_4cc6a0c1d6b614c4 = []byte{ - // 867 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x55, 0x3f, 0x8f, 0x1b, 0x45, - 0x14, 0xf7, 0x9e, 0xed, 0xb5, 0xfd, 0x2e, 0x72, 0x8e, 0xb9, 0x28, 0x59, 0x1f, 0xb0, 0x6b, 0xb9, - 0xc1, 0x48, 0xc9, 0x5a, 0x1c, 0x82, 0x02, 0x29, 0x48, 0xb7, 0xb9, 0x48, 0x49, 0x14, 0x41, 0x34, - 0x17, 0x51, 0xd0, 0xa0, 0xb1, 0x77, 0xb2, 0xb7, 0xba, 0xfd, 0x97, 0x99, 0x59, 0x84, 0x3b, 0x2a, - 0x6a, 0x4a, 0x3e, 0x02, 0x05, 0x0d, 0x3d, 0x1f, 0x20, 0xe5, 0x95, 0x11, 0xc5, 0xc2, 0xf9, 0x1a, - 0xb4, 0x55, 0x3e, 0x02, 0x9a, 0x99, 0x5d, 0x7b, 0xcf, 0x07, 0xa1, 0xa0, 0xb9, 0x7b, 0x7f, 0x7e, - 0xef, 0xcf, 0xfc, 0xde, 0xdb, 0x67, 0xf8, 0x34, 0x3b, 0x0b, 0x66, 0x2f, 0x73, 0xca, 0x42, 0xca, - 0xd4, 0xff, 0x25, 0x23, 0x49, 0x40, 0x1b, 0xe2, 0x9c, 0xf0, 0xa6, 0xea, 0x66, 0x2c, 0x15, 0x29, - 0x1a, 0x5e, 0x05, 0x1c, 0xdc, 0x0b, 0x42, 0x71, 0x9a, 0xcf, 0xdd, 0x45, 0x1a, 0xcf, 0x82, 0x34, - 0x48, 0x67, 0x0a, 0x36, 0xcf, 0x5f, 0x28, 0x4d, 0x29, 0x4a, 0xd2, 0xe1, 0x07, 0x76, 0x90, 0xa6, - 0x41, 0x44, 0x37, 0x28, 0x3f, 0x67, 0x44, 0x84, 0x69, 0x52, 0xf9, 0x47, 0xdb, 0x7e, 0x92, 0x2c, - 0x2b, 0xd7, 0xbb, 0xb2, 0xe3, 0x28, 0x0d, 0x74, 0xce, 0x5a, 0xd0, 0xce, 0xc9, 0x09, 0xdc, 0x79, - 0xc6, 0xd2, 0x98, 0x8a, 0x53, 0x9a, 0x73, 0x4c, 0x5f, 0xe6, 0x94, 0x8b, 0x47, 0x94, 0xf8, 0x94, - 0xa1, 0x11, 0x74, 0xbe, 0x20, 0x31, 0xb5, 0x8c, 0xb1, 0x31, 0x1d, 0x78, 0xdd, 0xb2, 0x70, 0x8c, - 0x7b, 0x58, 0x99, 0xd0, 0xfb, 0x60, 0x7e, 0x45, 0xa2, 0x9c, 0x72, 0x6b, 0x67, 0xdc, 0xde, 0x38, - 0x2b, 0xe3, 0xe4, 0x7c, 0x07, 0xde, 0xb9, 0x96, 0x15, 0x21, 0xe8, 0x64, 0x44, 0x9c, 0xea, 0x7c, - 0x58, 0xc9, 0xe8, 0x16, 0x74, 0xb9, 0x20, 0x4c, 0x58, 0x3b, 0x63, 0x63, 0xda, 0xc6, 0x5a, 0x41, - 0x7b, 0xd0, 0xa6, 0x89, 0x6f, 0xb5, 0x95, 0x4d, 0x8a, 0x32, 0x96, 0x0b, 0x9a, 0x59, 0x1d, 0x65, - 0x52, 0x32, 0xba, 0x0f,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x63, 0x23, 0x62, 0x83, 0x44, 0x1f, - 0x42, 0x57, 0x29, 0x6a, 0x2b, 0x06, 0xde, 0x7e, 0x59, 0x38, 0x37, 0x55, 0x48, 0x03, 0xae, 0x11, - 0xe8, 0xf1, 0x66, 0x10, 0x5d, 0x35, 0x88, 0xe9, 0xdb, 0x06, 0xd1, 0x64, 0xf7, 0xda, 0x24, 0x7e, - 0x30, 0x60, 0x78, 0xf5, 0x75, 0xc8, 0x05, 0xc0, 0x94, 0xe7, 0x91, 0x50, 0x0f, 0xd0, 0x9c, 0x0d, - 0xcb, 0xc2, 0x01, 0xb6, 0xb6, 0xe2, 0x06, 0x02, 0x1d, 0x83, 0xa9, 0x35, 0x35, 0x95, 0xdd, 0xc3, - 0xf7, 0xb6, 0x9b, 0x39, 0x21, 0x71, 0x16, 0xd1, 0x13, 0xc1, 0x28, 0x89, 0xbd, 0x61, 0xc5, 0x9d, - 0xa9, 0xb3, 0xe1, 0x2a, 0x76, 0xf2, 0x9b, 0x01, 0x37, 0x9a, 0x40, 0x94, 0x81, 0x19, 0x91, 0x39, - 0x8d, 0xe4, 0xd8, 0x64, 0xda, 0x7d, 0x77, 0xfd, 0xb1, 0x3f, 0x95, 0xf6, 0x67, 0x24, 0x64, 0xde, - 0x03, 0x99, 0xed, 0xf7, 0xc2, 0xf9, 0xa8, 0x79, 0x7f, 0x18, 0x79, 0x41, 0x12, 0x32, 0x8b, 0xd2, - 0xb3, 0x70, 0xd6, 0xbc, 0x16, 0x3a, 0xee, 0xc8, 0x27, 0x99, 0xa0, 0x4c, 0xb6, 0x10, 0x53, 0xc1, - 0xc2, 0x05, 0xae, 0xea, 0xa0, 0xcf, 0xa0, 0xc7, 0x55, 0x07, 0xbc, 0x7a, 0xc9, 0xde, 0xa6, 0xa4, - 0x6e, 0x6d, 0xd3, 0xfd, 0xb7, 0x6a, 0xe5, 0x70, 0x1d, 0x30, 0x49, 0x60, 0x28, 0xbf, 0x21, 0xea, - 0xaf, 0xd7, 0x6e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fd, 0xb7, 0xed, 0xc0, 0x7f, 0xfe, 0xc6, - 0xcd, 0x4d, 0xf5, 0x9c, 0x8f, 0xff, 0x0e, 0x00, 0x00, 0xff, 0xff, 0x8d, 0xb5, 0x5d, 0xa7, 0x13, - 0x07, 0x00, 0x00, + // 869 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x55, 0x3f, 0x6f, 0xdb, 0x46, + 0x14, 0x17, 0x4d, 0x89, 0x92, 0xce, 0x81, 0x92, 0x5e, 0x82, 0x84, 0x72, 0x5b, 0x52, 0xe0, 0x52, + 0x15, 0x48, 0x28, 0xd4, 0x45, 0xbb, 0xa5, 0xa8, 0x19, 0x07, 0x48, 0x02, 0xa3, 0x0d, 0xce, 0x41, + 0x87, 0x2e, 0xc5, 0x49, 0x7c, 0xa1, 0x09, 0xf3, 0x5f, 0xee, 0x8e, 0x41, 0xb5, 0x75, 0xea, 0xdc, + 0xb1, 0x1f, 0xa1, 0x43, 0x97, 0x7e, 0x0b, 0x8f, 0x1e, 0x83, 0x0e, 0x6c, 0x2d, 0x2f, 0x05, 0xa7, + 0x7c, 0x84, 0x82, 0x77, 0xa4, 0x44, 0xcb, 0x6d, 0x3a, 0x74, 0xb1, 0xdf, 0x9f, 0xdf, 0xfb, 0x73, + 0xbf, 0xf7, 0xf8, 0x84, 0x3e, 0xcf, 0x4e, 0x83, 0xd9, 0xab, 0x1c, 0x58, 0x08, 0x4c, 0xfe, 0x5f, + 0x32, 0x9a, 0x04, 0xd0, 0x12, 0xe7, 0x94, 0xb7, 0x55, 0x37, 0x63, 0xa9, 0x48, 0xf1, 0xe8, 0x2a, + 0x60, 0xef, 0x41, 0x10, 0x8a, 0x93, 0x7c, 0xee, 0x2e, 0xd2, 0x78, 0x16, 0xa4, 0x41, 0x3a, 0x93, + 0xb0, 0x79, 0xfe, 0x52, 0x6a, 0x52, 0x91, 0x92, 0x0a, 0xdf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 0x21, 0x43, 0x81, 0xb0, + 0xdd, 0x5c, 0xa0, 0xaa, 0x94, 0xee, 0x0d, 0xcb, 0xc2, 0x56, 0x86, 0xe6, 0x18, 0x8d, 0xd5, 0x31, + 0x92, 0x07, 0x4a, 0x75, 0x02, 0x89, 0xaf, 0xae, 0xd2, 0x04, 0x0d, 0x04, 0xa3, 0x0b, 0xf8, 0x2e, + 0xf4, 0xeb, 0x1d, 0x6c, 0x96, 0x45, 0x9a, 0x9f, 0xfa, 0xf8, 0x0b, 0x34, 0x60, 0xf5, 0x93, 0xea, + 0x23, 0x75, 0xe7, 0xda, 0x91, 0x3a, 0x48, 0x96, 0xde, 0x8d, 0xb2, 0xb0, 0xd7, 0x48, 0xb2, 0x96, + 0x9e, 0x75, 0x07, 0xfa, 0xad, 0xae, 0x73, 0x5f, 0xd1, 0xd3, 0x3a, 0x2c, 0x7b, 0x68, 0xe0, 0x87, + 0x9c, 0xce, 0x23, 0xf0, 0x65, 0xe3, 0x03, 0xb2, 0xd6, 0x3d, 0x7e, 0x7e, 0x61, 0x75, 0xde, 0x5c, + 0x58, 0x9d, 0xb7, 0x17, 0x96, 0xf6, 0xc3, 0xca, 0xd2, 0x7e, 0x59, 0x59, 0xda, 0xd9, 0xca, 0xd2, + 0xce, 0x57, 0x96, 0xf6, 0xe7, 0xca, 0xd2, 0xfe, 0x5a, 0x59, 0x9d, 0xb7, 0x2b, 0x4b, 0xfb, 0xe9, + 0xd2, 0xea, 0x9c, 0x5f, 0x5a, 0x9d, 0x37, 0x97, 0x56, 0xe7, 0xdb, 0x87, 0xef, 0xda, 0x84, 0xff, + 0xfc, 0xbd, 0x9b, 0x1b, 0xf2, 0x39, 0x9f, 0xfe, 0x1d, 0x00, 0x00, 0xff, 0xff, 0xb3, 0x10, 0x2b, + 0x2c, 0x1f, 0x07, 0x00, 0x00, } func (this *PrometheusRequestHeader) Equal(that interface{}) bool { @@ -1035,7 +1035,7 @@ func (this *SampleStream) GoString() string { s = append(s, "&queryrangebase.SampleStream{") s = append(s, "Labels: "+fmt.Sprintf("%#v", this.Labels)+",\n") if this.Samples != nil { - vs := make([]*logproto.Sample, len(this.Samples)) + vs := make([]*logproto.LegacySample, len(this.Samples)) for i := range vs { vs[i] = &this.Samples[i] } @@ -1845,7 +1845,7 @@ func (this *SampleStream) String() string { if this == nil { return "nil" } - repeatedStringForSamples := "[]Sample{" + repeatedStringForSamples := "[]LegacySample{" for _, f := range this.Samples { repeatedStringForSamples += fmt.Sprintf("%v", f) + "," } @@ -2839,7 +2839,7 @@ func (m *SampleStream) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Samples = append(m.Samples, logproto.Sample{}) + m.Samples = append(m.Samples, logproto.LegacySample{}) if err := m.Samples[len(m.Samples)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } diff --git a/pkg/querier/queryrange/queryrangebase/queryrange.proto b/pkg/querier/queryrange/queryrangebase/queryrange.proto index 24e369d21d..f49d3e0a60 100644 --- a/pkg/querier/queryrange/queryrangebase/queryrange.proto +++ b/pkg/querier/queryrange/queryrangebase/queryrange.proto @@ -46,8 +46,8 @@ message PrometheusData { } message SampleStream { - repeated logproto.LabelPair labels = 1 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "metric", (gogoproto.customtype) = "github.com/grafana/loki/pkg/logproto.LabelAdapter"]; - repeated logproto.Sample samples = 2 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "values"]; + repeated logproto.LegacyLabelPair labels = 1 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "metric", (gogoproto.customtype) = "github.com/grafana/loki/pkg/logproto.LabelAdapter"]; + repeated logproto.LegacySample samples = 2 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "values"]; } message CachedResponse { diff --git a/pkg/querier/queryrange/queryrangebase/querysharding_test.go b/pkg/querier/queryrange/queryrangebase/querysharding_test.go index 89b0bd0e05..d53a64246f 100644 --- a/pkg/querier/queryrange/queryrangebase/querysharding_test.go +++ b/pkg/querier/queryrange/queryrangebase/querysharding_test.go @@ -126,14 +126,14 @@ func sampleMatrixResponse() *PrometheusResponse { {Name: "a", Value: "a1"}, {Name: "b", Value: "b1"}, }, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Timestamp: 5, - Value: 1, + TimestampMs: 5, + Value: 1, }, { - Timestamp: 10, - Value: 2, + TimestampMs: 10, + Value: 2, }, }, }, @@ -142,14 +142,14 @@ func sampleMatrixResponse() *PrometheusResponse { {Name: "a", Value: "a1"}, {Name: "b", Value: "b1"}, }, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Timestamp: 5, - Value: 8, + TimestampMs: 5, + Value: 8, }, { - Timestamp: 10, - Value: 9, + TimestampMs: 10, + Value: 9, }, }, }, diff --git a/pkg/querier/queryrange/queryrangebase/results_cache.go b/pkg/querier/queryrange/queryrangebase/results_cache.go index b9ba878fae..8f2fa87614 100644 --- a/pkg/querier/queryrange/queryrangebase/results_cache.go +++ b/pkg/querier/queryrange/queryrangebase/results_cache.go @@ -631,10 +631,10 @@ func extractMatrix(start, end int64, matrix []SampleStream) []SampleStream { func extractSampleStream(start, end int64, stream SampleStream) (SampleStream, bool) { result := SampleStream{ Labels: stream.Labels, - Samples: make([]logproto.Sample, 0, len(stream.Samples)), + Samples: make([]logproto.LegacySample, 0, len(stream.Samples)), } for _, sample := range stream.Samples { - if start <= sample.Timestamp && sample.Timestamp <= end { + if start <= sample.TimestampMs && sample.TimestampMs <= end { result.Samples = append(result.Samples, sample) } } diff --git a/pkg/querier/queryrange/queryrangebase/results_cache_test.go b/pkg/querier/queryrange/queryrangebase/results_cache_test.go index 8296c6b978..f5dd7ec238 100644 --- a/pkg/querier/queryrange/queryrangebase/results_cache_test.go +++ b/pkg/querier/queryrange/queryrangebase/results_cache_test.go @@ -61,9 +61,9 @@ var ( Labels: []logproto.LabelAdapter{ {Name: "foo", Value: "bar"}, }, - Samples: []logproto.Sample{ - {Value: 137, Timestamp: 1536673680000}, - {Value: 137, Timestamp: 1536673780000}, + Samples: []logproto.LegacySample{ + {Value: 137, TimestampMs: 1536673680000}, + {Value: 137, TimestampMs: 1536673780000}, }, }, }, @@ -72,11 +72,11 @@ var ( ) func mkAPIResponse(start, end, step int64) *PrometheusResponse { - var samples []logproto.Sample + var samples []logproto.LegacySample for i := start; i <= end; i += step { - samples = append(samples, logproto.Sample{ - Timestamp: i, - Value: float64(i), + samples = append(samples, logproto.LegacySample{ + TimestampMs: i, + Value: float64(i), }) } diff --git a/pkg/querier/queryrange/queryrangebase/series_test.go b/pkg/querier/queryrange/queryrangebase/series_test.go index 539f610736..2443697106 100644 --- a/pkg/querier/queryrange/queryrangebase/series_test.go +++ b/pkg/querier/queryrange/queryrangebase/series_test.go @@ -19,14 +19,14 @@ func Test_ResponseToSamples(t *testing.T) { {Name: "a", Value: "a1"}, {Name: "b", Value: "b1"}, }, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 1, - Timestamp: 1, + Value: 1, + TimestampMs: 1, }, { - Value: 2, - Timestamp: 2, + Value: 2, + TimestampMs: 2, }, }, }, @@ -35,14 +35,14 @@ func Test_ResponseToSamples(t *testing.T) { {Name: "a", Value: "a1"}, {Name: "b", Value: "b1"}, }, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 8, - Timestamp: 1, + Value: 8, + TimestampMs: 1, }, { - Value: 9, - Timestamp: 2, + Value: 9, + TimestampMs: 2, }, }, }, @@ -63,7 +63,7 @@ func Test_ResponseToSamples(t *testing.T) { sampleCt := 0 for iter.Next() { ts, v := iter.At() - require.Equal(t, input.Data.Result[setCt].Samples[sampleCt].Timestamp, ts) + require.Equal(t, input.Data.Result[setCt].Samples[sampleCt].TimestampMs, ts) require.Equal(t, input.Data.Result[setCt].Samples[sampleCt].Value, v) sampleCt++ } diff --git a/pkg/querier/queryrange/queryrangebase/value.go b/pkg/querier/queryrange/queryrangebase/value.go index c03c38c9b3..22d72d5bdc 100644 --- a/pkg/querier/queryrange/queryrangebase/value.go +++ b/pkg/querier/queryrange/queryrangebase/value.go @@ -23,10 +23,10 @@ func FromResult(res *promql.Result) ([]SampleStream, error) { case promql.Scalar: return []SampleStream{ { - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: v.V, - Timestamp: v.T, + Value: v.V, + TimestampMs: v.T, }, }, }, @@ -66,13 +66,13 @@ func mapLabels(ls labels.Labels) []logproto.LabelAdapter { return result } -func mapPoints(pts ...promql.Point) []logproto.Sample { - result := make([]logproto.Sample, 0, len(pts)) +func mapPoints(pts ...promql.Point) []logproto.LegacySample { + result := make([]logproto.LegacySample, 0, len(pts)) for _, pt := range pts { - result = append(result, logproto.Sample{ - Value: pt.V, - Timestamp: pt.T, + result = append(result, logproto.LegacySample{ + Value: pt.V, + TimestampMs: pt.T, }) } @@ -110,7 +110,7 @@ func NewSeriesSet(results []SampleStream) storage.SeriesSet { samples := make([]model.SamplePair, 0, len(stream.Samples)) for _, sample := range stream.Samples { samples = append(samples, model.SamplePair{ - Timestamp: model.Time(sample.Timestamp), + Timestamp: model.Time(sample.TimestampMs), Value: model.SampleValue(sample.Value), }) } diff --git a/pkg/querier/queryrange/queryrangebase/value_test.go b/pkg/querier/queryrange/queryrangebase/value_test.go index ca8f4759e4..b8b70e2715 100644 --- a/pkg/querier/queryrange/queryrangebase/value_test.go +++ b/pkg/querier/queryrange/queryrangebase/value_test.go @@ -33,10 +33,10 @@ func TestFromValue(t *testing.T) { err: false, expected: []SampleStream{ { - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 1, - Timestamp: 1, + Value: 1, + TimestampMs: 1, }, }, }, @@ -69,10 +69,10 @@ func TestFromValue(t *testing.T) { {Name: "a", Value: "a1"}, {Name: "b", Value: "b1"}, }, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 1, - Timestamp: 1, + Value: 1, + TimestampMs: 1, }, }, }, @@ -81,10 +81,10 @@ func TestFromValue(t *testing.T) { {Name: "a", Value: "a2"}, {Name: "b", Value: "b2"}, }, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 2, - Timestamp: 2, + Value: 2, + TimestampMs: 2, }, }, }, @@ -123,14 +123,14 @@ func TestFromValue(t *testing.T) { {Name: "a", Value: "a1"}, {Name: "b", Value: "b1"}, }, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 1, - Timestamp: 1, + Value: 1, + TimestampMs: 1, }, { - Value: 2, - Timestamp: 2, + Value: 2, + TimestampMs: 2, }, }, }, @@ -139,14 +139,14 @@ func TestFromValue(t *testing.T) { {Name: "a", Value: "a2"}, {Name: "b", Value: "b2"}, }, - Samples: []logproto.Sample{ + Samples: []logproto.LegacySample{ { - Value: 8, - Timestamp: 1, + Value: 8, + TimestampMs: 1, }, { - Value: 9, - Timestamp: 2, + Value: 9, + TimestampMs: 2, }, }, }, diff --git a/pkg/querier/queryrange/querysharding_test.go b/pkg/querier/queryrange/querysharding_test.go index 8fa4f2f34f..d8672ee7bc 100644 --- a/pkg/querier/queryrange/querysharding_test.go +++ b/pkg/querier/queryrange/querysharding_test.go @@ -269,7 +269,7 @@ func Test_InstantSharding(t *testing.T) { Result: []queryrangebase.SampleStream{ { Labels: []logproto.LabelAdapter{{Name: "foo", Value: "bar"}}, - Samples: []logproto.Sample{{Value: 10, Timestamp: 10}}, + Samples: []logproto.LegacySample{{Value: 10, TimestampMs: 10}}, }, }, }, @@ -288,15 +288,15 @@ func Test_InstantSharding(t *testing.T) { Result: []queryrangebase.SampleStream{ { Labels: []logproto.LabelAdapter{{Name: "foo", Value: "bar"}}, - Samples: []logproto.Sample{{Value: 10, Timestamp: 10}}, + Samples: []logproto.LegacySample{{Value: 10, TimestampMs: 10}}, }, { Labels: []logproto.LabelAdapter{{Name: "foo", Value: "bar"}}, - Samples: []logproto.Sample{{Value: 10, Timestamp: 10}}, + Samples: []logproto.LegacySample{{Value: 10, TimestampMs: 10}}, }, { Labels: []logproto.LabelAdapter{{Name: "foo", Value: "bar"}}, - Samples: []logproto.Sample{{Value: 10, Timestamp: 10}}, + Samples: []logproto.LegacySample{{Value: 10, TimestampMs: 10}}, }, }, }, response.(*LokiPromResponse).Response.Data) diff --git a/pkg/ruler/base/compat.go b/pkg/ruler/base/compat.go index 95919065a4..005a4d95bb 100644 --- a/pkg/ruler/base/compat.go +++ b/pkg/ruler/base/compat.go @@ -36,7 +36,7 @@ type PusherAppender struct { ctx context.Context pusher Pusher labels []labels.Labels - samples []logproto.Sample + samples []logproto.LegacySample userID string evaluationDelay time.Duration } @@ -56,9 +56,9 @@ func (a *PusherAppender) Append(_ storage.SeriesRef, l labels.Labels, t int64, v t -= a.evaluationDelay.Milliseconds() } - a.samples = append(a.samples, logproto.Sample{ - Timestamp: t, - Value: v, + a.samples = append(a.samples, logproto.LegacySample{ + TimestampMs: t, + Value: v, }) return 0, nil } diff --git a/pkg/ruler/base/compat_test.go b/pkg/ruler/base/compat_test.go index 225baa6d08..5f3fd7231d 100644 --- a/pkg/ruler/base/compat_test.go +++ b/pkg/ruler/base/compat_test.go @@ -111,7 +111,7 @@ func TestPusherAppendable(t *testing.T) { require.NoError(t, a.Commit()) - require.Equal(t, tc.expectedTS, pusher.request.Timeseries[0].Samples[0].Timestamp) + require.Equal(t, tc.expectedTS, pusher.request.Timeseries[0].Samples[0].TimestampMs) }) } diff --git a/pkg/ruler/base/ruler.pb.go b/pkg/ruler/base/ruler.pb.go index ca26877d0f..5a48b9cf69 100644 --- a/pkg/ruler/base/ruler.pb.go +++ b/pkg/ruler/base/ruler.pb.go @@ -380,50 +380,50 @@ func init() { func init() { proto.RegisterFile("pkg/ruler/base/ruler.proto", fileDescriptor_ca810a0fd7057a73) } var fileDescriptor_ca810a0fd7057a73 = []byte{ - // 677 bytes of a gzipped FileDescriptorProto + // 688 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x54, 0x4f, 0x6f,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0x89, 0xd2, 0x3c, 0x9d, 0x59, 0x78, 0x34, 0x72, 0x8b, 0x26, 0xca, 0xb6, 0x33, 0x25, 0x2c, - 0x1e, 0x6f, 0x67, 0x89, 0x8a, 0x99, 0xdb, 0x9d, 0x85, 0xc6, 0x00, 0xdf, 0x69, 0xdc, 0xda, 0x33, - 0xd8, 0xd2, 0x77, 0x55, 0xa0, 0x35, 0x7b, 0x90, 0x08, 0x55, 0x2f, 0x56, 0xf9, 0xb2, 0xf6, 0x97, - 0x2e, 0xf9, 0xec, 0xeb, 0x3a, 0x74, 0xd6, 0x1f, 0x1f, 0x9d, 0x62, 0xe7, 0xf8, 0x14, 0x3b, 0xe7, - 0xa7, 0x18, 0x7c, 0xcc, 0x31, 0xf8, 0x92, 0x63, 0x70, 0x98, 0x63, 0x70, 0x94, 0x63, 0xf0, 0x23, - 0xc7, 0xe0, 0x67, 0x8e, 0x9d, 0xf3, 0x1c, 0x83, 0x83, 0x33, 0xec, 0x1c, 0x9d, 0x61, 0xe7, 0xf8, - 0x0c, 0x3b, 0x61, 0xdb, 0x34, 0xf7, 0xe8, 0x57, 0x00, 0x00, 0x00, 0xff, 0xff, 0x63, 0xfe, 0x86, - 0x06, 0x8d, 0x06, 0x00, 0x00, + 0x18, 0x8e, 0xbb, 0xb6, 0x6b, 0xdd, 0xfd, 0xf6, 0x93, 0xbc, 0x09, 0x65, 0x05, 0xdc, 0xa9, 0x5c, + 0x26, 0x04, 0xa9, 0x18, 0x08, 0x09, 0x21, 0x84, 0x3a, 0x6d, 0x70, 0xd9, 0x01, 0x65, 0xc0, 0x75, + 0x72, 0x5a, 0x2f, 0x8b, 0xe6, 0xc5, 0xc1, 0x76, 0x2a, 0x71, 0xe3, 0x23, 0xec, 0xc8, 0x95, 0x1b, + 0x1f, 0x65, 0xc7, 0x1d, 0x27, 0x90, 0x06, 0xcb, 0x2e, 0x1c, 0xf7, 0x01, 0x38, 0x20, 0xdb, 0xc9, + 0x92, 0xc1, 0x38, 0x54, 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1, 0x29, 0x76, 0xce, 0x4f, 0x31, 0xf8, 0x90, 0x61, + 0xf0, 0x39, 0xc3, 0xe0, 0x30, 0xc3, 0xe0, 0x28, 0xc3, 0xe0, 0x7b, 0x86, 0xc1, 0x8f, 0x0c, 0x3b, + 0xe7, 0x19, 0x06, 0x07, 0x67, 0xd8, 0x39, 0x3a, 0xc3, 0xce, 0xf1, 0x19, 0x76, 0x82, 0xa6, 0x69, + 0xee, 0xe1, 0xaf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x55, 0x94, 0x9f, 0xfc, 0x99, 0x06, 0x00, 0x00, } func (this *RulesRequest) Equal(that interface{}) bool { diff --git a/pkg/ruler/base/ruler.proto b/pkg/ruler/base/ruler.proto index ceebc86dae..782dd5002b 100644 --- a/pkg/ruler/base/ruler.proto +++ b/pkg/ruler/base/ruler.proto @@ -44,11 +44,11 @@ message RuleStateDesc { message AlertStateDesc { string state = 1; - repeated logproto.LabelPair labels = 2 [ + repeated logproto.LegacyLabelPair labels = 2 [ (gogoproto.nullable) = false, (gogoproto.customtype) = "github.com/grafana/loki/pkg/logproto.LabelAdapter" ]; - repeated logproto.LabelPair annotations = 3 [ + repeated logproto.LegacyLabelPair annotations = 3 [ (gogoproto.nullable) = false, (gogoproto.customtype) = "github.com/grafana/loki/pkg/logproto.LabelAdapter" ]; diff --git a/pkg/ruler/rulespb/rules.pb.go b/pkg/ruler/rulespb/rules.pb.go index a24d38aa7b..f4c4360ef0 100644 --- a/pkg/ruler/rulespb/rules.pb.go +++ b/pkg/ruler/rulespb/rules.pb.go @@ -198,38 +198,38 @@ func init() { func init() { proto.RegisterFile("pkg/ruler/rulespb/rules.proto", fileDescriptor_dd3ef3757f506fba) } var fileDescriptor_dd3ef3757f506fba = []byte{ - // 488 bytes of a gzipped FileDescriptorProto + // 493 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x53, 0x41, 0x6f, 0xd3, 0x30, - 0x14, 0x8e, 0xd7, 0x34, 0x4b, 0x5c, 0x4d, 0x54, 0x66, 0x42, 0xd9, 0x00, 0xb7, 0x9a, 0x84, 0x54, - 0x0e, 0x24, 0x62, 0x88, 0x03, 0x27, 0xb4, 0x6a, 0x12, 0x52, 0xc5, 0x01, 0xe5, 0xc8, 0x05, 0x39, - 0xad, 0x1b, 0xa2, 0x79, 0xb6, 0xe5, 0x24, 0x88, 0xdd, 0xf8, 0x09, 0x1c, 0xf9, 0x09, 0xfc, 0x94, - 0x1d, 0x7b, 0x9c, 0x38, 0x0c, 0x9a, 0x5c, 0x38, 0xee, 0x1f, 0x80, 0x6c, 0x27, 0x5b, 0x01, 0x09, - 0x71, 0xe1, 0x52, 0xbf, 0xe7, 0xef, 0xbd, 0xf7, 0x7d, 0xef, 0x73, 0x03, 0xef, 0xcb, 0x93, 0x2c, - 0x56, 0x15, 0xa3, 0xca, 0xfc, 0x16, 0x32, 0xb5, 0x67, 0x24, 0x95, 0x28, 0x05, 0xea, 0x9b, 0x64, - 0xff, 0x51, 0x96, 0x97, 0x6f, 0xab, 0x34, 0x9a, 0x8b, 0xd3, 0x38, 0x13, 0x99, 0x88, 0x0d, 0x9a, - 0x56, 0x4b, 0x93, 0x99, 0xc4, 0x44, 0xb6, 0x6b, 0x1f, 0x67, 0x42, 0x64, 0x8c, 0xde, 0x54, 0x2d, - 0x2a, 0x45, 0xca, 0x5c, 0xf0, 0x16, 0xdf, 0xfb, 0x1d, 0x27, 0xfc, 0xac, 0x85, 0xee, 0x6a, 0x3d, - 0x4c, 0x64, 0x76, 0x66, 0x17, 0x58, 0xf0, 0xe0, 0x07, 0x80, 0x3b, 0x49, 0xc5, 0xe8, 0x0b, 0x25, - 0x2a, 0x79, 0x4c, 0x8b, 0x39, 0x42, 0xd0, 0xe5, 0xe4, 0x94, 0x86, 0x60, 0x0c, 0x26, 0x41, 0x62, - 0x62, 0x74, 0x0f, 0x06, 0xfa, 0x2c, 0x24, 0x99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0x8d, 0xad, 0x9b, 0x1a, 0x83, 0x0f, 0x6b, 0x6c, 0x2d, 0xd7, 0xd8, 0xba, + 0x5a, 0x63, 0xeb, 0xf5, 0xa3, 0xbf, 0x69, 0xff, 0xf2, 0xbb, 0x45, 0x8e, 0xf6, 0xf1, 0xf4, 0x67, + 0x00, 0x00, 0x00, 0xff, 0xff, 0x2f, 0x37, 0x59, 0x44, 0x8a, 0x03, 0x00, 0x00, } func (this *RuleGroupDesc) Equal(that interface{}) bool { diff --git a/pkg/ruler/rulespb/rules.proto b/pkg/ruler/rulespb/rules.proto index 1306511c09..cc10170810 100644 --- a/pkg/ruler/rulespb/rules.proto +++ b/pkg/ruler/rulespb/rules.proto @@ -36,11 +36,11 @@ message RuleDesc { string record = 2; string alert = 3; google.protobuf.Duration for = 4 [(gogoproto.nullable) = false,(gogoproto.stdduration) = true]; - repeated logproto.LabelPair labels = 5 [ + repeated logproto.LegacyLabelPair labels = 5 [ (gogoproto.nullable) = false, (gogoproto.customtype) = "github.com/grafana/loki/pkg/logproto.LabelAdapter" ]; - repeated logproto.LabelPair annotations = 6 [ + repeated logproto.LegacyLabelPair annotations = 6 [ (gogoproto.nullable) = false, (gogoproto.customtype) = "github.com/grafana/loki/pkg/logproto.LabelAdapter" ]; diff --git a/pkg/util/http_test.go b/pkg/util/http_test.go index a691c5950d..029912619f 100644 --- a/pkg/util/http_test.go +++ b/pkg/util/http_test.go @@ -148,10 +148,10 @@ func TestParseProtoReader(t *testing.T) { Labels: []logproto.LabelAdapter{ {Name: "foo", Value: "bar"}, }, - Samples: []logproto.Sample{ - {Value: 10, Timestamp: 1}, - {Value: 20, Timestamp: 2}, - {Value: 30, Timestamp: 3}, + Samples: []logproto.LegacySample{ + {Value: 10, TimestampMs: 1}, + {Value: 20, TimestampMs: 2}, + {Value: 30, TimestampMs: 3}, }, }, },