Documentation ¶
Overview ¶
Package spy contains an interface (Spy) and functionality to register new spies
Index ¶
Constants ¶
View Source
const ( ProfileCPU ProfileType = "cpu" ProfileInuseObjects ProfileType = "inuse_objects" ProfileAllocObjects ProfileType = "alloc_objects" ProfileInuseSpace ProfileType = "inuse_space" ProfileAllocSpace ProfileType = "alloc_space" Go = "gospy" EBPF = "ebpfspy" Python = "pyspy" Ruby = "rbspy" )
Variables ¶
View Source
var (
SupportedSpies []string
)
Functions ¶
func RegisterSpy ¶
func RegisterSpy(name string, cb SpyIntitializer)
func ResolveAutoName ¶
func SupportedExecSpies ¶ added in v0.0.16
func SupportedExecSpies() []string
Types ¶
type InitParams ¶ added in v0.27.0
type InitParams struct { Pid int ProfileType ProfileType SampleRate uint32 DisableGCRuns bool Logger log.Logger }
TODO: this interface is not the best as different spies have different arguments
type ProfileType ¶ added in v0.0.30
type ProfileType string
func (ProfileType) AggregationType ¶ added in v0.0.30
func (t ProfileType) AggregationType() metadata.AggregationType
func (ProfileType) IsCumulative ¶ added in v0.0.30
func (t ProfileType) IsCumulative() bool
func (ProfileType) Units ¶ added in v0.0.30
func (t ProfileType) Units() metadata.Units
type Resettable ¶ added in v0.0.25
type Resettable interface {
Reset()
}
type SpyIntitializer ¶ added in v0.2.0
type SpyIntitializer func(InitParams) (Spy, error)
func StartFunc ¶ added in v0.0.38
func StartFunc(name string) (SpyIntitializer, error)
Click to show internal directories.
Click to hide internal directories.