Documentation ¶
Index ¶
- Constants
- func MetricsQuery(statement string) (*proModel.Vector, error)
- func NodeCpuTotalCount(nodes []*model.ScNodeAvailInfo) ([]*model.ScNodeAvailInfo, error)
- func NodeCpuUsage(nodes []*model.ScNodeAvailInfo) ([]*model.ScNodeAvailInfo, error)
- func NodeDiskAvail(nodes []*model.ScNodeAvailInfo) ([]*model.ScNodeAvailInfo, error)
- func NodeDiskTotal(nodes []*model.ScNodeAvailInfo) ([]*model.ScNodeAvailInfo, error)
- func NodeMemoryAvail(nodes []*model.ScNodeAvailInfo) ([]*model.ScNodeAvailInfo, error)
- func NodeMemoryTotal(nodes []*model.ScNodeAvailInfo) ([]*model.ScNodeAvailInfo, error)
- func NodesDynamicInfo(svc *svc.ServiceContext) ([]*model.ScNodeAvailInfo, error)
- func NodesStaticInfo() ([]*model.ScNodePhyInfo, error)
- type ComputeResource
- type Queues
Constants ¶
View Source
const ( NODE_DISK_AVAIL = "node_filesystem_avail_bytes{fstype=~\"ext4|xfs\"}" NODE_DISK_TOTAL = "node_filesystem_size_bytes{fstype=~\"ext4|xfs\"}" NODE_MEMORY_AVAIL = "node_memory_MemAvailable_bytes" NODE_MEMORY_TOTAL = "node_memory_MemTotal_bytes" NODE_CPU_TOTAL_COUNT = "node:node_num_cpu:sum" NODE_CPU_USAGE = "" /* 128-byte string literal not displayed */ )
View Source
const ADDRESS = "http://10.101.15.3:32585"
Variables ¶
This section is empty.
Functions ¶
func NodeCpuTotalCount ¶
func NodeCpuTotalCount(nodes []*model.ScNodeAvailInfo) ([]*model.ScNodeAvailInfo, error)
NodeCpuTotalCount 查询cpu总核数
func NodeCpuUsage ¶
func NodeCpuUsage(nodes []*model.ScNodeAvailInfo) ([]*model.ScNodeAvailInfo, error)
NodeCpuUsage 查询cpu使用率
func NodeDiskAvail ¶
func NodeDiskAvail(nodes []*model.ScNodeAvailInfo) ([]*model.ScNodeAvailInfo, error)
NodeDiskAvail 查询磁盘可用空间
func NodeDiskTotal ¶
func NodeDiskTotal(nodes []*model.ScNodeAvailInfo) ([]*model.ScNodeAvailInfo, error)
NodeDiskTotal 查询磁盘总空间
func NodeMemoryAvail ¶
func NodeMemoryAvail(nodes []*model.ScNodeAvailInfo) ([]*model.ScNodeAvailInfo, error)
NodeMemoryAvail 查询内存可用大小
func NodeMemoryTotal ¶
func NodeMemoryTotal(nodes []*model.ScNodeAvailInfo) ([]*model.ScNodeAvailInfo, error)
NodeMemoryTotal 查询内存总大小
func NodesDynamicInfo ¶
func NodesDynamicInfo(svc *svc.ServiceContext) ([]*model.ScNodeAvailInfo, error)
func NodesStaticInfo ¶
func NodesStaticInfo() ([]*model.ScNodePhyInfo, error)
NodesStaticInfo 同步节点静态信息
Types ¶
type ComputeResource ¶
type Queues ¶
type Queues struct { NodeNums string `json:"nodeNums,omitempty"` ResourceId string `json:"resourceId,omitempty"` Memory string `json:"memory,omitempty"` AccountName string `json:"accountName,omitempty"` ResourceName string `json:"resourceName,omitempty"` ClusterId string `json:"clusterId,omitempty"` VALUE string `json:"VALUE,omitempty"` Type string `json:"type,omitempty"` Processor string `json:"processor,omitempty"` Network string `json:"network,omitempty"` AccountId string `json:"accountId,omitempty"` ITEM string `json:"ITEM,omitempty"` SPECIFICATIONS string `json:"SPECIFICATIONS,omitempty"` QueueName string `json:"queueName,omitempty"` CreateTime string `json:"createTime,omitempty"` StartTime string `json:"startTime,omitempty"` EndTime string `json:"endTime,omitempty"` }
Click to show internal directories.
Click to hide internal directories.