topo

package
v0.0.0-...-4bf4393 Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2022 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	SysStatNew     *psss.SystemStat
	SysStatOld     *psss.SystemStat
	GlobalTopology *Topology

	MsgpBuffer *bytes.Buffer
	MsgpWriter *msgp.Writer
)

Functions

This section is empty.

Types

type Addr

type Addr struct {
	Host string `zid:"0"`
	Port string `zid:"1"`
}

func (*Addr) DecodeMsg

func (z *Addr) DecodeMsg(dc *msgp.Reader) (err error)

DecodeMsg implements msgp.Decodable We treat empty fields as if we read a Nil from the wire.

func (Addr) EncodeMsg

func (z Addr) EncodeMsg(en *msgp.Writer) (err error)

EncodeMsg implements msgp.Encodable

func (Addr) MarshalMsg

func (z Addr) MarshalMsg(b []byte) (o []byte, err error)

MarshalMsg implements msgp.Marshaler

func (Addr) Msgsize

func (z Addr) Msgsize() (s int)

Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message

func (*Addr) String

func (a *Addr) String() string

func (*Addr) UnmarshalMsg

func (z *Addr) UnmarshalMsg(bts []byte) (o []byte, err error)

UnmarshalMsg implements msgp.Unmarshaler

func (*Addr) UnmarshalMsgWithCfg

func (z *Addr) UnmarshalMsgWithCfg(bts []byte, cfg *msgp.RuntimeConfig) (o []byte, err error)

type AddrSet

type AddrSet map[Addr]AddrState

type AddrState

type AddrState struct {
	Count int `zid:"0"`
	// contains filtered or unexported fields
}

func (*AddrState) DecodeMsg

func (z *AddrState) DecodeMsg(dc *msgp.Reader) (err error)

DecodeMsg implements msgp.Decodable We treat empty fields as if we read a Nil from the wire.

func (AddrState) EncodeMsg

func (z AddrState) EncodeMsg(en *msgp.Writer) (err error)

EncodeMsg implements msgp.Encodable

func (AddrState) MarshalMsg

func (z AddrState) MarshalMsg(b []byte) (o []byte, err error)

MarshalMsg implements msgp.Marshaler

func (AddrState) Msgsize

func (z AddrState) Msgsize() (s int)

Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message

func (*AddrState) UnmarshalMsg

func (z *AddrState) UnmarshalMsg(bts []byte) (o []byte, err error)

UnmarshalMsg implements msgp.Unmarshaler

func (*AddrState) UnmarshalMsgWithCfg

func (z *AddrState) UnmarshalMsgWithCfg(bts []byte, cfg *msgp.RuntimeConfig) (o []byte, err error)

func (*AddrState) Update

func (a *AddrState) Update()

type FileSchema_go

type FileSchema_go struct{}

FileSchema_go holds ZebraPack schema from file 'topo/dataExt.go'

func (FileSchema_go) ZebraSchemaInJsonCompact

func (FileSchema_go) ZebraSchemaInJsonCompact() []byte

ZebraSchemaInJsonCompact provides the ZebraPack Schema in compact JSON format, length 3309 bytes

func (FileSchema_go) ZebraSchemaInJsonPretty

func (FileSchema_go) ZebraSchemaInJsonPretty() []byte

ZebraSchemaInJsonPretty provides the ZebraPack Schema in pretty JSON format, length 8948 bytes

func (FileSchema_go) ZebraSchemaInMsgpack2Format

func (FileSchema_go) ZebraSchemaInMsgpack2Format() []byte

ZebraSchemaInMsgpack2Format provides the ZebraPack Schema in msgpack2 format, length 2589 bytes

type ProcInfoReserve

type ProcInfoReserve struct {
	Utime uint64
	Stime uint64
	Fresh bool
}

type ProcStat

type ProcStat struct {
	StartTime   int64   `zid:"0"`
	State       string  `zid:"1"`
	LoadAvg     float64 `zid:"2"`
	LoadInstant float64 `zid:"3"`
	VmSize      uint64  `zid:"4"`
	VmRSS       uint64  `zid:"5"`
	// contains filtered or unexported fields
}

func (*ProcStat) DecodeMsg

func (z *ProcStat) DecodeMsg(dc *msgp.Reader) (err error)

