identifier

package
v3.1.1+incompatible Latest Latest
Warning

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

Go to latest
Published: Nov 7, 2018 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HostIdentifier

type HostIdentifier struct {
	HostID          int64              `json:"bk_host_id" bson:"bk_host_id"`
	HostName        string             `json:"bk_host_name" bson:"bk_host_name"`
	SupplierID      int64              `json:"bk_supplier_id"`
	SupplierAccount string             `json:"bk_supplier_account"`
	CloudID         int64              `json:"bk_cloud_id" bson:"bk_cloud_id"`
	CloudName       string             `json:"bk_cloud_name" bson:"bk_cloud_name"`
	InnerIP         string             `json:"bk_host_innerip" bson:"bk_host_innerip"`
	OuterIP         string             `json:"bk_host_outerip" bson:"bk_host_outerip"`
	OSType          string             `json:"bk_os_type" bson:"bk_os_type"`
	OSName          string             `json:"bk_os_name" bson:"bk_os_name"`
	Memory          int64              `json:"bk_mem" bson:"bk_mem"`
	CPU             int64              `json:"bk_cpu" bson:"bk_cpu"`
	Disk            int64              `json:"bk_disk" bson:"bk_disk"`
	Module          map[string]*Module `json:"associations" bson:"associations"`
	Process         []Process          `json:"process" bson:"process"`
}

func NewHostIdentifier

func NewHostIdentifier(m map[string]interface{}) *HostIdentifier

func (*HostIdentifier) MarshalBinary

func (iden *HostIdentifier) MarshalBinary() (data []byte, err error)

type IdentifierHandler

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

func NewIdentifierHandler

func NewIdentifierHandler(cache *redis.Client, db storage.DI) *IdentifierHandler

func (*IdentifierHandler) StartHandleInsts

func (ih *IdentifierHandler) StartHandleInsts() error

type Inst

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

type Module

type Module struct {
	BizID      int64  `json:"bk_biz_id"`
	BizName    string `json:"bk_biz_name"`
	SetID      int64  `json:"bk_set_id"`
	SetName    string `json:"bk_set_name"`
	ModuleID   int64  `json:"bk_module_id"`
	ModuleName string `json:"bk_module_name"`
	SetStatus  string `json:"bk_service_status"`
	SetEnv     string `json:"bk_set_env"`
}

func NewModule

func NewModule(m map[string]interface{}) *Module

type PorcessSorter

type PorcessSorter []Process

func (PorcessSorter) Len

func (p PorcessSorter) Len() int

func (PorcessSorter) Less

func (p PorcessSorter) Less(i, j int) bool

func (PorcessSorter) Swap

func (p PorcessSorter) Swap(i, j int)

type Process

type Process struct {
	ProcessID       int64   `json:"bk_process_id" bson:"bk_process_id"`               // 进程名称
	ProcessName     string  `json:"bk_process_name" bson:"bk_process_name"`           // 进程名称
	BindIP          string  `json:"bind_ip" bson:"bind_ip"`                           // 绑定IP, 枚举: [{ID: "1", Name: "127.0.0.1"}, {ID: "2", Name: "0.0.0.0"}, {ID: "3", Name: "第一内网IP"}, {ID: "4", Name: "第一外网IP"}]
	PORT            string  `json:"port" bson:"port"`                                 // 端口, 单个端口:"8080", 多个连续端口:"8080-8089", 多个不连续端口:"8080-8089,8199"
	PROTOCOL        string  `json:"protocol" bson:"protocol"`                         // 协议, 枚举: [{ID: "1", Name: "TCP"}, {ID: "2", Name: "UDP"}],
	FuncID          string  `json:"bk_func_id" bson:"bk_func_id"`                     // 功能ID
	FuncName        string  `json:"bk_func_name" bson:"bk_func_name"`                 // 功能名称
	StartParamRegex string  `json:"bk_start_param_regex" bson:"bk_start_param_regex"` // 启动参数匹配规则
	BindModules     []int64 `json:"bind_modules" bson:"bind_modules"`                 // 进程绑定的模块ID,数字数组
}

Jump to

Keyboard shortcuts

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