ezpprof

package
v0.0.0-...-f18a85d Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2020 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RunProfiler

func RunProfiler(opts Opts) interface{ Stop() }

RunProfiler starts a specific profiler based on the options passed to it. It will return a Stop function that can be deferred

Types

type Opts

type Opts struct {
	Mem         bool   `long:"pprof_mem"                env:"pprof_mem"   description:"Memory profile. Mutually exlusive with all the other modes." `
	CPU         bool   `long:"pprof_cpu"                env:"pprof_cpu"   description:"CPU profile. Mutually exlusive with all the other modes."    `
	Trace       bool   `long:"pprof_trace"              env:"pprof_trace" description:"Trace profile. Mutually exlusive with all the other modes."  `
	Block       bool   `long:"pprof_block"              env:"pprof_block" description:"Block profile. Mutually exlusive with all the other modes."  `
	Mutex       bool   `long:"pprof_mutex"              env:"pprof_mutex" description:"Mutex profile. Mutually exlusive with all the other modes."  `
	ProfilePath string `long:"pprof_dir"   default:"./" env:"pprof_dir"   description:"The ouptut directory where ezpprof will write the file"`
}

Opts are options for which profiler you want to run. Note only one of these options should ever be set (aside from the profile path)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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