request

package
v0.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 3, 2023 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EventType

type EventType uint8
const (
	EventTypeHTTP EventType = iota + 1
	EventTypeGRPC
	EventTypeHTTPClient
	EventTypeGRPCClient
	EventTypeSQLClient
)

The following consts need to coincide with some C identifiers: EVENT_HTTP_REQUEST, EVENT_GRPC_REQUEST, EVENT_HTTP_CLIENT, EVENT_GRPC_CLIENT, EVENT_SQL_CLIENT

type IgnoreMode added in v0.3.2

type IgnoreMode uint8
const (
	IgnoreMetrics IgnoreMode = iota + 1
	IgnoreTraces
)

type PidInfo added in v0.3.2

type PidInfo struct {
	// HostPID is the PID as seen by the host (root cgroup)
	HostPID uint32
	// UserID is the PID as seen by the user space.
	// Might differ from HostPID if the process is in a different namespace/cgroup/container/etc.
	UserPID uint32
	// Namespace for the PIDs
	Namespace uint32
}

PidInfo stores different views of the PID of the process that generated the span

type Span

type Span struct {
	Type          EventType
	IgnoreSpan    IgnoreMode
	ID            uint64
	Method        string
	Path          string
	Route         string
	Peer          string
	Host          string
	HostPort      int
	Status        int
	ContentLength int64
	RequestStart  int64
	Start         int64
	End           int64
	ServiceID     svc.ID
	Metadata      map[string]string
	Traceparent   string
	Pid           PidInfo
}

Span contains the information being submitted by the following nodes in the graph. It enables comfortable handling of data from Go.

func (*Span) Inside

func (s *Span) Inside(parent *Span) bool

func (*Span) Timings

func (s *Span) Timings() Timings

type Timings

type Timings struct {
	RequestStart time.Time
	Start        time.Time
	End          time.Time
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL