...

Package v1

import "go.opentelemetry.io/proto/otlp/collector/trace/v1"
Overview
Index

Overview ▾

Package v1 is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index ▾

Variables
func RegisterTraceServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
func RegisterTraceServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client TraceServiceClient) error
func RegisterTraceServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)
func RegisterTraceServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server TraceServiceServer) error
func RegisterTraceServiceServer(s grpc.ServiceRegistrar, srv TraceServiceServer)
type ExportTracePartialSuccess
    func (*ExportTracePartialSuccess) Descriptor() ([]byte, []int)
    func (x *ExportTracePartialSuccess) GetErrorMessage() string
    func (x *ExportTracePartialSuccess) GetRejectedSpans() int64
    func (*ExportTracePartialSuccess) ProtoMessage()
    func (x *ExportTracePartialSuccess) ProtoReflect() protoreflect.Message
    func (x *ExportTracePartialSuccess) Reset()
    func (x *ExportTracePartialSuccess) String() string
type ExportTraceServiceRequest
    func (*ExportTraceServiceRequest) Descriptor() ([]byte, []int)
    func (x *ExportTraceServiceRequest) GetResourceSpans() []*v1.ResourceSpans
    func (*ExportTraceServiceRequest) ProtoMessage()
    func (x *ExportTraceServiceRequest) ProtoReflect() protoreflect.Message
    func (x *ExportTraceServiceRequest) Reset()
    func (x *ExportTraceServiceRequest) String() string
type ExportTraceServiceResponse
    func (*ExportTraceServiceResponse) Descriptor() ([]byte, []int)
    func (x *ExportTraceServiceResponse) GetPartialSuccess() *ExportTracePartialSuccess
    func (*ExportTraceServiceResponse) ProtoMessage()
    func (x *ExportTraceServiceResponse) ProtoReflect() protoreflect.Message
    func (x *ExportTraceServiceResponse) Reset()
    func (x *ExportTraceServiceResponse) String() string
type TraceServiceClient
    func NewTraceServiceClient(cc grpc.ClientConnInterface) TraceServiceClient
type TraceServiceServer
type UnimplementedTraceServiceServer
    func (UnimplementedTraceServiceServer) Export(context.Context, *ExportTraceServiceRequest) (*ExportTraceServiceResponse, error)
type UnsafeTraceServiceServer

Package files

trace_service.pb.go trace_service.pb.gw.go trace_service_grpc.pb.go

Variables

var File_opentelemetry_proto_collector_trace_v1_trace_service_proto protoreflect.FileDescriptor

TraceService_ServiceDesc is the grpc.ServiceDesc for TraceService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

var TraceService_ServiceDesc = grpc.ServiceDesc{
    ServiceName: "opentelemetry.proto.collector.trace.v1.TraceService",
    HandlerType: (*TraceServiceServer)(nil),
    Methods: []grpc.MethodDesc{
        {
            MethodName: "Export",
            Handler:    _TraceService_Export_Handler,
        },
    },
    Streams:  []grpc.StreamDesc{},
    Metadata: "opentelemetry/proto/collector/trace/v1/trace_service.proto",
}

func RegisterTraceServiceHandler

func RegisterTraceServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterTraceServiceHandler registers the http handlers for service TraceService to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterTraceServiceHandlerClient

func RegisterTraceServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client TraceServiceClient) error

RegisterTraceServiceHandlerClient registers the http handlers for service TraceService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "TraceServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "TraceServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "TraceServiceClient" to call the correct interceptors.

func RegisterTraceServiceHandlerFromEndpoint

func RegisterTraceServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterTraceServiceHandlerFromEndpoint is same as RegisterTraceServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterTraceServiceHandlerServer

func RegisterTraceServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server TraceServiceServer) error

RegisterTraceServiceHandlerServer registers the http handlers for service TraceService to "mux". UnaryRPC :call TraceServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterTraceServiceHandlerFromEndpoint instead.

func RegisterTraceServiceServer

func RegisterTraceServiceServer(s grpc.ServiceRegistrar, srv TraceServiceServer)

type ExportTracePartialSuccess

type ExportTracePartialSuccess struct {

    // The number of rejected spans.
    //
    // A `rejected_<signal>` field holding a `0` value indicates that the
    // request was fully accepted.
    RejectedSpans int64 `protobuf:"varint,1,opt,name=rejected_spans,json=rejectedSpans,proto3" json:"rejected_spans,omitempty"`
    // A developer-facing human-readable message in English. It should be used
    // either to explain why the server rejected parts of the data during a partial
    // success or to convey warnings/suggestions during a full success. The message
    // should offer guidance on how users can address such issues.
    //
    // error_message is an optional field. An error_message with an empty value
    // is equivalent to it not being set.
    ErrorMessage string `protobuf:"bytes,2,opt,name=error_message,json=errorMessage,proto3" json:"error_message,omitempty"`
    // contains filtered or unexported fields
}

func (*ExportTracePartialSuccess) Descriptor

func (*ExportTracePartialSuccess) Descriptor() ([]byte, []int)

Deprecated: Use ExportTracePartialSuccess.ProtoReflect.Descriptor instead.

func (*ExportTracePartialSuccess) GetErrorMessage

func (x *ExportTracePartialSuccess) GetErrorMessage() string

