Documentation ¶
Index ¶
- Constants
- func CustomHeadersStreamInterceptor(httpOpts httpclient.Options) grpc.StreamClientInterceptor
- func StatusCodeFromHTTP(httpStatusCode int) ptrace.StatusCode
- func TraceToFrame(td ptrace.Traces) (*data.Frame, error)
- type Datasource
- type ExtendedResponse
- type KeyValue
- type OpenTracingSpanKind
- type Service
- func (s *Service) PublishStream(ctx context.Context, req *backend.PublishStreamRequest) (*backend.PublishStreamResponse, error)
- func (s *Service) QueryData(ctx context.Context, req *backend.QueryDataRequest) (*backend.QueryDataResponse, error)
- func (s *Service) RunStream(ctx context.Context, request *backend.RunStreamRequest, ...) error
- func (s *Service) SubscribeStream(ctx context.Context, req *backend.SubscribeStreamRequest) (*backend.SubscribeStreamResponse, error)
- type StreamSender
- type TraceLog
- type TraceReference
Constants ¶
const ( TagMessage = "message" TagSpanKind = "span.kind" TagStatusCode = "status.code" TagStatusMsg = "status.message" TagError = "error" TagHTTPStatusMsg = "http.status_message" TagW3CTraceState = "w3c.tracestate" )
Some of the keys used to represent OTLP constructs as tags or annotations in other formats.
const (
ResourceNoServiceName = "OTLPResourceNoServiceName"
)
Constants used for signifying batch-level attribute values where not supplied by OTLP data but required by other protocols.
const SearchPathPrefix = "search/"
Variables ¶
This section is empty.
Functions ¶
func CustomHeadersStreamInterceptor ¶
func CustomHeadersStreamInterceptor(httpOpts httpclient.Options) grpc.StreamClientInterceptor
CustomHeadersStreamInterceptor adds custom headers to the outgoing context for each RPC call. Should work similar to the CustomHeadersMiddleware in the HTTP client provider.
func StatusCodeFromHTTP ¶
func StatusCodeFromHTTP(httpStatusCode int) ptrace.StatusCode
StatusCodeFromHTTP takes an HTTP status code and return the appropriate OpenTelemetry status code See: https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/trace/semantic_conventions/http.md#status
Types ¶
type Datasource ¶
type Datasource struct { HTTPClient *http.Client StreamingClient tempopb.StreamingQuerierClient URL string }
type ExtendedResponse ¶
type ExtendedResponse struct { *tempopb.SearchResponse State dataquery.SearchStreamingState }
type OpenTracingSpanKind ¶
type OpenTracingSpanKind string
OpenTracingSpanKind are possible values for TagSpanKind and match the OpenTracing conventions: https://github.com/opentracing/specification/blob/main/semantic_conventions.md These values are used for representing span kinds that have no equivalents in OpenCensus format. They are stored as values of TagSpanKind
const ( OpenTracingSpanKindUnspecified OpenTracingSpanKind = "" OpenTracingSpanKindClient OpenTracingSpanKind = "client" OpenTracingSpanKindServer OpenTracingSpanKind = "server" OpenTracingSpanKindConsumer OpenTracingSpanKind = "consumer" OpenTracingSpanKindProducer OpenTracingSpanKind = "producer" OpenTracingSpanKindInternal OpenTracingSpanKind = "internal" )
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func ProvideService ¶
func ProvideService(httpClientProvider *httpclient.Provider) *Service
func (*Service) PublishStream ¶
func (s *Service) PublishStream(ctx context.Context, req *backend.PublishStreamRequest) (*backend.PublishStreamResponse, error)
func (*Service) QueryData ¶
func (s *Service) QueryData(ctx context.Context, req *backend.QueryDataRequest) (*backend.QueryDataResponse, error)
func (*Service) RunStream ¶
func (s *Service) RunStream(ctx context.Context, request *backend.RunStreamRequest, sender *backend.StreamSender) error
func (*Service) SubscribeStream ¶
func (s *Service) SubscribeStream(ctx context.Context, req *backend.SubscribeStreamRequest) (*backend.SubscribeStreamResponse, error)