context

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Context

type Context struct {
	// contains filtered or unexported fields
}

func NewContext

func NewContext(reqCtx *RequestContext, eveCtx *EventContext) *Context

func (*Context) GetEventContext

func (c *Context) GetEventContext() *EventContext

func (*Context) GetRequestContext

func (c *Context) GetRequestContext() *RequestContext

func (*Context) GetTracer

func (c *Context) GetTracer() opentracing.Tracer

func (*Context) PrintPrevEventData

func (c *Context) PrintPrevEventData(t *testing.T)

func (*Context) SetEventContext

func (c *Context) SetEventContext(eveCtx *EventContext) *Context

SetEventContext is written by generated code when user or library submit their observations contains the static code base information

func (*Context) SetRequestContext

func (c *Context) SetRequestContext(reqCtx *RequestContext) *Context

SetRequestContext is written by network APIs on receiving requests. e.g., rest, rpc contains the request-wise static values. e.g., session-id, token

func (*Context) SetTracer

func (c *Context) SetTracer(tracer opentracing.Tracer) *Context

type EventContext

type EventContext struct {
	// contains filtered or unexported fields
}

EventContext is the context associated with each observation

func NewEventContext

func NewEventContext(codebase *cb.CodeBaseInfo, snapshots *cb.PrerequisiteSnapshots) *EventContext

func (*EventContext) GetCodeInfoBasic

func (c *EventContext) GetCodeInfoBasic() *cb.CodeBaseInfo

func (*EventContext) GetOffsetSnapshots

func (c *EventContext) GetOffsetSnapshots() *cb.PrerequisiteSnapshots

func (*EventContext) GetPrerequisiteSnapshots

func (c *EventContext) GetPrerequisiteSnapshots() *cb.PrerequisiteSnapshots

func (*EventContext) GetPrevEvent

func (c *EventContext) GetPrevEvent() (*EventContext, *cb.EventData)

func (*EventContext) SetCodeInfoBasic

func (c *EventContext) SetCodeInfoBasic(codebase *cb.CodeBaseInfo) *EventContext

func (*EventContext) SetOffsetSnapshots

func (c *EventContext) SetOffsetSnapshots(snapshots *cb.PrerequisiteSnapshots) *EventContext

func (*EventContext) SetPrerequisiteSnapshots

func (c *EventContext) SetPrerequisiteSnapshots(snapshots *cb.PrerequisiteSnapshots) *EventContext

func (*EventContext) SetPrevEvent

func (c *EventContext) SetPrevEvent(eveCtx *EventContext, ed *cb.EventData) *EventContext

type RequestContext

type RequestContext struct {
	// contains filtered or unexported fields
}

RequestContext is inter-service message context

func NewRequestContext

func NewRequestContext(lib string, configureID int64, msg *cb.EventMessage) *RequestContext

func (*RequestContext) GetConfigureID

func (c *RequestContext) GetConfigureID() int64

func (*RequestContext) GetEventMessage

func (c *RequestContext) GetEventMessage() *cb.EventMessage

func (*RequestContext) GetLib

func (c *RequestContext) GetLib() string

func (*RequestContext) GetSpanMetadata

func (c *RequestContext) GetSpanMetadata() *cb.SpanMetadata

func (*RequestContext) SetSpanMetadata

func (c *RequestContext) SetSpanMetadata(sm *cb.SpanMetadata) *RequestContext

Jump to

Keyboard shortcuts

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