code: func (r *ReporterRecorder) Flush() []model.SpanModel {
  	r.mtx.Lock()
  	spans := r.spans
  	r.spans = nil
  	r.mtx.Unlock()
  	return spans
  }
docs: // Flush returns all recorded spans and clears its internal span storage