@@ -169,13 +169,13 @@ func Test_RangeSeriesWithExemplars(t *testing.T) {
169169 out []* typesv1.Series
170170 }{
171171 {
172- name : "exemplar tracking keeps highest value " ,
172+ name : "exemplar timestamps preserved during aggregation " ,
173173 series : []* typesv1.Series {{
174174 Labels : []* typesv1.LabelPair {{Name : "service_name" , Value : "api" }},
175175 Points : []* typesv1.Point {
176- {Timestamp : 1000 , Value : 100.0 , Exemplars : []* typesv1.Exemplar {{ProfileId : "prof-1" , Value : 100 , Timestamp : 1000 }}},
177- {Timestamp : 1000 , Value : 300.0 , Exemplars : []* typesv1.Exemplar {{ProfileId : "prof-2" , Value : 300 , Timestamp : 1000 }}},
178- {Timestamp : 2000 , Value : 200.0 , Exemplars : []* typesv1.Exemplar {{ProfileId : "prof-3" , Value : 200 , Timestamp : 2000 }}},
176+ {Timestamp : 947 , Value : 100.0 , Exemplars : []* typesv1.Exemplar {{ProfileId : "prof-1" , Value : 100 , Timestamp : 947 }}},
177+ {Timestamp : 987 , Value : 300.0 , Exemplars : []* typesv1.Exemplar {{ProfileId : "prof-2" , Value : 300 , Timestamp : 987 }}},
178+ {Timestamp : 1847 , Value : 200.0 , Exemplars : []* typesv1.Exemplar {{ProfileId : "prof-3" , Value : 200 , Timestamp : 1847 }}},
179179 },
180180 }},
181181 start : 1000 ,
@@ -185,8 +185,8 @@ func Test_RangeSeriesWithExemplars(t *testing.T) {
185185 out : []* typesv1.Series {{
186186 Labels : []* typesv1.LabelPair {{Name : "service_name" , Value : "api" }},
187187 Points : []* typesv1.Point {
188- {Timestamp : 1000 , Value : 400.0 , Annotations : []* typesv1.ProfileAnnotation {}, Exemplars : []* typesv1.Exemplar {{ProfileId : "prof-2" , Value : 300 , Timestamp : 1000 }}},
189- {Timestamp : 2000 , Value : 200.0 , Annotations : []* typesv1.ProfileAnnotation {}, Exemplars : []* typesv1.Exemplar {{ProfileId : "prof-3" , Value : 200 , Timestamp : 2000 }}},
188+ {Timestamp : 1000 , Value : 400.0 , Annotations : []* typesv1.ProfileAnnotation {}, Exemplars : []* typesv1.Exemplar {{ProfileId : "prof-2" , Value : 300 , Timestamp : 987 }}},
189+ {Timestamp : 2000 , Value : 200.0 , Annotations : []* typesv1.ProfileAnnotation {}, Exemplars : []* typesv1.Exemplar {{ProfileId : "prof-3" , Value : 200 , Timestamp : 1847 }}},
190190 },
191191 }},
192192 },
0 commit comments