engine

package
v2.3.2+incompatible Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2018 License: MIT Imports: 23 Imported by: 3

Documentation

Index

Constants

View Source
const (
	EtcdResourcesKey       = "/lain/config/resources"
	EtcdGuardSwitchKey     = "/lain/config/guardswitch"
	EtcdCloudVolumeRootKey = "/lain/config/cloud_volumes_root"
	EtcdVolumeRootKey      = "/lain/config/volumes_root"

	EtcdConfigKey = "/lain/deployd/engine/config"

	DefaultLastSpecCacheTTL = 10 * 60    // 10min
	DefautDeviceRatio       = uint64(70) // 70% so should / 100
)
View Source
const (
	KCntStatus          = "/lain/deployd/histroy"
	FmtKCntStatusLstPos = "/lain/deployd/histroy/%s/%d/lastpos"
	FmtKCntStatusInfo   = "/lain/deployd/histroy/%s/%d/%d"

	DefaultStatusSize = 20
)

cnt means container

View Source
const (
	DefaultHealthInterval = 10
	DefaultHealthTimeout  = 3
	DefaultHealthRetries  = 3

	DefaultSetUpTime = 20

	CPUQuota        = int64(1000000)
	CPUMaxPctg      = 50 // max percentage of total cpu
	CPUMaxLevel     = 8
	CPUDeafultLevel = 2

	CURL_TMPLT = `echo $(curl -m %v -s -o /dev/null -w '%%{http_code}\n' %s) | grep -Eq "^[2-3]..$"`
)
View Source
const (
	OperationStart = "start"
	OperationOver  = "over"
)
View Source
const (
	RunStatePending      = iota // waiting for operation
	RunStateDrift               // drifting from one node to another
	RunStateSuccess             // ok
	RunStateExit                // exited
	RunStateFail                // start failed with error
	RunStateInconsistent        // container's state is different between deployd and swarm
	RunStateMissing             // container is missing and need create it. happened when node down .etc
	RunStateRemoved             // removed
	RunStatePaused              // paused
	RunStateError               // call docker interface with error
)
View Source
const (
	HealthStateNone = iota
	HealthStateStarting
	HealthStateHealthy
	HealthStateUnHealthy
)
View Source
const (
	ExpectStateRun = iota
	ExpectStateStop
)
View Source
const (
	PGOpStateIdle = iota
	PGOpStateUpgrading
	PGOpStateScheduling
	PGOpStateDrifting
	PGOpStateRemoving
	PGOpStateStarting
	PGOpStateStoping
	PGOpStateRestarting
)
View Source
const (
	MinPodSetupTime = 0
	MaxPodSetupTime = 300

	MinPodKillTimeout = 10
	MaxPodKillTimeout = 120
)
View Source
const (
	CloudVolumeSingleMode = "single"
	CloudVolumeMultiMode  = "multi"
)
View Source
const (
	DependencyNamespaceLevel = iota
	DependencyNodeLevel
)
View Source
const (
	RestartPolicyNever = iota
	RestartPolicyAlways
	RestartPolicyOnFail
)
View Source
const (
	ClusterFailedThreadSold = 20
)
View Source
const (
	KeyPrefixStreamPorts = "/lain/deployd/stream/ports"
)

Variables

View Source
var (
	ErrPodGroupExists         = errors.New("PodGroup has already existed")
	ErrPodGroupNotExists      = errors.New("PodGroup not existed")
	ErrPodGroupCleaning       = errors.New("PodGroup is removing, need to wait for that")
	ErrNotEnoughResources     = errors.New("Not enough CPUs and Memory to use")
	ErrDependencyPodExists    = errors.New("DependencyPod has already existed")
	ErrDependencyPodNotExists = errors.New("DependencyPod not existed")
	ErrConstraintNotExists    = errors.New("Constraint not existed")
	ErrNotifyNotExists        = errors.New("Notify uri not existed")
)
View Source
var (
	NotifyPodMissing   = "LAIN found pod missing, ready to redeployd it"
	NotifyPodDown      = "LAIN found pod down, ready to restart it"
	NotifyPodDownOOM   = "LAIN found pod down with OOM, ready to restart it"
	NotifyLetPodGo     = "LAIN found pod restart too many times in a short period, will let it go"
	NotifyPodIPLost    = "LAIN found pod lost IP, please inform the SA team"
	NotifyPodUnHealthy = "LAIN found pod Unhealthy, please check your service"

	NotifyClusterUnHealthy = "LAIN found Cluster Manager Unhealthy, please check your cluster"

	NotifyUpgradeFailedTmplt = "LAIN found Last version:%d upgrade is terrrible, please check your code carefully!!"
)
View Source
var ByVersionAndDriftCounter = func(c1, c2 *container) bool {
	return c1.version > c2.version ||
		(c1.version == c2.version && c1.driftCount > c2.driftCount)
}
View Source
var DependsGarbageCollectTimeout time.Duration

set GarbageCollectTimeout long enough. sometimes, podgroup refresh goroutine may having some problem(such as swarm exception), and do not verify it's portal for a long time

View Source
var (
	ErrOperLockedFormat = "Another operation \"%s\" is progressing"
)
View Source
var RefreshInterval int
View Source
var RestartInfoClearInterval time.Duration

some instances written with JAVA like language may suffer from OOM, if they are restarted before (now - RestartInfoClearInterval), clear the restart info

View Source
var RestartMaxCount int

Functions

func CancelPorts

func CancelPorts(sps ...*StreamProc)

func ConfigEngine

func ConfigEngine(engine *OrcEngine) bool

func ConfigPortsManager

func ConfigPortsManager(endpoint string)

func GuardGotoSleep

func GuardGotoSleep(store storage.Store) bool

func GuardGotoWork

func GuardGotoWork(store storage.Store) bool

func HandleDockerEvent

func HandleDockerEvent(engine *OrcEngine, event *adoc.Event)

func MaintainEngineStatusHistory

func MaintainEngineStatusHistory(engine *OrcEngine)

func NewConstraintController

func NewConstraintController() *constraintController

func NewNotifyController

func NewNotifyController(stop chan struct{}) *notifyController

func NewPodStatusHistory

func NewPodStatusHistory(podname string, instance int, status *StatusMessage) *podStatusHistory

func OccupiedPorts

func OccupiedPorts(ports ...int) []int

func RefreshPorts

func RefreshPorts(pgCtrls map[string]*podGroupController)

func RegisterPorts

func RegisterPorts(sps ...*StreamProc) (bool, []int)

func SyncEventsDataFromStorage

func SyncEventsDataFromStorage(engine *OrcEngine) bool

Sync with etcd data when start deployd ugly finished! should change with allKeysByPrefix(return all non-dir node)

func UpdatePorts

func UpdatePorts(sps ...*StreamProc)

func WatchEngineConfig

func WatchEngineConfig(engine *OrcEngine)

Types

type BaseRuntime

type BaseRuntime struct {
	Healthst  HealthState
	State     RunState
	OOMkilled bool
	LastError string
	UpdatedAt time.Time
}

type By

type By func(c1, c2 *container) bool

By is the type of a "less" function that defines the ordering of its Planet arguments.

func (By) Sort

func (by By) Sort(containers []*container)

Sort is a method on the function type, By, that sorts the argument slice according to the function.

type CloudVolumeSpec

type CloudVolumeSpec struct {
	Type string
	Dirs []string
}

func (CloudVolumeSpec) Clone

func (s CloudVolumeSpec) Clone() CloudVolumeSpec

func (CloudVolumeSpec) Equals

func (s CloudVolumeSpec) Equals(o CloudVolumeSpec) bool

func (CloudVolumeSpec) VerifyParams

func (s CloudVolumeSpec) VerifyParams() bool

type ConstraintSpec

type ConstraintSpec struct {
	Type  string
	Equal bool
	Value string
	Soft  bool
}

type Container

type Container struct {
	// FIXME(mijia): multiple ports supporing, will have multiple entries of <NodePort, ContainerPort, Protocol>
	Id            string
	Runtime       adoc.ContainerDetail
	NodeName      string
	NodeIp        string
	ContainerIp   string
	NodePort      int
	ContainerPort int
	Protocol      string
}

func (Container) Clone

func (c Container) Clone() Container

func (Container) Equals

func (c Container) Equals(o Container) bool

type ContainerLabel

type ContainerLabel struct {
	Name           string
	Namespace      string
	InstanceNo     int
	Version        int
	DriftCount     int
	ContainerIndex int
	Annotation     string
}

func (*ContainerLabel) FromMaps

func (label *ContainerLabel) FromMaps(m map[string]string) bool

func (ContainerLabel) Label2Maps

func (label ContainerLabel) Label2Maps() map[string]string

func (ContainerLabel) NameAffinity

func (label ContainerLabel) NameAffinity() string

type ContainerSpec

type ContainerSpec struct {
	ImSpec
	Image         string
	Env           []string
	User          string
	WorkingDir    string
	DnsSearch     []string
	Volumes       []string // a stateful flag
	SystemVolumes []string // not a stateful flag, every node has system volumes
	CloudVolumes  []CloudVolumeSpec
	Command       []string
	Entrypoint    []string
	CpuLimit      int
	MemoryLimit   int64
	Expose        int
	LogConfig     adoc.LogConfig
}

func NewContainerSpec

func NewContainerSpec(image string) ContainerSpec

func (ContainerSpec) Clone

func (s ContainerSpec) Clone() ContainerSpec

func (ContainerSpec) Equals

func (s ContainerSpec) Equals(o ContainerSpec) bool

func (ContainerSpec) VerifyParams

func (s ContainerSpec) VerifyParams() bool

type Dependency

type Dependency struct {
	PodName string
	Policy  DependencyPolicy
}

func (Dependency) Clone

func (d Dependency) Clone() Dependency

type DependencyEvent

type DependencyEvent struct {
	Type      string // add, remove, verify
	Name      string
	NodeName  string
	Namespace string
}

type DependencyPolicy

type DependencyPolicy int

type Device

type Device struct {
	Path    string `json:"path"`
	MaxIops uint64 `json:"iops"`
	MaxRate string `json:"rate"`
	Ratio   uint64 `json:"ratio,omitempty"`
}

type EngineConfig

type EngineConfig struct {
	ReadOnly    bool `json:"readonly"`
	Maintenance bool `json:"maintenance"`
}

type ExpectState

type ExpectState int

func (ExpectState) String

func (es ExpectState) String() string

type Guard

type Guard struct {
	Working bool `json:"Working"`
}

func FetchGuard

func FetchGuard() *Guard

type HealthCnfOptions

type HealthCnfOptions struct {
	Interval int `json:"interval"`
	Timeout  int `json:"timeout"`
	Retries  int `json:"retries"`
}

func (HealthCnfOptions) Equals

func (hco HealthCnfOptions) Equals(cp HealthCnfOptions) bool

type HealthConfig

type HealthConfig struct {
	Cmd     string           `json:"cmd"`
	Options HealthCnfOptions `json:"options"`
}

func (HealthConfig) Equals

func (hc HealthConfig) Equals(cp HealthConfig) bool

func (HealthConfig) FetchOption

func (hc HealthConfig) FetchOption() HealthCnfOptions

type HealthState

type HealthState int

func (HealthState) String

func (hs HealthState) String() string

type ImRuntime

type ImRuntime struct {
	BaseRuntime
	TargetState  ExpectState
	DriftCount   int
	RestartCount int
	RestartAt    time.Time
}

type ImSpec

type ImSpec struct {
	Name      string
	Namespace string
	Version   int
	CreatedAt time.Time
	UpdatedAt time.Time
}

type Listener

type Listener interface {
	ListenerId() string
	HandleEvent(payload interface{})
}

type LockedError

type LockedError interface {
	error
}

type NamespacePodsWithSpec

type NamespacePodsWithSpec struct {
	Spec PodSpec
	Pods map[string][]Pod
}

type NotifySpec

type NotifySpec struct {
	Level      string
	Namespace  string
	PodName    string
	InstanceNo int
	Timestamp  time.Time
	Message    string
}

func NewNotifySpec

func NewNotifySpec(namespace string, podName string, instanceNo int, timestamp time.Time, message string) NotifySpec

type OperLockedError

type OperLockedError struct {
	// contains filtered or unexported fields
}

func (OperLockedError) Error

func (ole OperLockedError) Error() string

type OperationEvent

type OperationEvent struct {
	Type   string // start, over
	PgName string
}

type OrcEngine

type OrcEngine struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

func New

func New(cluster cluster.Cluster, store storage.Store) (*OrcEngine, error)

func (*OrcEngine) AddNotify

func (engine *OrcEngine) AddNotify(callback string) error

func (*OrcEngine) ChangeState

func (engine *OrcEngine) ChangeState(pgName, op string, instance int) error

func (*OrcEngine) Config

func (engine *OrcEngine) Config() EngineConfig

func (*OrcEngine) DeleteConstraints

func (engine *OrcEngine) DeleteConstraints(cstType string) error

func (*OrcEngine) DeleteNotify

func (engine *OrcEngine) DeleteNotify(callback string) error

func (*OrcEngine) DriftNode

func (engine *OrcEngine) DriftNode(fromNode, toNode string, pgName string, pgInstance int, force bool)

func (*OrcEngine) FetchPodStaHstry

func (engine *OrcEngine) FetchPodStaHstry(name string, instance int) []*StatusMessage

func (*OrcEngine) GetConstraints

func (engine *OrcEngine) GetConstraints(cstType string) (ConstraintSpec, bool)

func (*OrcEngine) GetDependencyPod

func (engine *OrcEngine) GetDependencyPod(name string) (NamespacePodsWithSpec, error)

func (*OrcEngine) GetNodes

func (engine *OrcEngine) GetNodes() ([]cluster.Node, error)

func (*OrcEngine) GetNotifies

func (engine *OrcEngine) GetNotifies() []string

func (*OrcEngine) GuardGotoSleep

func (engine *OrcEngine) GuardGotoSleep() bool

func (*OrcEngine) GuardGotoWork

func (engine *OrcEngine) GuardGotoWork() bool

func (*OrcEngine) HandleEvent

func (engine *OrcEngine) HandleEvent(payload interface{})

func (*OrcEngine) InspectPodGroup

func (engine *OrcEngine) InspectPodGroup(name string) (PodGroupWithSpec, bool)

func (*OrcEngine) ListenerId

func (engine *OrcEngine) ListenerId() string

func (*OrcEngine) LoadDependsPods

func (engine *OrcEngine) LoadDependsPods() error

func (*OrcEngine) LoadPodGroups

func (engine *OrcEngine) LoadPodGroups() error

func (*OrcEngine) Maintaince

func (engine *OrcEngine) Maintaince(maintaince bool)

func (*OrcEngine) NewDependencyPod

func (engine *OrcEngine) NewDependencyPod(spec PodSpec) error

func (*OrcEngine) NewPodGroup

func (engine *OrcEngine) NewPodGroup(spec PodGroupSpec) error

func (*OrcEngine) PgOpOver

func (engine *OrcEngine) PgOpOver(pgName string)

func (*OrcEngine) PgOpStart

func (engine *OrcEngine) PgOpStart(pgName string)

func (*OrcEngine) ReadOnly

func (engine *OrcEngine) ReadOnly() bool

func (*OrcEngine) RefreshPodGroup

func (engine *OrcEngine) RefreshPodGroup(name string, forceUpdate bool) error

func (*OrcEngine) RemoveDependencyPod

func (engine *OrcEngine) RemoveDependencyPod(name string, force bool) error

func (*OrcEngine) RemoveNode

func (engine *OrcEngine) RemoveNode(node string) error

remove a node should be in such steps show below 1. make target node in maintenance with constraint 2. fetch all containers in target node 3. drift all containers in target node Asynchronously (which can make cluster corrupted but eagle will correct it, don't worry!

in situation: schedule instance(generally shrink) and drift concurrently)

4. stop all process service for lain (generally by lainctl) 5. remove maintenance(generally by lainctl or called in add node phase)

func (*OrcEngine) RemovePodGroup

func (engine *OrcEngine) RemovePodGroup(name string) error

func (*OrcEngine) RescheduleInstance

func (engine *OrcEngine) RescheduleInstance(name string, numInstances int, restartPolicy ...RestartPolicy) error

func (*OrcEngine) RescheduleSpec

func (engine *OrcEngine) RescheduleSpec(name string, podSpec PodSpec) error

func (*OrcEngine) SetConfig

func (engine *OrcEngine) SetConfig(config EngineConfig)

func (*OrcEngine) Start

func (engine *OrcEngine) Start()

func (*OrcEngine) Started

func (engine *OrcEngine) Started() bool

func (*OrcEngine) Stop

func (engine *OrcEngine) Stop()

func (*OrcEngine) UpdateConstraints

func (engine *OrcEngine) UpdateConstraints(spec ConstraintSpec) error

func (*OrcEngine) UpdateDependencyPod

func (engine *OrcEngine) UpdateDependencyPod(spec PodSpec) error

