profile

package
v0.0.0-...-6906e5f Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package profile implements functions for profiling the router

This package automatically registers pprof handlers if the build tag "pprof". Additionally, the following flags are available: -cpuprofile: write cpu profile to file -memprofile: write memory profile to this file -pprof-port: port for pprof server, set to zero to disable (only with pprof build tag)

Note that exposing pprof handlers in production is a security risk.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Profiler

type Profiler interface {
	Finish()
}

func Start

func Start() Profiler

Start starts profiling and returns a Profiler that must be finished with Finish() (usually via defer)

Jump to

Keyboard shortcuts

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