model

package
v0.0.0-...-58d9a08 Latest Latest
Warning

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

Go to latest
Published: May 27, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TimeFormat    = "2006-01-02 15:04:05"
	DockerRuntime = "docker"
)
View Source
const (
	ObjectNameSplit = "/"
)

Variables

This section is empty.

Functions

func ParseContainerID

func ParseContainerID(cID string) (r, id string, err error)

func ParseContainerInfo

func ParseContainerInfo(containerStr string) (ns, podName, containerName string, err error)

func ParseDeploymentInfo

func ParseDeploymentInfo(str string) (nodeName, nodeIP string, err error)

func ParseNodeInfo

func ParseNodeInfo(nodeStr string) (nodeName, nodeIP string, err error)

func ParsePodInfo

func ParsePodInfo(podStr string) (ns, podName string, err error)

Types

type AtomicObject

type AtomicObject interface {
	GetObjectName() string
}

type ContainerInfo

type ContainerInfo struct {
	ContainerRuntime string
	ContainerId      string
	ContainerName    string
}

type ContainerObject

type ContainerObject struct {
	Namespace        string
	PodName          string
	PodUID           string
	PodIP            string
	NodeName         string
	NodeIP           string
	ContainerRuntime string
	ContainerId      string
	ContainerName    string
}

func (*ContainerObject) GetObjectName

func (c *ContainerObject) GetObjectName() string

type DaemonSetObject

type DaemonSetObject struct {
	DaemonSetName string
	Namespace     string
}

func (*DaemonSetObject) GetObjectName

func (d *DaemonSetObject) GetObjectName() string

type DeploymentObject

type DeploymentObject struct {
	Namespace      string
	DeploymentName string
}

func (*DeploymentObject) GetObjectName

func (d *DeploymentObject) GetObjectName() string

type NamespaceObject

type NamespaceObject struct {
	Namespace string
}

func (*NamespaceObject) GetObjectName

func (p *NamespaceObject) GetObjectName() string

type NodeObject

type NodeObject struct {
	NodeName         string
	NodeInternalIP   string
	HostName         string
	ContainerID      string
	ContainerRuntime string
}

func (*NodeObject) GetObjectName

func (n *NodeObject) GetObjectName() string

type PodObject

type PodObject struct {
	Namespace  string
	PodName    string
	PodUID     string
	PodIP      string
	NodeName   string
	NodeIP     string
	Containers []ContainerInfo
}

func (*PodObject) GetObjectName

func (p *PodObject) GetObjectName() string

func (*PodObject) GetSubObjects

func (p *PodObject) GetSubObjects() []ContainerObject

type SubExpInfo

type SubExpInfo struct {
	UID        string              `json:"uid"`
	Status     v1alpha1.StatusType `json:"status"`
	CreateTime string              `json:"create_time,omitempty"`
	UpdateTime string              `json:"update_time,omitempty"`
	Message    string              `json:"error,omitempty"`
}

Jump to

Keyboard shortcuts

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