type PGOpState

type PGOpState int32

func (PGOpState) String

func (pgos PGOpState) String() string

type Pod

type Pod struct {
	InstanceNo int
	Containers []Container
	ImRuntime
}

func (*Pod) ChangeTargetState

func (pod *Pod) ChangeTargetState(state ExpectState)

func (Pod) Clone

func (p Pod) Clone() Pod

func (Pod) ContainerIds

func (pod Pod) ContainerIds() []string

func (Pod) Equals

func (p Pod) Equals(o Pod) bool

func (Pod) NeedRestart

func (pod Pod) NeedRestart(policy RestartPolicy) bool

func (Pod) NodeIp

func (pod Pod) NodeIp() string

func (Pod) NodeName

func (pod Pod) NodeName() string

func (Pod) PodIp

func (pod Pod) PodIp() string

func (Pod) RestartEnoughTimes

func (pod Pod) RestartEnoughTimes() bool

type PodGroup

type PodGroup struct {
	Pods []Pod
	BaseRuntime
}

func (PodGroup) Clone

func (pg PodGroup) Clone() PodGroup

func (PodGroup) Equals

func (pg PodGroup) Equals(o PodGroup) bool

type PodGroupPrevState

type PodGroupPrevState struct {
	Nodes []string
	// we think a instance only have one ip, as now a instance only have one container.
	IPs []string
}

func (PodGroupPrevState) Clone

func (pgps PodGroupPrevState) Clone() PodGroupPrevState

func (PodGroupPrevState) Length

func (pgps PodGroupPrevState) Length() int

func (PodGroupPrevState) Reset

func (pgps PodGroupPrevState) Reset(instanceNo int) PodGroupPrevState

type PodGroupSpec

type PodGroupSpec struct {
	ImSpec
	Pod           PodSpec
	NumInstances  int
	RestartPolicy RestartPolicy
}

func NewPodGroupSpec

func NewPodGroupSpec(name string, namespace string, podSpec PodSpec, numInstances int) PodGroupSpec

func (PodGroupSpec) Clone

func (spec PodGroupSpec) Clone() PodGroupSpec

func (PodGroupSpec) Equals

func (spec PodGroupSpec) Equals(o PodGroupSpec) bool

func (PodGroupSpec) String

func (spec PodGroupSpec) String() string

func (PodGroupSpec) VerifyParams

func (spec PodGroupSpec) VerifyParams() bool

type PodGroupStatusHistory

type PodGroupStatusHistory struct {
	// contains filtered or unexported fields
}

type PodGroupWithSpec

type PodGroupWithSpec struct {
	Spec      PodGroupSpec
	PrevState []PodPrevState
	PodGroup
}

type PodPrevState

type PodPrevState struct {
	NodeName string
	IPs      []string
}

func NewPodPrevState

func NewPodPrevState(length int) PodPrevState

func (PodPrevState) Clone

func (pps PodPrevState) Clone() PodPrevState

type PodSpec

type PodSpec struct {
	ImSpec
	Network      string
	Containers   []ContainerSpec
	Filters      []string // for cluster scheduling
	Labels       map[string]string
	Dependencies []Dependency
	Annotation   string
	Stateful     bool
	SetupTime    int
	KillTimeout  int
	PrevState    PodPrevState
	HealthConfig HealthConfig
}

func NewPodSpec

func NewPodSpec(containerSpec ContainerSpec, otherSpecs ...ContainerSpec) PodSpec

func (PodSpec) Clone

func (s PodSpec) Clone() PodSpec

func (PodSpec) Equals

func (s PodSpec) Equals(o PodSpec) bool

func (PodSpec) GetKillTimeout

func (s PodSpec) GetKillTimeout() int

func (PodSpec) GetSetupTime

func (s PodSpec) GetSetupTime() int

func (PodSpec) HasVolumes

func (s PodSpec) HasVolumes() bool

func (PodSpec) IsHardStateful

func (s PodSpec) IsHardStateful() bool

func (PodSpec) IsStateful

func (s PodSpec) IsStateful() bool

func (PodSpec) Merge

func (s PodSpec) Merge(o PodSpec) PodSpec

func (PodSpec) String

func (s PodSpec) String() string

func (PodSpec) VerifyParams

func (s PodSpec) VerifyParams() bool

type PortsManager

type PortsManager struct {
	// contains filtered or unexported fields
}

