server

package
v0.0.0-...-e525d52 Latest Latest
Warning

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

Go to latest
Published: Jun 4, 2019 License: Apache-2.0 Imports: 11 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DefaultServiceInfo    = &ServiceInfo{}
	DefaultCollectionInfo = &CollectionInfo{}
	DefaultProfileFile    savefile.PPfile
	DefaultHeapFile       savefile.PPfile
	DefaultBlockFile      savefile.PPfile
	DefaultMutexFile      savefile.PPfile
	DefaultGoroutineFile  savefile.PPfile
)

Functions

func NewPProf

func NewPProf()

Types

type Block

type Block struct {
	PProf *PProf
}

func NewBlock

func NewBlock() *Block

func (*Block) GetURL

func (p *Block) GetURL() string

func (*Block) Handle

func (h *Block) Handle(c *gin.Context)

type CollectionInfo

type CollectionInfo struct {
	Seconds int32 `form:"collection_seconds"`
	Timeout int32 `form:"collection_timeout"`
}

type DebugPProf

type DebugPProf interface {
	GetURL() string
	Handle(c *gin.Context)
}

type Goroutine

type Goroutine struct {
	Debug int `form:"debug"` // 1 or 2
	PProf *PProf
}

func NewGoroutine

func NewGoroutine() *Goroutine

func (*Goroutine) GetDebugURL

func (h *Goroutine) GetDebugURL(debug int) string

func (*Goroutine) GetURL

func (h *Goroutine) GetURL() string

func (*Goroutine) Handle

func (h *Goroutine) Handle(c *gin.Context)

type Heap

type Heap struct {
	Type  string `form:"type"` // -inuse_space or -alloc_objects
	PProf *PProf
}

func NewHeap

func NewHeap() *Heap

func (*Heap) GetURL

func (h *Heap) GetURL() string

func (*Heap) Handle

func (h *Heap) Handle(c *gin.Context)

type Mutex

type Mutex struct {
	PProf *PProf
}

func NewMutex

func NewMutex() *Mutex

func (*Mutex) GetURL

func (p *Mutex) GetURL() string

func (*Mutex) Handle

func (h *Mutex) Handle(c *gin.Context)

type PProf

type PProf struct {
	Service    *ServiceInfo
	Collection *CollectionInfo
}

func (*PProf) BindBasicData

func (p *PProf) BindBasicData(c *gin.Context) error

func (*PProf) GetImageCompletePath

func (p *PProf) GetImageCompletePath(ppf savefile.PPfile, ext string) *profile.Path

func (*PProf) GetPbGzCompletePath

func (p *PProf) GetPbGzCompletePath(ppf savefile.PPfile, ext string) *profile.Path

func (*PProf) GetURL

func (p *PProf) GetURL(profilingUrl string) string

func (*PProf) HandleImage

func (p *PProf) HandleImage(saver save.Save, avgs []string) (int, error)

func (*PProf) HanldePzPb

func (p *PProf) HanldePzPb(url string, saver save.Save) (int, error)

func (*PProf) Response

func (p *PProf) Response(path *profile.CompletePath) map[string]string

type Profile

type Profile struct {
	PProf *PProf
}

func NewProfile

func NewProfile() *Profile

func (*Profile) GetURL

func (p *Profile) GetURL() string

func (*Profile) Handle

func (p *Profile) Handle(c *gin.Context)

type ServiceInfo

type ServiceInfo struct {
	Name      string `form:"service_name" binding:"required"`
	Port      int64  `form:"service_port" binding:"required"`
	Namespace string `form:"namespace"`
}

Jump to

Keyboard shortcuts

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