MCPcopy
hub / github.com/grafana/tempo / NewHTTPCollector

Function NewHTTPCollector

modules/frontend/pipeline/collector_http.go:24–30  ·  view source on GitHub ↗

todo: long term this should return an http.Handler instead of a RoundTripper? that way it can completely encapsulate all the responsibilities of converting a pipeline http.Response and error into an http.Response to be NewHTTPCollector returns a new http collector

(next AsyncRoundTripper[combiner.PipelineResponse], consumers int, combiner combiner.Combiner)

Source from the content-addressed store, hash-verified

22
23// NewHTTPCollector returns a new http collector
24func NewHTTPCollector(next AsyncRoundTripper[combiner.PipelineResponse], consumers int, combiner combiner.Combiner) http.RoundTripper {
25 return httpCollector{
26 next: next,
27 combiner: combiner,
28 consumers: consumers,
29 }
30}
31
32// RoundTrip implements the http.RoundTripper interface
33func (r httpCollector) RoundTrip(req *http.Request) (*http.Response, error) {

Callers 10

newSearchHTTPHandlerFunction · 0.92
newTraceIDHandlerFunction · 0.92
newTraceIDV2HandlerFunction · 0.92
newTagsHTTPHandlerFunction · 0.92
newTagsV2HTTPHandlerFunction · 0.92
newTagValuesHTTPHandlerFunction · 0.92

Calls

no outgoing calls

Tested by 1