func()

in pkg/processor/processor.go [168:182]


func (p *Processor) sendBatchAsync(batch []*tracesegment.TraceSegment) []*tracesegment.TraceSegment {
	log.Debugf("processor: segment batch size: %d. capacity: %d", len(batch), cap(batch))

	segmentDocuments := []*string{}
	for _, segment := range batch {
		rawBytes := *segment.Raw
		x := string(rawBytes[:])
		segmentDocuments = append(segmentDocuments, &x)
		p.pool.Return(segment.PoolBuf)
	}
	p.traceSegmentsBatch.send(segmentDocuments)
	// Reset Idle Timer
	p.SetIdleTimer()
	return p.flushBatch(batch)
}