func (*ExportTracePartialSuccess) GetRejectedSpans

func (x *ExportTracePartialSuccess) GetRejectedSpans() int64

func (*ExportTracePartialSuccess) ProtoMessage

func (*ExportTracePartialSuccess) ProtoMessage()

func (*ExportTracePartialSuccess) ProtoReflect

func (x *ExportTracePartialSuccess) ProtoReflect() protoreflect.Message

func (*ExportTracePartialSuccess) Reset

func (x *ExportTracePartialSuccess) Reset()

func (*ExportTracePartialSuccess) String

func (x *ExportTracePartialSuccess) String() string

type ExportTraceServiceRequest

type ExportTraceServiceRequest struct {

    // An array of ResourceSpans.
    // For data coming from a single resource this array will typically contain one
    // element. Intermediary nodes (such as OpenTelemetry Collector) that receive
    // data from multiple origins typically batch the data before forwarding further and
    // in that case this array will contain multiple elements.
    ResourceSpans []*v1.ResourceSpans `protobuf:"bytes,1,rep,name=resource_spans,json=resourceSpans,proto3" json:"resource_spans,omitempty"`
    // contains filtered or unexported fields
}

func (*ExportTraceServiceRequest) Descriptor

func (*ExportTraceServiceRequest) Descriptor() ([]byte, []int)

Deprecated: Use ExportTraceServiceRequest.ProtoReflect.Descriptor instead.

func (*ExportTraceServiceRequest) GetResourceSpans

func (x *ExportTraceServiceRequest) GetResourceSpans() []*v1.ResourceSpans

func (*ExportTraceServiceRequest) ProtoMessage

func (*ExportTraceServiceRequest) ProtoMessage()

func (*ExportTraceServiceRequest) ProtoReflect

func (x *ExportTraceServiceRequest) ProtoReflect() protoreflect.Message

func (*ExportTraceServiceRequest) Reset

func (x *ExportTraceServiceRequest) Reset()

func (*ExportTraceServiceRequest) String

func (x *ExportTraceServiceRequest) String() string

type ExportTraceServiceResponse

type ExportTraceServiceResponse struct {

    // The details of a partially successful export request.
    //
    // If the request is only partially accepted
    // (i.e. when the server accepts only parts of the data and rejects the rest)
    // the server MUST initialize the `partial_success` field and MUST
    // set the `rejected_<signal>` with the number of items it rejected.
    //
    // Servers MAY also make use of the `partial_success` field to convey
    // warnings/suggestions to senders even when the request was fully accepted.
    // In such cases, the `rejected_<signal>` MUST have a value of `0` and
    // the `error_message` MUST be non-empty.
    //
    // A `partial_success` message with an empty value (rejected_<signal> = 0 and
    // `error_message` = "") is equivalent to it not being set/present. Senders
    // SHOULD interpret it the same way as in the full success case.
    PartialSuccess *ExportTracePartialSuccess `protobuf:"bytes,1,opt,name=partial_success,json=partialSuccess,proto3" json:"partial_success,omitempty"`
    // contains filtered or unexported fields
}

func (*ExportTraceServiceResponse) Descriptor

func (*ExportTraceServiceResponse) Descriptor() ([]byte, []int)

Deprecated: Use ExportTraceServiceResponse.ProtoReflect.Descriptor instead.

func (*ExportTraceServiceResponse) GetPartialSuccess

func (x *ExportTraceServiceResponse) GetPartialSuccess() *ExportTracePartialSuccess

func (*ExportTraceServiceResponse) ProtoMessage

func (*ExportTraceServiceResponse) ProtoMessage()

func (*ExportTraceServiceResponse) ProtoReflect

func (x *ExportTraceServiceResponse) ProtoReflect() protoreflect.Message

func (*ExportTraceServiceResponse) Reset

func (x *ExportTraceServiceResponse) Reset()

func (*ExportTraceServiceResponse) String

func (x *ExportTraceServiceResponse) String() string

type TraceServiceClient

TraceServiceClient is the client API for TraceService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type TraceServiceClient interface {
    // For performance reasons, it is recommended to keep this RPC
    // alive for the entire life of the application.
    Export(ctx context.Context, in *ExportTraceServiceRequest, opts ...grpc.CallOption) (*ExportTraceServiceResponse, error)
}

func NewTraceServiceClient

func NewTraceServiceClient(cc grpc.ClientConnInterface) TraceServiceClient

type TraceServiceServer

TraceServiceServer is the server API for TraceService service. All implementations must embed UnimplementedTraceServiceServer for forward compatibility

type TraceServiceServer interface {
    // For performance reasons, it is recommended to keep this RPC
    // alive for the entire life of the application.
    Export(context.Context, *ExportTraceServiceRequest) (*ExportTraceServiceResponse, error)
    // contains filtered or unexported methods
}

type UnimplementedTraceServiceServer

UnimplementedTraceServiceServer must be embedded to have forward compatible implementations.

type UnimplementedTraceServiceServer struct {
}

func (UnimplementedTraceServiceServer) Export

func (UnimplementedTraceServiceServer) Export(context.Context, *ExportTraceServiceRequest) (*ExportTraceServiceResponse, error)

type UnsafeTraceServiceServer

UnsafeTraceServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to TraceServiceServer will result in compilation errors.

type UnsafeTraceServiceServer interface {
    // contains filtered or unexported methods
}