DecodeMsg implements msgp.Decodable We treat empty fields as if we read a Nil from the wire.

func (*ProcStat) EncodeMsg

func (z *ProcStat) EncodeMsg(en *msgp.Writer) (err error)

EncodeMsg implements msgp.Encodable

func (*ProcStat) MarshalMsg

func (z *ProcStat) MarshalMsg(b []byte) (o []byte, err error)

MarshalMsg implements msgp.Marshaler

func (*ProcStat) Msgsize

func (z *ProcStat) Msgsize() (s int)

Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message

func (*ProcStat) UnmarshalMsg

func (z *ProcStat) UnmarshalMsg(bts []byte) (o []byte, err error)

UnmarshalMsg implements msgp.Unmarshaler

func (*ProcStat) UnmarshalMsgWithCfg

func (z *ProcStat) UnmarshalMsgWithCfg(bts []byte, cfg *msgp.RuntimeConfig) (o []byte, err error)

type ServiceInfo

type ServiceInfo struct {
	ProcsStat  map[int]ProcStat     `zid:"0"`
	DoListen   bool                 `zid:"1"`
	Addrs      map[string]AddrState `zid:"2" msgp:"omitempty"` // this field represents: listening addrs when DoListen is set, and remote addrs when DoListen is reset
	UpStream   map[string]AddrState `zid:"3" msgp:"omitempty"` // this field will not be nil only DoListen is set
	DownStream map[string]AddrState `zid:"4" msgp:"omitempty"` // this field will not be nil only DoListen is set
	// contains filtered or unexported fields
}

func NewServiceInfo

func NewServiceInfo() *ServiceInfo

func (*ServiceInfo) DecodeMsg

func (z *ServiceInfo) DecodeMsg(dc *msgp.Reader) (err error)

DecodeMsg implements msgp.Decodable We treat empty fields as if we read a Nil from the wire.

func (*ServiceInfo) EncodeMsg

func (z *ServiceInfo) EncodeMsg(en *msgp.Writer) (err error)

EncodeMsg implements msgp.Encodable

func (*ServiceInfo) MarshalMsg

func (z *ServiceInfo) MarshalMsg(b []byte) (o []byte, err error)

MarshalMsg implements msgp.Marshaler

func (*ServiceInfo) Msgsize

func (z *ServiceInfo) Msgsize() (s int)

Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message

func (*ServiceInfo) UnmarshalMsg

func (z *ServiceInfo) UnmarshalMsg(bts []byte) (o []byte, err error)

UnmarshalMsg implements msgp.Unmarshaler

func (*ServiceInfo) UnmarshalMsgWithCfg

func (z *ServiceInfo) UnmarshalMsgWithCfg(bts []byte, cfg *msgp.RuntimeConfig) (o []byte, err error)

type Topology

type Topology struct {
	Services map[string]*ServiceInfo `zid:"0"`
	Time     int64                   `zid:"1"`
	// contains filtered or unexported fields
}

func NewTopology

func NewTopology() *Topology

func (*Topology) DecodeMsg

func (z *Topology) DecodeMsg(dc *msgp.Reader) (err error)

DecodeMsg implements msgp.Decodable We treat empty fields as if we read a Nil from the wire.

func (*Topology) EncodeMsg

func (z *Topology) EncodeMsg(en *msgp.Writer) (err error)

EncodeMsg implements msgp.Encodable

func (*Topology) GetProcInfo

func (t *Topology) GetProcInfo() (err error)

func (*Topology) GetSockInfo

func (t *Topology) GetSockInfo() (err error)

func (*Topology) MarshalMsg

func (z *Topology) MarshalMsg(b []byte) (o []byte, err error)

MarshalMsg implements msgp.Marshaler

func (*Topology) Msgsize

func (z *Topology) Msgsize() (s int)

Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message

func (*Topology) PrintAll

func (t *Topology) PrintAll()

func (*Topology) UnmarshalMsg

func (z *Topology) UnmarshalMsg(bts []byte) (o []byte, err error)

UnmarshalMsg implements msgp.Unmarshaler

func (*Topology) UnmarshalMsgWithCfg

func (z *Topology) UnmarshalMsgWithCfg(bts []byte, cfg *msgp.RuntimeConfig) (o []byte, err error)

Jump to

Keyboard shortcuts

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