zpprof

package
v1.7.11 Latest Latest
Warning

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

Go to latest
Published: Apr 13, 2024 License: MIT Imports: 9 Imported by: 1

Documentation

Overview

Package zpprof provides a register for zweb framework to use net/http/pprof easily.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ListenAndServe added in v0.1.26

func ListenAndServe(addr ...string) error

func Register

func Register(r *znet.Engine, token string) (RouterGroup *znet.Engine)

Register Registration routing

Types

type SystemInfo

type SystemInfo struct {
	ServerName   string
	Runtime      string // 运行时间
	GoroutineNum string // goroutine数量
	CPUNum       string // cpu核数
	UsedMem      string // 当前内存使用量
	TotalMem     string // 总分配的内存
	SysMem       string // 系统内存占用量
	Lookups      string // 指针查找次数
	Mallocs      string // 内存分配次数
	Frees        string // 内存释放次数
	LastGCTime   string // 距离上次GC时间
	NextGC       string // 下次GC内存回收量
	PauseTotalNs string // GC暂停时间总量
	PauseNs      string // 上次GC暂停时间
	HeapInuse    string // 正在使用的堆内存
}

SystemInfo SystemInfo

func NewSystemInfo added in v0.1.21

func NewSystemInfo(startTime time.Time) *SystemInfo

Jump to

Keyboard shortcuts

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