Expose NewMergedSeriesSet for merging SeriesSets

Signed-off-by: Goutham Veeramachaneni <cs14btech11014@iith.ac.in>
pull/5805/head
Goutham Veeramachaneni 8 years ago
parent 5b242f35ba
commit c463b0c8c8
No known key found for this signature in database
GPG Key ID: F1C217E8E9023CAD
  1. 7
      querier.go

@ -360,6 +360,13 @@ type mergedSeriesSet struct {
adone, bdone bool
}
// NewMergedSeriesSet takes two series sets as a single series set. The input series sets
// must be sorted and sequential in time, i.e. if they have the same label set,
// the datapoints of a must be before the datapoints of b.
func NewMergedSeriesSet(a, b SeriesSet) SeriesSet {
return newMergedSeriesSet(a, b)
}
func newMergedSeriesSet(a, b SeriesSet) *mergedSeriesSet {
s := &mergedSeriesSet{a: a, b: b}
// Initialize first elements of both sets as Next() needs

Loading…
Cancel
Save