data_collector

package
v0.0.0-...-33e2e76 Latest Latest
Warning

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

Go to latest
Published: Mar 16, 2020 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AllConfigMapsPerNamespace

func AllConfigMapsPerNamespace(clientset *kubernetes.Clientset, namespaces []string) map[string]*ConfigMapsPerNamespaceDetails

func AllDeploymentsPerNamespace

func AllDeploymentsPerNamespace(clientset *kubernetes.Clientset, namespaces []string) map[string]*DeploymentPerNamespaceDetails

func AllEndPointsPerNamespace

func AllEndPointsPerNamespace(clientset *kubernetes.Clientset, namespace []string) map[string]*EndPointsPerNamespaceDetails

func AllPodsPerNamespace

func AllPodsPerNamespace(clientset *kubernetes.Clientset, namespaces []string) map[string]*PodsPerNameSpaceDetails

func AllReplicaSetsPerNamespace

func AllReplicaSetsPerNamespace(clientset *kubernetes.Clientset, namespaces []string) map[string]*ReplicaSetPerNamespaceDetails

func AllRolesPerNamespace

func AllRolesPerNamespace(clientset *kubernetes.Clientset, namespaces []string) map[string]*RolesPerNamespaceDetails

func AllServicesPerNamespace

func AllServicesPerNamespace(clietset *kubernetes.Clientset, namespaces []string) map[string]*ServicePerNamespaceDetails

func GetAllNamespaces

func GetAllNamespaces(nsc *NamespaceClient) *v1.NamespaceList

func GetAllNodesDetails

func GetAllNodesDetails(clientset *kubernetes.Clientset) map[string]*NodeDetails

Types

type ConfigMapClient

type ConfigMapClient struct {
	Clientset *kubernetes.Clientset
}

type ConfigMapInfo

type ConfigMapInfo struct {
	Name              string
	UID               types.UID
	Namespace         string
	APIVersion        string
	ClusterName       string
	CreationTimestamp metav1.Time
	DataSize          int
	BinaryDataSize    int
}

type ConfigMapsPerNamespaceDetails

type ConfigMapsPerNamespaceDetails struct {
	Namespace      string
	ConfigMapsInfo []ConfigMapInfo
}

func GetAllConfigMapByNamespace

func GetAllConfigMapByNamespace(cmc *ConfigMapClient, namespace string) *ConfigMapsPerNamespaceDetails

type DeploymentClient

type DeploymentClient struct {
	Clientset *kubernetes.Clientset
}

type DeploymentInfo

type DeploymentInfo struct {
	Name              string
	UID               types.UID
	Namespace         string
	APIVersion        string
	ClusterName       string
	CreationTimestamp metav1.Time
	Replicas          *int32
}

type DeploymentPerNamespaceDetails

type DeploymentPerNamespaceDetails struct {
	TotalDeployments int32
	Namespace        string
	DeploymentsInfo  []DeploymentInfo
}

func GetAllDeploymentsByNamespace

func GetAllDeploymentsByNamespace(dc *DeploymentClient, namespace string) *DeploymentPerNamespaceDetails

type EndPointsClient

type EndPointsClient struct {
	Clientset *kubernetes.Clientset
}

type EndPointsInfo

type EndPointsInfo struct {
	Name              string
	UID               types.UID
	Namespace         string
	APIVersion        string
	ClusterName       string
	CreationTimestamp metav1.Time
	Subsets           []v1.EndpointSubset
}

type EndPointsPerNamespaceDetails

type EndPointsPerNamespaceDetails struct {
	Namespace     string
	EndpointsInfo []EndPointsInfo
}

func GetAllEndPointsByNamespace

func GetAllEndPointsByNamespace(epc *EndPointsClient, namespace string) *EndPointsPerNamespaceDetails

type MaxPodsPerNode

type MaxPodsPerNode int8

type NamespaceClient

type NamespaceClient struct {
	Clientset *kubernetes.Clientset
}

type NamespaceDetails

type NamespaceDetails struct {
	NamespacesInfo []NamespaceInfo
	NamespaceNames []string
}

func GetNameSpaceDetails

func GetNameSpaceDetails(clientset *kubernetes.Clientset) *NamespaceDetails

func (*NamespaceDetails) GetNamespaceDetails

