autoprofile

package
v1.12.1 Latest Latest
Warning

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

Go to latest
Published: May 6, 2020 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Disable

func Disable()

Disable disables the auto profiling (default)

func Enable

func Enable()

Enable enables the auto profiling (disabled by default)

func SetGetExternalPIDFunc

func SetGetExternalPIDFunc(fn func() string)

SetGetExternalPIDFunc configures the profiler to use provided function to retrieve the current PID

func SetLogLevel deprecated

func SetLogLevel(level int)

SetLogLevel sets the min log level for autoprofiler

Deprecated: use autoprofile.SetLogger() to set the logger and configure the min log level directly

func SetLogger added in v1.8.0

func SetLogger(l logger.LeveledLogger)

SetLogger sets the leveled logger to use to output the diagnostic messages and errors

func SetOptions

func SetOptions(opts Options)

SetOptions configures the profiler with provided settings

func SetSendProfilesFunc

func SetSendProfilesFunc(fn internal.SendProfilesFunc)

SetSendProfilesFunc configures the profiler to use provided function to write collected profiles

Types

type Options

type Options struct {
	IncludeProfilerFrames bool
	MaxBufferedProfiles   int
}

Options contains profiler configuration

func DefaultOptions

func DefaultOptions() Options

DefaultOptions returns profiler defaults

Directories

Path Synopsis
pprof/profile
Package profile provides a representation of profile.proto and methods to encode/decode profiles in this format.
Package profile provides a representation of profile.proto and methods to encode/decode profiles in this format.

Jump to

Keyboard shortcuts

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