code: func (mc *CCacheMetric) Search(ctx context.Context, metric schema.AMKey, res *CCSearchResult, from, until uint32) {
  	mc.RLock()
  	defer mc.RUnlock()
  
  	if len(mc.chunks) < 1 {
  		return
  	}
  
  	mc.searchForward(ctx, metric, from, until, res)
  	if !res.Complete {
  		mc.searchBackward(from, until, res)
  	}
  
  	if !res.Complete && res.From > res.Until {
  		log.Warnf("CCacheMetric Search: Found from > until (%d/%d), key = %s, printing chunks\n", res.From, res.Until, mc.MKey.String())
  		mc.debugMetric(from-7200, until+7200)
  		res.Complete = false
  		res.Start = res.Start[:0]
  		res.End = res.End[:0]
  		res.From = from
  		res.Until = until
  	}
  }
docs: // Search searches the CCacheMetric's data and returns a complete-as-possible CCSearchResult
  //
  // we first look for the chunks where the "from" and "until" ts are in.
  // then we seek from the "from" towards "until"
  // and add as many cunks as possible to the result, if this did not result
  // in all chunks necessary to serve the request we do the same in the reverse
  // order from "until" to "from"
  // if the first seek in chronological direction already ends up with all the
  // chunks we need to serve the request, the second one can be skipped.
  //
  // EXAMPLE:
  // from ts:                    |
  // until ts:                                                   |
  // cache:            |---|---|---|   |   |   |   |   |---|---|---|---|---|---|
  // chunks returned:          |---|                   |---|---|---|