func (nsd *NamespaceDetails) GetNamespaceDetails(nsl *v1.NamespaceList)

func (*NamespaceDetails) Serialize

func (nsd *NamespaceDetails) Serialize() (string, error)

type NamespaceInfo

type NamespaceInfo struct {
	Name              string
	UID               types.UID
	Status            v1.NamespacePhase
	CreationTimestamp metav1.Time
}

type NodeAddress

type NodeAddress struct {
	Address string
	Type    string
}

type NodeCapacity

type NodeCapacity struct {
	CPU              string
	Memory           string
	EphemeralStorage string
	Pods             MaxPodsPerNode
}

type NodeClient

type NodeClient struct {
	Clientset *kubernetes.Clientset
}

type NodeDetails

type NodeDetails struct {
	NodeInfo       *NodeInfo
	NodeAddresses  []NodeAddress
	NodeSystemInfo *NodeSystemInfo
	NodeCapacity   *NodeCapacity
}

type NodeInfo

type NodeInfo struct {
	Name string
	UID  types.UID
}

type NodeSystemInfo

type NodeSystemInfo struct {
	Architecture     string
	KernelVersion    string
	KubeProxyVersion string
	KubeletVersion   string
	OperatingSystem  string
	OsImage          string
	SystemUUID       string
}

type PodClient

type PodClient struct {
	Clientset *kubernetes.Clientset
}

type PodInfo

type PodInfo struct {
	Name              string
	UID               types.UID
	Namespace         string
	APIVersion        string
	ClusterName       string
	CreationTimestamp metav1.Time
}

type PodsPerNameSpaceDetails

type PodsPerNameSpaceDetails struct {
	TotalPods int32
	Namespace string
	PodsInfo  []PodInfo
}

func GetAllPodsByNamespace

func GetAllPodsByNamespace(pc *PodClient, namespace string) *PodsPerNameSpaceDetails

func (*PodsPerNameSpaceDetails) Serialize

func (ppnsd *PodsPerNameSpaceDetails) Serialize() (string, error)

type ReplicaSetClient

type ReplicaSetClient struct {
	Clientset *kubernetes.Clientset
}

type ReplicaSetInfo

type ReplicaSetInfo struct {
	Name              string
	UID               types.UID
	Namespace         string
	APIVersion        string
	CLusterName       string
	CreationTimestamp metav1.Time
	Replicas          *int32
	ReadyReplicas     int32
	AvailableReplicas int32
}

type ReplicaSetPerNamespaceDetails

type ReplicaSetPerNamespaceDetails struct {
	TotalReplicaSets int32
	Namespace        string
	ReplicaSetsInfo  []ReplicaSetInfo
}

func GetAllReplicaSetByNamespace

func GetAllReplicaSetByNamespace(rsc *ReplicaSetClient, namespace string) *ReplicaSetPerNamespaceDetails

type RolesClient

type RolesClient struct {
	Clientset *kubernetes.Clientset
}

type RolesInfo

type RolesInfo struct {
	Name              string
	UID               types.UID
	Namespace         string
	APIVersion        string
	Clustername       string
	CreationTimestamp metav1.Time
	Rules             []v1.PolicyRule
}

type RolesPerNamespaceDetails

type RolesPerNamespaceDetails struct {
	Namespace string
	RolesInfo []RolesInfo
}

func GetAllRolesByNamespace

func GetAllRolesByNamespace(rc *RolesClient, namespace string) *RolesPerNamespaceDetails

type ServiceClient

type ServiceClient struct {
	Clientset *kubernetes.Clientset
}

type ServiceInfo

type ServiceInfo struct {
	Name              string
	UID               types.UID
	Namespace         string
	APIVersion        string
	ClusterName       string
	CreationTimestamp metav1.Time
	Type              string
	Ports             []apiV1.ServicePort
	ClusterIP         string
	ExternalIPs       []string
}

type ServicePerNamespaceDetails

type ServicePerNamespaceDetails struct {
	Namespace    string
	ServicesInfo []ServiceInfo
}

func GetAllServiceByNamespace

func GetAllServiceByNamespace(sc *ServiceClient, namespace string) *ServicePerNamespaceDetails

Directories

Path Synopsis
v1

Jump to

Keyboard shortcuts

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