func NewPortsManager

func NewPortsManager(endpoint string) *PortsManager

func (*PortsManager) CancelStreamPort

func (pm *PortsManager) CancelStreamPort(sp *StreamProc) bool

func (PortsManager) CancelStreamPorts

func (pm PortsManager) CancelStreamPorts(spArr ...*StreamProc)

func (PortsManager) FetchAllStreamPortsInfo

func (pm PortsManager) FetchAllStreamPortsInfo() []StreamProc

func (PortsManager) Refresh

func (pm PortsManager) Refresh(pgCtrls map[string]*podGroupController)

func (PortsManager) RegisterStreamPort

func (pm PortsManager) RegisterStreamPort(sp *StreamProc) bool

func (PortsManager) RegisterStreamPorts

func (pm PortsManager) RegisterStreamPorts(spArr ...*StreamProc) (bool, []int)

func (*PortsManager) UpdateStreamPort

func (pm *PortsManager) UpdateStreamPort(sp *StreamProc) bool

func (PortsManager) UpdateStreamPorts

func (pm PortsManager) UpdateStreamPorts(spArr ...*StreamProc)

type Publisher

type Publisher interface {
	EmitEvent(payload interface{})
	AddListener(subscriber Listener)
	RemoveListener(subscriber Listener)
}

func NewPublisher

func NewPublisher(goRoutine bool) Publisher

type Resource

type Resource struct {
	Cpu     int      `json:"cpu"`
	Memory  string   `json:"memory"`
	Devices []Device `json:"devices"`
}

func FetchResource

func FetchResource() *Resource

type RestartPolicy

type RestartPolicy int

func (RestartPolicy) String

func (rp RestartPolicy) String() string

type RunState

type RunState int

func (RunState) String

func (rs RunState) String() string

type RuntimeEaglePod

type RuntimeEaglePod struct {
	ContainerLabel
	Container   adoc.Container
	ParseSource string
}

func (RuntimeEaglePod) String

func (pod RuntimeEaglePod) String() string

type RuntimeEagleView

type RuntimeEagleView struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

func NewRuntimeEagleView

func NewRuntimeEagleView() *RuntimeEagleView

func (*RuntimeEagleView) Activate

func (ev *RuntimeEagleView) Activate(c cluster.Cluster)

func (*RuntimeEagleView) GetRuntimeEaglePods

func (ev *RuntimeEagleView) GetRuntimeEaglePods(name string) ([]RuntimeEaglePod, bool)

func (*RuntimeEagleView) Refresh

func (ev *RuntimeEagleView) Refresh(c cluster.Cluster) error

func (*RuntimeEagleView) RefreshPodGroup

func (ev *RuntimeEagleView) RefreshPodGroup(c cluster.Cluster, pgName string) ([]RuntimeEaglePod, error)

func (*RuntimeEagleView) RefreshPodsByNamespace

func (ev *RuntimeEagleView) RefreshPodsByNamespace(c cluster.Cluster, namespace string) ([]RuntimeEaglePod, error)

type SharedPodWithSpec

type SharedPodWithSpec struct {
	RefCount   int
	VerifyTime time.Time
	Spec       PodSpec
	Pod        Pod
}

type StatusLastPos

type StatusLastPos struct {
	Pos  int
	Size int
}

type StatusMessage

type StatusMessage struct {
	Status string `json:"status,omitempty"`
	From   string `json:"from,omitempty"`
	Time   int64  `json:"time,omitempty"`
	Action string `json:"action,omitempty"`
}

func FetchPodStaHstry

func FetchPodStaHstry(engine *OrcEngine, podname string, instance int) []*StatusMessage

type StreamPort

type StreamPort struct {
	SrcPort int    `json:"srcport"`
	DstPort int    `json:"dstport"`
	Proto   string `json:"proto"`
}

func (StreamPort) Equals

func (sp StreamPort) Equals(osp StreamPort) bool

type StreamPorts

type StreamPorts struct {
	Ports []StreamPort `json:"ports"`
}

func (StreamPorts) Equals

func (sp StreamPorts) Equals(osp StreamPorts) bool

type StreamProc

type StreamProc struct {
	StreamPort
	NameSpace string
	ProcName  string
}

func FetchAllPortsInfo

func FetchAllPortsInfo() []StreamProc

Jump to

Keyboard shortcuts

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