mysql

package
v0.0.0-...-b8a1a0e Latest Latest
Warning

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

Go to latest
Published: Jan 31, 2024 License: Apache-2.0 Imports: 16 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Db *gorm.DB
View Source
var DbConfig MySqlConfig

Functions

func GetConnectionWithDatabase

func GetConnectionWithDatabase(cfg MySqlConfig) *gorm.DB

func GetConnectionWithoutDatabase

func GetConnectionWithoutDatabase(cfg MySqlConfig) *gorm.DB

func GetDSN

func GetDSN(cfg MySqlConfig, database string, timeout uint32, multiStatements bool) string

func GetGormDB

func GetGormDB(dsn string) *gorm.DB

func GetResultSetMax

func GetResultSetMax() int

func Gorm

func Gorm(cfg MySqlConfig) *gorm.DB

func InitMySQL

func InitMySQL(cfg MySqlConfig) error

Types

type ACL

type ACL struct {
	ID           int       `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	BusinessID   int       `gorm:"column:business_id;type:int;not null" json:"BUSINESS_ID"`
	Name         string    `gorm:"column:name;type:char(64);default:null" json:"NAME"`
	Type         int       `gorm:"column:type;type:int;default:null;default:2" json:"TYPE"`         // 1-epc; 2-custom
	TapType      int       `gorm:"column:tap_type;type:int;default:null;default:3" json:"TAP_TYPE"` // 1-WAN; 3-LAN
	State        int       `gorm:"column:state;type:int;default:null;default:1" json:"STATE"`       // 0-disable; 1-enable
	Applications string    `gorm:"column:applications;type:char(64);not null" json:"APPLICATIONS"`  // separated by , (1-performance analysis; 2-backpacking; 6-npb)
	EpcID        int       `gorm:"column:epc_id;type:int;default:null" json:"EPC_ID"`
	SrcGroupIDs  string    `gorm:"column:src_group_ids;type:text;default:null" json:"SRC_GROUP_IDS"` // separated by ,
	DstGroupIDs  string    `gorm:"column:dst_group_ids;type:text;default:null" json:"DST_GROUP_IDS"` // separated by ,
	Protocol     *int      `gorm:"column:protocol;type:int;default:null" json:"PROTOCOL"`
	SrcPorts     string    `gorm:"column:src_ports;type:text;default:null" json:"SRC_PORTS"` // separated by ,
	DstPorts     string    `gorm:"column:dst_ports;type:text;default:null" json:"DST_PORTS"` // separated by ,
	Vlan         int       `gorm:"column:vlan;type:int;default:null" json:"VLAN"`
	CreatedAt    time.Time `gorm:"column:created_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"CREATED_AT"`
	UpdatedAt    time.Time `gorm:"column:updated_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"UPDATED_AT"`
	Lcuuid       string    `gorm:"column:lcuuid;type:char(64);default:null" json:"LCUUID"`
}

func (ACL) TableName

func (ACL) TableName() string

type AZ

type AZ struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string `gorm:"column:name;type:varchar(64);default:''" json:"NAME" mapstructure:"NAME"`
	CreateMethod   int    `gorm:"column:create_method;type:int;default:0" json:"CREATE_METHOD" mapstructure:"CREATE_METHOD"` // 0.learning 1.user_defined
	Label          string `gorm:"column:label;type:varchar(64);default:''" json:"LABEL" mapstructure:"LABEL"`
	Region         string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	Domain         string `gorm:"column:domain;type:char(64);default:''" json:"DOMAIN" mapstructure:"DOMAIN"`
}

func (AZ) TableName

func (AZ) TableName() string

type AZAnalyzerConnection

type AZAnalyzerConnection struct {
	ID         int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	AZ         string `gorm:"column:az;type:char(64);default:ALL" json:"AZ"`
	Region     string `gorm:"column:region;type:char(64);default:ffffffff-ffff-ffff-ffff-ffffffffffff" json:"REGION"`
	AnalyzerIP string `gorm:"column:analyzer_ip;type:char(64);default:null" json:"ANALYZER_IP"`
	Lcuuid     string `gorm:"column:lcuuid;type:char(64);not null" json:"LCUUID"`
}

func (AZAnalyzerConnection) TableName

func (AZAnalyzerConnection) TableName() string

type AZControllerConnection

type AZControllerConnection struct {
	ID           int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	AZ           string `gorm:"column:az;type:char(64);default:ALL" json:"AZ"`
	Region       string `gorm:"column:region;type:char(64);default:ffffffff-ffff-ffff-ffff-ffffffffffff" json:"REGION"`
	ControllerIP string `gorm:"column:controller_ip;type:char(64);default:null" json:"CONTROLLER_IP"`
	Lcuuid       string `gorm:"column:lcuuid;type:char(64);not null" json:"LCUUID"`
}

func (AZControllerConnection) TableName

func (AZControllerConnection) TableName() string

type Analyzer

type Analyzer struct {
	ID                int       `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	State             int       `gorm:"column:state;type:int;default:null" json:"STATE"`    // 0.Temp 1.Creating 2.Complete 3.Modifying 4.Exception
	HaState           int       `gorm:"column:ha_state;type:int;default:1" json:"HA_STATE"` // 1.master 2.backup
	Name              string    `gorm:"column:name;type:char(64);default:null" json:"NAME"`
	Description       string    `gorm:"column:description;type:varchar(256);default:null" json:"DESCRIPTION"`
	IP                string    `gorm:"column:ip;type:char(64);default:null" json:"IP"`
	NATIP             string    `gorm:"column:nat_ip;type:char(64);default:null" json:"NAT_IP"`
	Agg               int       `gorm:"column:agg;type:int;default:1" json:"AGG"`
	CPUNum            int       `gorm:"column:cpu_num;type:int;default:0" json:"CPU_NUM"` // logical number of cpu
	MemorySize        int64     `gorm:"column:memory_size;type:bigint;default:0" json:"MEMORY_SIZE"`
	Arch              string    `gorm:"column:arch;type:varchar(256);default:null" json:"ARCH"`
	Os                string    `gorm:"column:os;type:varchar(256);default:null" json:"OS"`
	KernelVersion     string    `gorm:"column:kernel_version;type:varchar(256);default:null" json:"KERNEL_VERSION"`
	PcapDataMountPath string    `gorm:"column:pcap_data_mount_path;type:varchar(256);default:null" json:"PCAP_DATA_MOUNT_PATH"`
	VTapMax           int       `gorm:"column:vtap_max;type:int;default:200" json:"VTAP_MAX"`
	SyncedAt          time.Time `gorm:"column:synced_at;type:datetime;not null;default:CURRENT_TIMESTAMP" json:"SYNCED_AT"`
	NATIPEnabled      int       `gorm:"column:nat_ip_enabled;default:0" json:"NAT_IP_ENABLED"` // 0: disabled 1:enabled
	PodIP             string    `gorm:"column:pod_ip;type:char(64);default:null" json:"POD_IP"`
	PodName           string    `gorm:"column:pod_name;type:char(64);default:null" json:"pod_name"`
	CAMD5             string    `gorm:"column:ca_md5;type:char(64);default:null" json:"CA_MD5"`
	Lcuuid            string    `gorm:"column:lcuuid;type:char(64);not null" json:"LCUUID"`
}

type Base

type Base struct {
	ID     int    `gorm:"primaryKey;autoIncrement;unique;column:id;type:int;not null" json:"ID" mapstructure:"ID"`
	Lcuuid string `gorm:"unique;column:lcuuid;type:char(64)" json:"LCUUID" mapstructure:"LCUUID"`
}

func (Base) GetID

func (b Base) GetID() int

func (Base) GetLcuuid

func (b Base) GetLcuuid() string

func (*Base) SetID

func (b *Base) SetID(id int)

type Business

type Business struct {
	ID          int       `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name        string    `gorm:"column:name;type:char(64);default:null" json:"NAME"`
	Description string    `gorm:"column:description;type:varchar(256);default:null" json:"DESCRIPTION"`
	Type        int       `gorm:"column:type;type:int;default:1" json:"TYPE"`        // 1-data center; 2-ip; 3-vpc; 4-WAN; 5-NPB; 6-diagnose; 21-tmp ip; 31-tmp vpc
	VPCID       int       `gorm:"column:epc_id;type:int;default:null" json:"VPC_ID"` // for vpc type
	NetworkID   int       `gorm:"column:vl2_id;type:int;default:null" json:"VL2_ID"` // for ip type
	State       int       `gorm:"column:state;type:int;default:1" json:"STATE"`      // 0-disable; 1-enable
	CreatedAt   time.Time `gorm:"column:created_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"CREATED_AT"`
	UpdatedAt   time.Time `gorm:"column:updated_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"UPDATED_AT"`
	Lcuuid      string    `gorm:"column:lcuuid;type:char(64);not null" json:"LCUUID"`
}

type CEN

type CEN struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Label          string `gorm:"column:label;type:char(64);default:''" json:"LABEL" mapstructure:"LABEL"`
	Alias          string `gorm:"column:alias;type:char(64);default:''" json:"ALIAS" mapstructure:"ALIAS"`
	VPCIDs         string `gorm:"column:epc_ids;type:text;default:''" json:"EPC_IDS" mapstructure:"EPC_IDS"` // separated by ,
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
}

func (CEN) TableName

func (CEN) TableName() string

type ChAPPLabel

type ChAPPLabel struct {
	LabelNameID  int    `gorm:"primaryKey;column:label_name_id;type:int;not null" json:"LABEL_NAME_ID"`
	LabelValueID int    `gorm:"primaryKey;column:label_value_id;type:int unsigned;not null" json:"LABEL_VALUE_ID"`
	LabelValue   string `gorm:"column:label_value;type:text;not null" json:"LABEL_VALUE"`
}

func (ChAPPLabel) TableName

func (ChAPPLabel) TableName() string

type ChAZ

type ChAZ struct {
	ID     int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name   string `gorm:"column:name;type:varchar(64);default:null" json:"NAME"`
	IconID int    `gorm:"column:icon_id;type:int;default:null" json:"ICON_ID"`
}

type ChChost

type ChChost struct {
	ID      int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name    string `gorm:"column:name;type:varchar(256)" json:"NAME"`
	L3EPCID int    `gorm:"column:l3_epc_id;type:int" json:"L3_EPC_ID"`
	HostID  int    `gorm:"column:host_id;type:int" json:"HOST_ID"`
}

type ChChostCloudTag

type ChChostCloudTag struct {
	ID    int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Key   string `gorm:"primaryKey;column:key;type:varchar(256);default:null" json:"KEY"`
	Value string `gorm:"column:value;type:varchar(256);default:null" json:"VALUE"`
}

type ChChostCloudTags

type ChChostCloudTags struct {
	ID        int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	CloudTags string `gorm:"column:cloud_tags;type:text;default:null" json:"CLOUD_TAGS"`
}

type ChDevice

type ChDevice struct {
	DeviceType int    `gorm:"primaryKey;column:devicetype;type:int;not null" json:"DEVICETYPE"`
	DeviceID   int    `gorm:"primaryKey;column:deviceid;type:int;not null" json:"DEVICEID"`
	Name       string `gorm:"column:name;type:text;default:null" json:"NAME"`
	IconID     int    `gorm:"column:icon_id;type:int;default:null" json:"ICON_ID"`
	UID        string `gorm:"column:uid;type:char(64);default:null" json:"UID"`
}

type ChDevicePort

type ChDevicePort struct {
	DeviceType         int    `gorm:"primaryKey;column:devicetype;type:int;not null" json:"DEVICETYPE"`
	DeviceID           int    `gorm:"primaryKey;column:deviceid;type:int;not null" json:"DEVICEID"`
	Protocol           int    `gorm:"primaryKey;column:protocol;type:int;not null" json:"PROTOCOL"`
	Port               int    `gorm:"primaryKey;column:port;type:int;not null" json:"PORT"`
	PortLBID           int    `gorm:"column:port_lb_id;type:int;default:null" json:"PORT_LB_ID"`
	PortLBName         string `gorm:"column:port_lb_name;type:varchar(256);default:null" json:"PORT_LB_NAME"`
	PortLBListenerID   int    `gorm:"column:port_lb_listener_id;type:int;default:null" json:"PORT_LB_LISTENER_ID"`
	PortLBListenerName string `gorm:"column:port_lb_listener_name;type:varchar(256);default:null" json:"PORT_LB_LISTENER_NAME"`
	PortPodServiceID   int    `gorm:"column:port_pod_service_id;type:int;default:null" json:"PORT_POD_SERVICE_ID"`
	PortPodServiceName string `gorm:"column:port_pod_service_name;type:varchar(256);default:null" json:"PORT_POD_SERVICE_NAME"`
}

type ChGProcess

type ChGProcess struct {
	ID      int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name    string `gorm:"column:name;type:text;default:null" json:"NAME"`
	IconID  int    `gorm:"column:icon_id;type:int;default:null" json:"ICON_ID"`
	CHostID int    `gorm:"column:chost_id;type:int;not null" json:"CHOST_ID"`
	L3EPCID int    `gorm:"column:l3_epc_id;type:int" json:"L3_EPC_ID"`
}

func (ChGProcess) TableName

func (ChGProcess) TableName() string

type ChIPPort

type ChIPPort struct {
	IP                 string `gorm:"primaryKey;column:ip;type:varchar(64);not null" json:"IP"`
	SubnetID           int    `gorm:"primaryKey;column:subnet_id;type:int;not null" json:"SUBNET_ID"`
	Protocol           int    `gorm:"primaryKey;column:protocol;type:int;not null" json:"PROTOCOL"`
	Port               int    `gorm:"primaryKey;column:port;type:int;not null" json:"PORT"`
	PortLBID           int    `gorm:"column:port_lb_id;type:int;default:null" json:"PORT_LB_ID"`
	PortLBName         string `gorm:"column:port_lb_name;type:varchar(256);default:null" json:"PORT_LB_NAME"`
	PortLBListenerID   int    `gorm:"column:port_lb_listener_id;type:int;default:null" json:"PORT_LB_LISTENER_ID"`
	PortLBListenerName string `gorm:"column:port_lb_listener_name;type:varchar(256);default:null" json:"PORT_LB_LISTENER_NAME"`
	PortPodServiceID   int    `gorm:"column:port_pod_service_id;type:int;default:null" json:"PORT_POD_SERVICE_ID"`
	PortPodServiceName string `gorm:"column:port_pod_service_name;type:varchar(256);default:null" json:"PORT_POD_SERVICE_NAME"`
}

type ChIPRelation

type ChIPRelation struct {
	L3EPCID        int    `gorm:"primaryKey;column:l3_epc_id;type:int;not null" json:"L3_EPC_ID"`
	IP             string `gorm:"primaryKey;column:ip;type:varchar(64);not null" json:"IP"`
	NATGWID        int    `gorm:"column:natgw_id;type:int;default:null" json:"NATGW_ID"`
	NATGWName      string `gorm:"column:natgw_name;type:varchar(256);default:null" json:"NATGW_NAME"`
	LBID           int    `gorm:"column:lb_id;type:int;default:null" json:"LB_ID"`
	LBName         string `gorm:"column:lb_name;type:varchar(256);default:null" json:"LB_NAME"`
	LBListenerID   int    `gorm:"column:lb_listener_id;type:int;default:null" json:"LB_LISTENER_ID"`
	LBListenerName string `gorm:"column:lb_listener_name;type:varchar(256);default:null" json:"LB_LISTENER_NAME"`
	PodIngressID   int    `gorm:"column:pod_ingress_id;type:int;default:null" json:"POD_INGRESS_ID"`
	PodIngressName string `gorm:"column:pod_ingress_name;type:varchar(256);default:null" json:"POD_INGRESS_NAME"`
	PodServiceID   int    `gorm:"column:pod_service_id;type:int;default:null" json:"POD_SERVICE_ID"`
	PodServiceName string `gorm:"column:pod_service_name;type:varchar(256);default:null" json:"POD_SERVICE_NAME"`
}

func (ChIPRelation) TableName

func (ChIPRelation) TableName() string

type ChIPResource

type ChIPResource struct {
	IP             string `gorm:"primaryKey;column:ip;type:varchar(64);not null" json:"IP"`
	SubnetID       int    `gorm:"primaryKey;column:subnet_id;type:int;not null" json:"SUBNET_ID"`
	SubnetName     string `gorm:"column:subnet_name;type:varchar(256);default:null" json:"SUBNET_NAME"`
	RegionID       int    `gorm:"column:region_id;type:int;not null" json:"REGION_ID"`
	RegionName     string `gorm:"column:region_name;type:varchar(256);default:null" json:"REGION_NAME"`
	AZID           int    `gorm:"column:az_id;type:int;not null" json:"AZ_ID"`
	AZName         string `gorm:"column:az_name;type:varchar(256);default:null" json:"AZ_NAME"`
	HostID         int    `gorm:"column:host_id;type:int;not null" json:"HOST_ID"`
	HostName       string `gorm:"column:host_name;type:varchar(256);default:null" json:"HOST_NAME"`
	CHostID        int    `gorm:"column:chost_id;type:int;not null" json:"CHOST_ID"`
	CHostName      string `gorm:"column:chost_name;type:varchar(256);default:null" json:"CHOST_NAME"`
	L3EPCID        int    `gorm:"column:l3_epc_id;type:int;not null" json:"L3_EPC_ID"`
	L3EPCName      string `gorm:"column:l3_epc_name;type:varchar(256);default:null" json:"L3_EPC_NAME"`
	RouterID       int    `gorm:"column:router_id;type:int;not null" json:"ROUTER_ID"`
	RouterName     string `gorm:"column:router_name;type:varchar(256);default:null" json:"ROUTER_NAME"`
	DHCPGWID       int    `gorm:"column:dhcpgw_id;type:int;not null" json:"DHCPGW_ID"`
	DHCPGWName     string `gorm:"column:dhcpgw_name;type:varchar(256);default:null" json:"DHCPGW_NAME"`
	LBID           int    `gorm:"column:lb_id;type:int;default:null" json:"LB_ID"`
	LBName         string `gorm:"column:lb_name;type:varchar(256);default:null" json:"LB_NAME"`
	LBListenerID   int    `gorm:"column:lb_listener_id;type:int;default:null" json:"LB_LISTENER_ID"`
	LBListenerName string `gorm:"column:lb_listener_name;type:varchar(256);default:null" json:"LB_LISTENER_NAME"`
	NATGWID        int    `gorm:"column:natgw_id;type:int;default:null" json:"NATGW_ID"`
	NATGWName      string `gorm:"column:natgw_name;type:varchar(256);default:null" json:"NATGW_NAME"`
	RedisID        int    `gorm:"column:redis_id;type:int;not null" json:"REDIS_ID"`
	RedisName      string `gorm:"column:redis_name;type:varchar(256);default:null" json:"REDIS_NAME"`
	RDSID          int    `gorm:"column:rds_id;type:int;not null" json:"RDS_ID"`
	RDSName        string `gorm:"column:rds_name;type:varchar(256);default:null" json:"RDS_NAME"`
	PodClusterID   int    `gorm:"column:pod_cluster_id;type:int;not null" json:"POD_CLUSTER_ID"`
	PodClusterName string `gorm:"column:pod_cluster_name;type:varchar(256);default:null" json:"POD_CLUSTER_NAME"`
	PodNSID        int    `gorm:"column:pod_ns_id;type:int;not null" json:"POD_NS_ID"`
	PodNSName      string `gorm:"column:pod_ns_name;type:varchar(256);default:null" json:"POD_NS_NAME"`
	PodNodeID      int    `gorm:"column:pod_node_id;type:int;not null" json:"POD_NODE_ID"`
	PodNodeName    string `gorm:"column:pod_node_name;type:varchar(256);default:null" json:"POD_NODE_NAME"`
	PodIngressID   int    `gorm:"column:pod_ingress_id;type:int;default:null" json:"POD_INGRESS_ID"`
	PodIngressName string `gorm:"column:pod_ingress_name;type:varchar(256);default:null" json:"POD_INGRESS_NAME"`
	PodServiceID   int    `gorm:"column:pod_service_id;type:int;default:null" json:"POD_SERVICE_ID"`
	PodServiceName string `gorm:"column:pod_service_name;type:varchar(256);default:null" json:"POD_SERVICE_NAME"`
	PodGroupID     int    `gorm:"column:pod_group_id;type:int;default:null" json:"POD_GROUP_ID"`
	PodGroupName   string `gorm:"column:pod_group_name;type:varchar(256);default:null" json:"POD_GROUP_NAME"`
	PodID          int    `gorm:"column:pod_id;type:int;default:null" json:"POD_ID"`
	PodName        string `gorm:"column:pod_name;type:varchar(256);default:null" json:"POD_NAME"`
	UID            string `gorm:"column:uid;type:char(64);default:null" json:"UID"`
}

func (ChIPResource) TableName

func (ChIPResource) TableName() string

type ChIntEnum

type ChIntEnum struct {
	TagName     string `gorm:"primaryKey;column:tag_name;type:varchar(256);default:null" json:"TAG_NAME"`
	Value       int    `gorm:"primaryKey;column:value;type:int;default:0" json:"VALUE"`
	Name        string `gorm:"column:name;type:varchar(256);default:null" json:"NAME"`
	Description string `gorm:"column:description;type:varchar(256);default:null" json:"DESCRIPTION"`
}

type ChLBListener

type ChLBListener struct {
	ID   int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name string `gorm:"column:name;type:varchar(256);not null" json:"NAME"`
}

func (ChLBListener) TableName

func (ChLBListener) TableName() string

type ChNetwork

type ChNetwork struct {
	ID     int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name   string `gorm:"column:name;type:varchar(256);not null" json:"NAME"`
	IconID int    `gorm:"column:icon_id;type:int;default:null" json:"ICON_ID"`
}

func (ChNetwork) TableName

func (ChNetwork) TableName() string

type ChNodeType

type ChNodeType struct {
	ResourceType int    `gorm:"primaryKey;column:resource_type;type:int;not null" json:"RESOURCE_TYPE"`
	NodeType     string `gorm:"column:node_type;type:varchar(256);default:null" json:"NODE_TYPE"`
}

type ChOSAppTag

type ChOSAppTag struct {
	PID   int    `gorm:"primaryKey;column:pid;type:int;not null" json:"PID"`
	Key   string `gorm:"primaryKey;column:key;type:varchar(256);default:null" json:"KEY"`
	Value string `gorm:"column:value;type:varchar(256);default:null" json:"VALUE"`
}

func (ChOSAppTag) TableName

func (ChOSAppTag) TableName() string

type ChOSAppTags

type ChOSAppTags struct {
	PID       int    `gorm:"primaryKey;column:pid;type:int;not null" json:"PID"`
	OSAPPTags string `gorm:"column:os_app_tags;type:text;default:null" json:"OS_APP_TAGS"`
}

func (ChOSAppTags) TableName

func (ChOSAppTags) TableName() string

type ChPod

type ChPod struct {
	ID           int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name         string `gorm:"column:name;type:varchar(256);not null" json:"NAME"`
	IconID       int    `gorm:"column:icon_id;type:int;default:null" json:"ICON_ID"`
	PodClusterID int    `gorm:"column:pod_cluster_id;type:int;not null" json:"POD_CLUSTER_ID"`
	PodNsID      int    `gorm:"column:pod_ns_id;type:int;not null" json:"POD_NS_ID"`
	PodNodeID    int    `gorm:"column:pod_node_id;type:int;not null" json:"POD_NODE_ID"`
	PodServiceID int    `gorm:"column:pod_service_id;type:int;default:null" json:"POD_SERVICE_ID"`
	PodGroupID   int    `gorm:"column:pod_group_id;type:int;default:null" json:"POD_GROUP_ID"`
}

type ChPodCluster

type ChPodCluster struct {
	ID     int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name   string `gorm:"column:name;type:varchar(64);default:null" json:"NAME"`
	IconID int    `gorm:"column:icon_id;type:int;default:null" json:"ICON_ID"`
}

type ChPodGroup

type ChPodGroup struct {
	ID           int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name         string `gorm:"column:name;type:varchar(256);not null" json:"NAME"`
	PodGroupType int    `gorm:"column:pod_group_type;type:int;default:null" json:"POD_GROUP_TYPE"`
	IconID       int    `gorm:"column:icon_id;type:int;default:null" json:"ICON_ID"`
	PodClusterID int    `gorm:"column:pod_cluster_id;type:int;not null" json:"POD_CLUSTER_ID"`
	PodNsID      int    `gorm:"column:pod_ns_id;type:int;not null" json:"POD_NS_ID"`
}

type ChPodGroupPort

type ChPodGroupPort struct {
	ID                 int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Protocol           int    `gorm:"primaryKey;column:protocol;type:int;not null" json:"PROTOCOL"`
	Port               int    `gorm:"primaryKey;column:port;type:int;not null" json:"PORT"`
	PortLBID           int    `gorm:"column:port_lb_id;type:int;default:null" json:"PORT_LB_ID"`
	PortLBName         string `gorm:"column:port_lb_name;type:varchar(256);default:null" json:"PORT_LB_NAME"`
	PortLBListenerID   int    `gorm:"column:port_lb_listener_id;type:int;default:null" json:"PORT_LB_LISTENER_ID"`
	PortLBListenerName string `gorm:"column:port_lb_listener_name;type:varchar(256);default:null" json:"PORT_LB_LISTENER_NAME"`
	PortPodServiceID   int    `gorm:"column:port_pod_service_id;type:int;default:null" json:"PORT_POD_SERVICE_ID"`
	PortPodServiceName string `gorm:"column:port_pod_service_name;type:varchar(256);default:null" json:"PORT_POD_SERVICE_NAME"`
}

type ChPodIngress

type ChPodIngress struct {
	ID   int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name string `gorm:"column:name;type:varchar(256);not null" json:"NAME"`
}

type ChPodK8sAnnotation

type ChPodK8sAnnotation struct {
	ID      int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Key     string `gorm:"primaryKey;column:key;type:varchar(256);default:null" json:"KEY"`
	Value   string `gorm:"column:value;type:varchar(256);default:null" json:"VALUE"`
	L3EPCID int    `gorm:"column:l3_epc_id;type:int;not null" json:"L3_EPC_ID"`
	PodNsID int    `gorm:"column:pod_ns_id;type:int;not null" json:"POD_NS_ID"`
}

type ChPodK8sAnnotations

type ChPodK8sAnnotations struct {
	ID          int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Annotations string `gorm:"column:annotations;type:text;default:null" json:"ANNOTATIONS"`
	L3EPCID     int    `gorm:"column:l3_epc_id;type:int;not null" json:"L3_EPC_ID"`
	PodNsID     int    `gorm:"column:pod_ns_id;type:int;not null" json:"POD_NS_ID"`
}

type ChPodK8sEnv

type ChPodK8sEnv struct {
	ID      int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Key     string `gorm:"primaryKey;column:key;type:varchar(256);default:null" json:"KEY"`
	Value   string `gorm:"column:value;type:varchar(256);default:null" json:"VALUE"`
	L3EPCID int    `gorm:"column:l3_epc_id;type:int;not null" json:"L3_EPC_ID"`
	PodNsID int    `gorm:"column:pod_ns_id;type:int;not null" json:"POD_NS_ID"`
}

type ChPodK8sEnvs

type ChPodK8sEnvs struct {
	ID      int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Envs    string `gorm:"column:envs;type:text;default:null" json:"ENVS"`
	L3EPCID int    `gorm:"column:l3_epc_id;type:int;not null" json:"L3_EPC_ID"`
	PodNsID int    `gorm:"column:pod_ns_id;type:int;not null" json:"POD_NS_ID"`
}

type ChPodK8sLabel

type ChPodK8sLabel struct {
	ID      int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Key     string `gorm:"primaryKey;column:key;type:varchar(256);default:null" json:"KEY"`
	Value   string `gorm:"column:value;type:varchar(256);default:null" json:"VALUE"`
	L3EPCID int    `gorm:"column:l3_epc_id;type:int;not null" json:"L3_EPC_ID"`
	PodNsID int    `gorm:"column:pod_ns_id;type:int;not null" json:"POD_NS_ID"`
}

type ChPodK8sLabels

type ChPodK8sLabels struct {
	ID      int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Labels  string `gorm:"column:labels;type:text;default:null" json:"LABELS"`
	L3EPCID int    `gorm:"column:l3_epc_id;type:int;not null" json:"L3_EPC_ID"`
	PodNsID int    `gorm:"column:pod_ns_id;type:int;not null" json:"POD_NS_ID"`
}

type ChPodNSCloudTag

type ChPodNSCloudTag struct {
	ID    int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Key   string `gorm:"primaryKey;column:key;type:varchar(256);default:null" json:"KEY"`
	Value string `gorm:"column:value;type:varchar(256);default:null" json:"VALUE"`
}

func (ChPodNSCloudTag) TableName

func (ChPodNSCloudTag) TableName() string

type ChPodNSCloudTags

type ChPodNSCloudTags struct {
	ID        int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	CloudTags string `gorm:"column:cloud_tags;type:text;default:null" json:"CLOUD_TAGS"`
}

func (ChPodNSCloudTags) TableName

func (ChPodNSCloudTags) TableName() string

type ChPodNamespace

type ChPodNamespace struct {
	ID           int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name         string `gorm:"column:name;type:varchar(256);not null" json:"NAME"`
	IconID       int    `gorm:"column:icon_id;type:int;default:null" json:"ICON_ID"`
	PodClusterID int    `gorm:"column:pod_cluster_id;type:int;not null" json:"POD_CLUSTER_ID"`
}

func (ChPodNamespace) TableName

func (ChPodNamespace) TableName() string

type ChPodNode

type ChPodNode struct {
	ID     int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name   string `gorm:"column:name;type:varchar(256);not null" json:"NAME"`
	IconID int    `gorm:"column:icon_id;type:int;default:null" json:"ICON_ID"`
}

type ChPodNodePort

type ChPodNodePort struct {
	ID                 int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Protocol           int    `gorm:"primaryKey;column:protocol;type:int;not null" json:"PROTOCOL"`
	Port               int    `gorm:"primaryKey;column:port;type:int;not null" json:"PORT"`
	PortLBID           int    `gorm:"column:port_lb_id;type:int;default:null" json:"PORT_LB_ID"`
	PortLBName         string `gorm:"column:port_lb_name;type:varchar(256);default:null" json:"PORT_LB_NAME"`
	PortLBListenerID   int    `gorm:"column:port_lb_listener_id;type:int;default:null" json:"PORT_LB_LISTENER_ID"`
	PortLBListenerName string `gorm:"column:port_lb_listener_name;type:varchar(256);default:null" json:"PORT_LB_LISTENER_NAME"`
	PortPodServiceID   int    `gorm:"column:port_pod_service_id;type:int;default:null" json:"PORT_POD_SERVICE_ID"`
	PortPodServiceName string `gorm:"column:port_pod_service_name;type:varchar(256);default:null" json:"PORT_POD_SERVICE_NAME"`
}

type ChPodPort

type ChPodPort struct {
	ID                 int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Protocol           int    `gorm:"primaryKey;column:protocol;type:int;not null" json:"PROTOCOL"`
	Port               int    `gorm:"primaryKey;column:port;type:int;not null" json:"PORT"`
	PortLBID           int    `gorm:"column:port_lb_id;type:int;default:null" json:"PORT_LB_ID"`
	PortLBName         string `gorm:"column:port_lb_name;type:varchar(256);default:null" json:"PORT_LB_NAME"`
	PortLBListenerID   int    `gorm:"column:port_lb_listener_id;type:int;default:null" json:"PORT_LB_LISTENER_ID"`
	PortLBListenerName string `gorm:"column:port_lb_listener_name;type:varchar(256);default:null" json:"PORT_LB_LISTENER_NAME"`
	PortPodServiceID   int    `gorm:"column:port_pod_service_id;type:int;default:null" json:"PORT_POD_SERVICE_ID"`
	PortPodServiceName string `gorm:"column:port_pod_service_name;type:varchar(256);default:null" json:"PORT_POD_SERVICE_NAME"`
}

type ChPodService

type ChPodService struct {
	ID           int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name         string `gorm:"column:name;type:varchar(256)" json:"NAME"`
	PodClusterID int    `gorm:"column:pod_cluster_id;type:int" json:"POD_CLUSTER_ID"`
	PodNsID      int    `gorm:"column:pod_ns_id;type:int" json:"POD_NS_ID"`
}

type ChPodServiceK8sAnnotation

type ChPodServiceK8sAnnotation struct {
	ID      int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Key     string `gorm:"primaryKey;column:key;type:varchar(256);default:null" json:"KEY"`
	Value   string `gorm:"column:value;type:varchar(256);default:null" json:"VALUE"`
	L3EPCID int    `gorm:"column:l3_epc_id;type:int;not null" json:"L3_EPC_ID"`
	PodNsID int    `gorm:"column:pod_ns_id;type:int;not null" json:"POD_NS_ID"`
}

type ChPodServiceK8sAnnotations

type ChPodServiceK8sAnnotations struct {
	ID          int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Annotations string `gorm:"column:annotations;type:text;default:null" json:"ANNOTATIONS"`
	L3EPCID     int    `gorm:"column:l3_epc_id;type:int;not null" json:"L3_EPC_ID"`
	PodNsID     int    `gorm:"column:pod_ns_id;type:int;not null" json:"POD_NS_ID"`
}

type ChPodServiceK8sLabel

type ChPodServiceK8sLabel struct {
	ID      int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Key     string `gorm:"primaryKey;column:key;type:varchar(256);default:null" json:"KEY"`
	Value   string `gorm:"column:value;type:varchar(256);default:null" json:"VALUE"`
	L3EPCID int    `gorm:"column:l3_epc_id;type:int;not null" json:"L3_EPC_ID"`
	PodNsID int    `gorm:"column:pod_ns_id;type:int;not null" json:"POD_NS_ID"`
}

type ChPodServiceK8sLabels

type ChPodServiceK8sLabels struct {
	ID      int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Labels  string `gorm:"column:labels;type:text;default:null" json:"LABELS"`
	L3EPCID int    `gorm:"column:l3_epc_id;type:int;not null" json:"L3_EPC_ID"`
	PodNsID int    `gorm:"column:pod_ns_id;type:int;not null" json:"POD_NS_ID"`
}

type ChPrometheusLabelName

type ChPrometheusLabelName struct {
	ID   int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name string `gorm:"column:name;type:varchar(256);not null" json:"NAME"`
}

type ChPrometheusMetricAPPLabelLayout

type ChPrometheusMetricAPPLabelLayout struct {
	ID                  int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	MetricName          string `gorm:"column:metric_name;type:varchar(256);not null" json:"METRIC_NAME"`
	APPLabelName        string `gorm:"column:app_label_name;type:varchar(256);not null" json:"APP_LABEL_NAME"`
	APPLabelColumnIndex uint8  `gorm:"column:app_label_column_index;type:int unsigned;not null" json:"APP_LABEL_COLUMN_INDEX"`
}

type ChPrometheusMetricName

type ChPrometheusMetricName struct {
	ID   int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name string `gorm:"column:name;type:varchar(256);not null" json:"NAME"`
}

type ChPrometheusTargetLabelLayout

type ChPrometheusTargetLabelLayout struct {
	TargetID          int    `gorm:"primaryKey;column:target_id;type:int;not null" json:"TARGET_ID"`
	TargetLabelNames  string `gorm:"column:target_label_names;type:text;not null" json:"TARGET_LABEL_NAMES"`
	TargetLabelValues string `gorm:"column:target_label_values;type:text;not null" json:"TARGET_LABEL_VALUES"`
}

type ChRegion

type ChRegion struct {
	ID     int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name   string `gorm:"column:name;type:varchar(64);default:null" json:"NAME"`
	IconID int    `gorm:"column:icon_id;type:int;default:null" json:"ICON_ID"`
}

type ChServerPort

type ChServerPort struct {
	ServerPort     int    `gorm:"primaryKey;column:server_port;type:int;not null" json:"SERVER_PORT"`
	ServerPortName string `gorm:"column:server_port_name;type:varchar(256)" json:"SERVER_PORT_NAME"`
}

type ChStringEnum

type ChStringEnum struct {
	TagName     string `gorm:"primaryKey;column:tag_name;type:varchar(256);default:null" json:"TAG_NAME"`
	Value       string `gorm:"primaryKey;column:value;type:varchar(256);default:null" json:"VALUE"`
	Name        string `gorm:"column:name;type:varchar(256);default:null" json:"NAME"`
	Description string `gorm:"column:description;type:varchar(256);default:null" json:"DESCRIPTION"`
}

type ChTapType

type ChTapType struct {
	Value int    `gorm:"primaryKey;column:value;type:int;not null" json:"VALUE"`
	Name  string `gorm:"column:name;type:varchar(64);default:null" json:"NAME"`
}

type ChTargetLabel

type ChTargetLabel struct {
	MetricID    int    `gorm:"primaryKey;column:metric_id;type:int;not null" json:"METRIC_ID"`
	LabelNameID int    `gorm:"primaryKey;column:label_name_id;type:int;not null" json:"LABEL_NAME_ID"`
	TargetID    int    `gorm:"primaryKey;column:target_id;type:int unsigned;not null" json:"TARGET_ID"`
	LabelValue  string `gorm:"column:label_value;type:varchar(256);not null" json:"LABEL_VALUE"`
}

type ChVPC

type ChVPC struct {
	ID     int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name   string `gorm:"column:name;type:varchar(64);default:null" json:"NAME"`
	IconID int    `gorm:"column:icon_id;type:int;default:null" json:"ICON_ID"`
	UID    string `gorm:"column:uid;type:char(64);default:null" json:"UID"`
}

func (ChVPC) TableName

func (ChVPC) TableName() string

type ChVTap

type ChVTap struct {
	ID     int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name   string `gorm:"column:name;type:varchar(256);not null" json:"NAME"`
	Type   int    `gorm:"column:type;type:int;not null" json:"TYPE"`
	IconID int    `gorm:"column:icon_id;type:int;default:null" json:"ICON_ID"`
}

func (ChVTap) TableName

func (ChVTap) TableName() string

type ChVTapPort

type ChVTapPort struct {
	VTapID     int    `gorm:"primaryKey;column:vtap_id;type:int;not null" json:"VTAP_ID"`
	TapPort    int64  `gorm:"primaryKey;column:tap_port;type:bigint;not null" json:"TAP_PORT"`
	MacType    int    `gorm:"column:mac_type;type:int;default:null" json:"MAC_TYPE"`
	HostID     int    `gorm:"column:host_id;type:int;default:null" json:"HOST_ID"`
	Name       string `gorm:"column:name;type:varchar(256);default:null" json:"NAME"`
	HostName   string `gorm:"column:host_name;type:varchar(256);default:null" json:"HOST_NAME"`
	DeviceType int    `gorm:"column:device_type;type:int;not null" json:"DEVICE_TYPE"`
	DeviceID   int    `gorm:"column:device_id;type:int;not null" json:"DEVICE_ID"`
	DeviceName string `gorm:"column:device_name;type:varchar(256);not null" json:"DEVICE_NAME"`
	IconID     int    `gorm:"column:icon_id;type:int;default:null" json:"ICON_ID"`
}

func (ChVTapPort) TableName

func (ChVTapPort) TableName() string

type Contact

type Contact struct {
	Base         `gorm:"embedded" mapstructure:",squash"`
	Name         string    `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	CreateMethod int       `gorm:"column:create_method;type:int;default:0" json:"CREATE_METHOD" mapstructure:"CREATE_METHOD"` // 0.learning 1.user_defined
	Mobile       string    `gorm:"column:mobile;type:char(13);default:''" json:"MOBILE" mapstructure:"MOBILE"`
	Email        string    `gorm:"column:email;type:varchar(128);default:''" json:"EMAIL" mapstructure:"EMAIL"`
	Company      string    `gorm:"column:company;type:varchar(128);default:''" json:"COMPANY" mapstructure:"COMPANY"`
	PushEmail    string    `gorm:"column:push_email;type:text;default:null" json:"PUSH_EMAIL" mapstructure:"PUSH_EMAIL"`
	Domain       string    `gorm:"column:domain;type:char(64);default:''" json:"DOMAIN" mapstructure:"DOMAIN"`
	AlarmPush    int       `gorm:"column:alarm_push;type:int;default:0" json:"ALARM_PUSH" mapstructure:"ALARM_PUSH"`
	ReportPush   int       `gorm:"column:report_push;type:int;default:0" json:"REPORT_PUSH" mapstructure:"REPORT_PUSH"`
	Deleted      int       `gorm:"column:deleted;type:int;default:0" json:"DELETED" mapstructure:"DELETED"`
	CreatedAt    time.Time `gorm:"column:created_at;type:datetime;not null;default:CURRENT_TIMESTAMP" json:"CREATED_AT" mapstructure:"CREATED_AT"`
	UpdatedAt    time.Time `gorm:"column:updated_at;type:datetime;default:null" json:"UPDATED_AT" mapstructure:"UPDATED_AT"`
}

type Controller

type Controller struct {
	ID                 int       `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	State              int       `gorm:"column:state;type:int;default:null" json:"STATE"` // 0.Temp 1.Creating 2.Complete 3.Modifying 4.Exception
	Name               string    `gorm:"column:name;type:char(64);default:null" json:"NAME"`
	Description        string    `gorm:"column:description;type:varchar(256);default:null" json:"DESCRIPTION"`
	IP                 string    `gorm:"column:ip;type:char(64);default:null" json:"IP"`
	NATIP              string    `gorm:"column:nat_ip;type:char(64);default:null" json:"NAT_IP"`
	CPUNum             int       `gorm:"column:cpu_num;type:int;default:0" json:"CPU_NUM"` // logical number of cpu
	MemorySize         int64     `gorm:"column:memory_size;type:bigint;default:0" json:"MEMORY_SIZE"`
	Arch               string    `gorm:"column:arch;type:varchar(256);default:null" json:"ARCH"`
	Os                 string    `gorm:"column:os;type:varchar(256);default:null" json:"OS"`
	KernelVersion      string    `gorm:"column:kernel_version;type:varchar(256);default:null" json:"KERNEL_VERSION"`
	VTapMax            int       `gorm:"column:vtap_max;type:int;default:2000" json:"VTAP_MAX"`
	SyncedAt           time.Time `gorm:"column:synced_at;type:datetime;not null;default:CURRENT_TIMESTAMP" json:"SYNCED_AT"`
	NATIPEnabled       int       `gorm:"column:nat_ip_enabled;default:0" json:"NAT_IP_ENABLED"` // 0: disabled 1:enabled
	NodeType           int       `gorm:"column:node_type;type:int;default:2" json:"NODE_TYPE"`  // region node type 1.master 2.slave
	RegionDomainPrefix string    `gorm:"column:region_domain_prefix;type:varchar(256);default:''" json:"REGION_DOMAIN_PREFIX"`
	NodeName           string    `gorm:"column:node_name;type:char(64);default:null" json:"NODE_NAME"`
	PodIP              string    `gorm:"column:pod_ip;type:char(64);default:null" json:"POD_IP"`
	PodName            string    `gorm:"column:pod_name;type:char(64);default:null" json:"POD_NAME"`
	CAMD5              string    `gorm:"column:ca_md5;type:char(64);default:null" json:"CA_MD5"`
	Lcuuid             string    `gorm:"column:lcuuid;type:char(64);not null" json:"LCUUID"`
}

type DHCPPort

type DHCPPort struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
	Region         string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	AZ             string `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"`
	VPCID          int    `gorm:"column:epc_id;type:int;default:0" json:"VPC_ID" mapstructure:"VPC_ID"`
}

func (DHCPPort) TableName

func (DHCPPort) TableName() string

type DataSource

type DataSource struct {
	ID                        int       `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	DisplayName               string    `gorm:"column:display_name;type:char(64);default:''" json:"DISPLAY_NAME"`
	DataTableCollection       string    `gorm:"column:data_table_collection;type:char(64);default:''" json:"DATA_TABLE_COLLECTION"`
	State                     int       `gorm:"column:state;type:int;default:1" json:"STATE"`
	BaseDataSourceID          int       `gorm:"column:base_data_source_id;type:int" json:"BASE_DATA_SOURCE_ID"`
	Interval                  int       `gorm:"column:interval;type:int" json:"INTERVAL"`
	RetentionTime             int       `gorm:"column:retention_time;type:int" json:"RETENTION_TIME"` // unit: hour
	SummableMetricsOperator   string    `gorm:"column:summable_metrics_operator;type:char(64)" json:"SUMMABLE_METRICS_OPERATOR"`
	UnSummableMetricsOperator string    `gorm:"column:unsummable_metrics_operator;type:char(64)" json:"UNSUMMABLE_METRICS_OPERATOR"`
	UpdatedAt                 time.Time `gorm:"column:updated_at" json:"UPDATED_AT"`
	Lcuuid                    string    `gorm:"column:lcuuid;type:char(64)" json:"LCUUID"`
}

type DialTestTask

type DialTestTask struct {
	ID            int       `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name          string    `gorm:"column:name;type:varchar(256);not null" json:"NAME"`
	Protocol      int       `gorm:"column:protocol;type:int;not null" json:"PROTOCOL"` // 1.ICMP
	Host          string    `gorm:"column:host;type:varchar(256);not null" json:"HOST"`
	OvertimeTime  int       `gorm:"column:overtime_time;type:int;default:2000" json:"OVERTIME_TIME"`
	Payload       int       `gorm:"column:payload;type:int;default:64" json:"PAYLOAD"`
	TTL           int       `gorm:"column:ttl;type:smallint;default:64" json:"TTL"`
	DialLocation  string    `gorm:"column:dial_location;type:varchar(256);not null" json:"DIAL_LOCATION"`
	DialFrequency int       `gorm:"column:dial_frequency;type:int;default:1000" json:"DIAL_FREQUENCY"`
	PCAP          []byte    `gorm:"column:pcap;type:mediumblob" json:"PCAP"`
	CreatedAt     time.Time `gorm:"column:created_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"CREATED_AT"`
	UpdatedAt     time.Time `gorm:"column:updated_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"UPDATED_AT"`
}

func (DialTestTask) TableName

func (DialTestTask) TableName() string

type Domain

type Domain struct {
	Base         `gorm:"embedded" mapstructure:",squash"`
	OperatedTime `gorm:"embedded" mapstructure:",squash"`
	SyncedAt     *time.Time `gorm:"column:synced_at" json:"SYNCED_AT" mapstructure:"SYNCED_AT"`
	Name         string     `gorm:"column:name;type:varchar(64)" json:"NAME" mapstructure:"NAME"`
	IconID       int        `gorm:"column:icon_id;type:int" json:"ICON_ID" mapstructure:"ICON_ID"`
	DisplayName  string     `gorm:"column:display_name;type:varchar(64);default:''" json:"DISPLAY_NAME" mapstructure:"DISPLAY_NAME"`
	ClusterID    string     `gorm:"column:cluster_id;type:char(64)" json:"CLUSTER_ID" mapstructure:"CLUSTER_ID"`
	Type         int        `gorm:"column:type;type:int;default:0" json:"TYPE" mapstructure:"TYPE"` // 1.openstack 2.vsphere 3.nsp 4.tencent 5.filereader 6.aws 7.pingan 8.zstack 9.aliyun 10.huawei prv 11.k8s 12.simulation 13.huawei 14.qingcloud 15.qingcloud_private 16.F5 17.CMB_CMDB 18.azure 19.apsara_stack 20.tencent_tce 21.qingcloud_k8s 22.kingsoft_private 23.genesis 24.microsoft_acs 25.baidu_bce
	Config       string     `gorm:"column:config;type:text" json:"CONFIG" mapstructure:"CONFIG"`
	ErrorMsg     string     `gorm:"column:error_msg;type:text" json:"ERROR_MSG" mapstructure:"ERROR_MSG"`
	Enabled      int        `gorm:"column:enabled;type:int;not null;default:1" json:"ENABLED" mapstructure:"ENABLED"` // 0.false 1.true
	State        int        `gorm:"column:state;type:int;not null;default:1" json:"STATE" mapstructure:"STATE"`       // 1.normal 2.deleting 3.exception
	ControllerIP string     `gorm:"column:controller_ip;type:char(64)" json:"CONTROLLER_IP" mapstructure:"CONTROLLER_IP"`
}

type DomainAdditionalResource

type DomainAdditionalResource struct {
	ID                int             `gorm:"primaryKey;autoIncrement;unique;column:id;type:int;not null" json:"ID"`
	Domain            string          `gorm:"column:domain;type:char(64);default:''" json:"DOMAIN"`
	Content           string          `gorm:"column:content;type:longtext" json:"CONTENT"`
	CompressedContent compressedBytes `gorm:"column:compressed_content;type:longblob" json:"COMPRESSED_CONTENT"`
	CreatedAt         time.Time       `gorm:"autoCreateTime;column:created_at;type:datetime" json:"CREATED_AT"`
}

type FloatingIP

type FloatingIP struct {
	Base      `gorm:"embedded" mapstructure:",squash"`
	Domain    string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
	Region    string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	VPCID     int    `gorm:"column:epc_id;type:int;default:0" json:"VPC_ID" mapstructure:"VPC_ID"`
	NetworkID int    `gorm:"column:vl2_id;type:int;default:null" json:"VL2_ID" mapstructure:"VL2_ID"` // TODO json字段是否能修改,需返回给前端?
	VMID      int    `gorm:"column:vm_id;type:int;default:null" json:"VM_ID" mapstructure:"VM_ID"`
	IP        string `gorm:"column:ip;type:char(64);default:''" json:"IP" mapstructure:"IP"`
}

func (FloatingIP) TableName

func (FloatingIP) TableName() string

type Host

type Host struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Type           int       `gorm:"column:type;type:int" json:"TYPE" mapstructure:"TYPE"`    // 1.Server 3.Gateway 4.DFI
	State          int       `gorm:"column:state;type:int" json:"STATE" mapstructure:"STATE"` // 0.Temp 1.Creating 2.Complete 3.Modifying 4.Exception
	Name           string    `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Alias          string    `gorm:"column:alias;type:char(64);default:''" json:"ALIAS" mapstructure:"ALIAS"`
	Description    string    `gorm:"column:description;type:varchar(256);default:''" json:"DESCRIPTION" mapstructure:"DESCRIPTION"`
	IP             string    `gorm:"column:ip;type:char(64);default:''" json:"IP" mapstructure:"IP"`
	Hostname       string    `gorm:"column:hostname;type:char(64);default:''" json:"HOSTNAME" mapstructure:"HOSTNAME"`
	HType          int       `gorm:"column:htype;type:int" json:"HTYPE" mapstructure:"HTYPE"`                                   // 1. Xen host 2. VMware host 3. KVM host 4. Public cloud host 5. Hyper-V
	CreateMethod   int       `gorm:"column:create_method;type:int;default:0" json:"CREATE_METHOD" mapstructure:"CREATE_METHOD"` // 0.learning 1.user_defined
	UserName       string    `gorm:"column:user_name;type:varchar(64);default:''" json:"USER_NAME" mapstructure:"USER_NAME"`
	UserPasswd     string    `gorm:"column:user_passwd;type:varchar(64);default:''" json:"USER_PASSWD" mapstructure:"USER_PASSWD"`
	VCPUNum        int       `gorm:"column:vcpu_num;type:int;default:0" json:"VCPU_NUM" mapstructure:"VCPU_NUM"`
	MemTotal       int       `gorm:"column:mem_total;type:int;default:0" json:"MEM_TOTAL" mapstructure:"MEM_TOTAL"` // unit: M
	AZ             string    `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"`
	Region         string    `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	Domain         string    `gorm:"column:domain;type:char(64);default:''" json:"DOMAIN" mapstructure:"DOMAIN"`
	SyncedAt       time.Time `gorm:"column:synced_at;type:datetime;not null;default:CURRENT_TIMESTAMP" json:"SYNCED_AT" mapstructure:"SYNCED_AT"`
	ExtraInfo      string    `gorm:"column:extra_info;type:text;default:''" json:"EXTRA_INFO" mapstructure:"EXTRA_INFO"`
}

func (Host) TableName

func (Host) TableName() string

type KubernetesCluster

type KubernetesCluster struct {
	ID          int       `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	ClusterID   string    `gorm:"column:cluster_id;type:varchar(256);" json:"CLUSTER_ID"`
	Value       string    `gorm:"column:value;type:varchar(256);" json:"VALUE"`
	CreatedAt   time.Time `gorm:"column:created_at;type:datetime;default:CURRENT_TIMESTAMP" json:"CREATED_AT"`
	SyncedAt    time.Time `gorm:"column:synced_at;type:datetime" json:"SYNCED_AT"`
	UpdatedTime time.Time `gorm:"column:updated_time;type:datetime" json:"UPDATED_TIME"`
}

type LANIP

type LANIP struct {
	Base         `gorm:"embedded" mapstructure:",squash"`
	IP           string    `gorm:"column:ip;type:char(64);default:''" json:"IP" mapstructure:"IP"`
	Netmask      string    `gorm:"column:netmask;type:char(64);default:''" json:"NETMASK" mapstructure:"NETMASK"`
	Gateway      string    `gorm:"column:gateway;type:char(64);default:''" json:"GATEWAY" mapstructure:"GATEWAY"`
	CreateMethod int       `gorm:"column:create_method;type:int;default:0" json:"CREATE_METHOD" mapstructure:"CREATE_METHOD"` // 0.learning 1.user_defined
	NetworkID    int       `gorm:"column:vl2id;type:int;default:null" json:"VL2ID" mapstructure:"VL2ID"`
	NetIndex     int       `gorm:"column:net_index;type:int;default:0" json:"NET_INDEX" mapstructure:"NET_INDEX"`
	SubDomain    string    `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
	Domain       string    `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
	VInterfaceID int       `gorm:"column:vifid;type:int;default:null" json:"VINTERFACE_ID" mapstructure:"VINTERFACE_ID"`
	SubnetID     int       `gorm:"column:vl2_net_id;type:int;default:0" json:"SUBNET_ID" mapstructure:"SUBNET_ID"`
	ISP          int       `gorm:"column:isp;type:int;default:0" json:"ISP" mapstructure:"ISP"` // Used for multi-ISP access
	CreatedAt    time.Time `gorm:"column:created_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"CREATED_AT" mapstructure:"CREATED_AT"`
	UpdatedAt    time.Time `gorm:"column:updated_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"UPDATED_AT" mapstructure:"UPDATED_AT"`
}

func (LANIP) TableName

func (LANIP) TableName() string

type LB

type LB struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Label          string `gorm:"column:label;type:char(64);default:''" json:"LABEL" mapstructure:"LABEL"`
	Model          int    `gorm:"column:model;type:int;default:0" json:"MODEL" mapstructure:"MODEL"` // 1.Internal 2.External
	VIP            string `gorm:"column:vip;type:text;default:''" json:"VIP" mapstructure:"VIP"`
	VPCID          int    `gorm:"column:epc_id;type:int;default:0" json:"EPC_ID" mapstructure:"EPC_ID"`
	AZ             string `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"` // TODO delete in future
	Region         string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
	UID            string `gorm:"column:uid;type:char(64);default:''" json:"UID" mapstructure:"UID"`
}

func (LB) TableName

func (LB) TableName() string

type LBListener

type LBListener struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	LBID           int    `gorm:"column:lb_id;type:int;default:0" json:"LB_ID" mapstructure:"LB_ID"`
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	IPs            string `gorm:"column:ips;type:text;default:''" json:"IPS" mapstructure:"IPS"`                // separated by ,
	SNATIPs        string `gorm:"column:snat_ips;type:text;default:''" json:"SNAT_IPS" mapstructure:"SNAT_IPS"` // separated by ,
	Label          string `gorm:"column:label;type:char(64);default:''" json:"LABEL" mapstructure:"LABEL"`
	Port           int    `gorm:"column:port;type:int;default:null" json:"PORT" mapstructure:"PORT"`
	Protocol       string `gorm:"column:protocol;type:char(64);default:''" json:"PROTOCOL" mapstructure:"PROTOCOL"`
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
}

func (LBListener) TableName

func (LBListener) TableName() string

type LBTargetServer

type LBTargetServer struct {
	Base         `gorm:"embedded" mapstructure:",squash"`
	LBID         int    `gorm:"column:lb_id;type:int;default:0" json:"LB_ID" mapstructure:"LB_ID"`
	LBListenerID int    `gorm:"column:lb_listener_id;type:int;default:0" json:"LB_LISTENER_ID" mapstructure:"LB_LISTENER_ID"`
	VPCID        int    `gorm:"column:epc_id;type:int;default:0" json:"EPC_ID" mapstructure:"EPC_ID"`
	Type         int    `gorm:"column:type;type:int;default:0" json:"TYPE" mapstructure:"TYPE"` // 1.VM 2.IP
	IP           string `gorm:"column:ip;type:char(64);default:''" json:"IP" mapstructure:"IP"`
	VMID         int    `gorm:"column:vm_id;type:int;default:0" json:"VM_ID" mapstructure:"VM_ID"`
	Port         int    `gorm:"column:port;type:int;default:null" json:"PORT" mapstructure:"PORT"`
	Protocol     string `gorm:"column:protocol;type:char(64);default:''" json:"PROTOCOL" mapstructure:"PROTOCOL"`
	Domain       string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
}

func (LBTargetServer) TableName

func (LBTargetServer) TableName() string

type LBVMConnection

type LBVMConnection struct {
	Base   `gorm:"embedded" mapstructure:",squash"`
	LBID   int    `gorm:"column:lb_id;type:int;default:null" json:"LB_ID" mapstructure:"LB_ID"`
	VMID   int    `gorm:"column:vm_id;type:int;default:null" json:"VM_ID" mapstructure:"VM_ID"`
	Domain string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
}

func (LBVMConnection) TableName

func (LBVMConnection) TableName() string

type MailServer

type MailServer struct {
	ID           int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Status       int    `gorm:"column:status;type:int;not null" json:"STATUS"`
	Host         string `gorm:"column:host;type:text;not null" json:"HOST"`
	Port         int    `gorm:"column:port;type:int;not null" json:"PORT"`
	User         string `gorm:"column:user;type:text;not null" json:"USER"`
	Password     string `gorm:"column:password;type:text;not null" json:"PASSWORD"`
	Security     string `gorm:"column:security;type:text;not null" json:"SECURITY"`
	NtlmEnabled  int    `gorm:"column:ntlm_enabled;type:int" json:"NTLM_ENABLED"`
	NtlmName     string `gorm:"column:ntlm_name;type:text" json:"NTLM_NAME"`
	NtlmPassword string `gorm:"column:ntlm_password;type:text" json:"NTLM_PASSWORD"`
	Lcuuid       string `gorm:"unique;column:lcuuid;type:char(64)" json:"LCUUID"`
}

func (MailServer) TableName

func (MailServer) TableName() string

type NATGateway

type NATGateway struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Label          string `gorm:"column:label;type:char(64);default:''" json:"LABEL" mapstructure:"LABEL"`
	FloatingIPs    string `gorm:"column:floating_ips;type:text;default:''" json:"FLOATING_IPS" mapstructure:"FLOATING_IPS"` // separated by ,
	VPCID          int    `gorm:"column:epc_id;type:int;default:0" json:"EPC_ID" mapstructure:"EPC_ID"`
	AZ             string `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"` // TODO delete in future
	Region         string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
	UID            string `gorm:"column:uid;type:char(64);default:''" json:"UID" mapstructure:"UID"`
}

func (NATGateway) TableName

func (NATGateway) TableName() string

type NATRule

type NATRule struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	NATGatewayID   int    `gorm:"column:nat_id;type:int;default:0" json:"NAT_ID" mapstructure:"NAT_ID"`
	Type           string `gorm:"column:type;type:char(16);default:''" json:"TYPE" mapstructure:"TYPE"`
	Protocol       string `gorm:"column:protocol;type:char(64);default:''" json:"PROTOCOL" mapstructure:"PROTOCOL"`
	FloatingIP     string `gorm:"column:floating_ip;type:char(64);default:''" json:"FLOATING_IP" mapstructure:"FLOATING_IP"`
	FloatingIPPort int    `gorm:"column:floating_ip_port;type:int;default:null" json:"FLOATING_IP_PORT" mapstructure:"FLOATING_IP_PORT"`
	FixedIP        string `gorm:"column:fixed_ip;type:char(64);default:''" json:"FIXED_IP" mapstructure:"FIXED_IP"`
	FixedIPPort    int    `gorm:"column:fixed_ip_port;type:int;default:null" json:"FIXED_IP_PORT" mapstructure:"FIXED_IP_PORT"`
	VInterfaceID   int    `gorm:"column:port_id;type:int;default:null" json:"PORT_ID" mapstructure:"PORT_ID"`
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
}

func (NATRule) TableName

func (NATRule) TableName() string

type NATVMConnection

type NATVMConnection struct {
	Base         `gorm:"embedded" mapstructure:",squash"`
	NATGatewayID int    `gorm:"column:nat_id;type:int;default:null" json:"NAT_ID" mapstructure:"NAT_ID"`
	VMID         int    `gorm:"column:vm_id;type:int;default:null" json:"VM_ID" mapstructure:"VM_ID"`
	Domain       string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
}

func (NATVMConnection) TableName

func (NATVMConnection) TableName() string

type Network

type Network struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	State          int    `gorm:"column:state;type:int;not null" json:"STATE" mapstructure:"STATE"`           // 0.Temp 1.Creating 2.Created 3.Exception 4.Modifing 5.Destroying 6.Destroyed
	NetType        int    `gorm:"column:net_type;type:int;default:4" json:"NET_TYPE" mapstructure:"NET_TYPE"` // 1.CTRL 2.SERVICE 3.WAN 4.LAN
	Name           string `gorm:"column:name;type:varchar(256);not null" json:"NAME" mapstructure:"NAME"`
	CreateMethod   int    `gorm:"column:create_method;type:int;default:0" json:"CREATE_METHOD" mapstructure:"CREATE_METHOD"` // 0.learning 1.user_defined
	Label          string `gorm:"column:label;type:varchar(64);default:''" json:"LABEL" mapstructure:"LABEL"`
	Alias          string `gorm:"column:alias;type:char(64);default:''" json:"ALIAS" mapstructure:"ALIAS"`
	Description    string `gorm:"column:description;type:varchar(256);default:''" json:"DESCRIPTION" mapstructure:"DESCRIPTION"`
	SubDomain      string `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
	Region         string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	AZ             string `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"`
	ISP            int    `gorm:"column:isp;type:int;default:0" json:"ISP" mapstructure:"ISP"`
	VPCID          int    `gorm:"column:epc_id;type:int;default:0" json:"VPC_ID" mapstructure:"VPC_ID"`
	SegmentationID int    `gorm:"column:segmentation_id;type:int;default:0" json:"SEGMENTATION_ID" mapstructure:"SEGMENTATION_ID"`
	TunnelID       int    `gorm:"column:tunnel_id;type:int;default:0" json:"TUNNEL_ID" mapstructure:"TUNNEL_ID"`
	Shared         bool   `gorm:"column:shared;type:int;default:0" json:"SHARED" mapstructure:"SHARED"`
	Topped         int    `gorm:"column:topped;type:int;default:0" json:"TOPPED" mapstructure:"TOPPED"`
	IsVIP          int    `gorm:"column:is_vip;type:int;default:0" json:"IS_VIP" mapstructure:"IS_VIP"`
}

func (Network) TableName

func (Network) TableName() string

type NpbPolicy

type NpbPolicy struct {
	ID               int       `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name             string    `gorm:"column:name;type:char(64);default:null" json:"NAME"`
	State            int       `gorm:"column:state;type:int;default:null;default:1" json:"STATE"` // 0-disable; 1-enable
	BusinessID       int       `gorm:"column:business_id;type:int;not null" json:"BUSINESS_ID"`
	Direction        int       `gorm:"column:direction;type:int;default:1" json:"DIRECTION"` // 1-two way; 2-server to client
	Vni              int       `gorm:"column:vni;type:int;default:null" json:"VNI"`
	NpbTunnelID      int       `gorm:"column:npb_tunnel_id;type:int;default:null" json:"NPB_TUNNEL_ID"`
	Distribute       int       `gorm:"column:distribute;type:int;default:null" json:"distribute"` // 0-drop, 1-distribute
	PayloadSlice     *int      `gorm:"column:payload_slice;type:int;default:null" json:"PAYLOAD_SLICE"`
	ACLID            int       `gorm:"column:acl_id;type:int;default:null" json:"ACL_ID"`
	PolicyACLGroupID int       `gorm:"column:policy_acl_group_id;type:int;default:null" json:"POLICY_ACL_GROUP_ID"`
	VtapIDs          string    `gorm:"column:vtap_ids;type:text;default:null" json:"VTAP_IDS"` // separated by ,
	CreatedAt        time.Time `gorm:"column:created_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"CREATED_AT"`
	UpdatedAt        time.Time `gorm:"column:updated_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"UPDATED_AT"`
	Lcuuid           string    `gorm:"column:lcuuid;type:char(64);default:null" json:"LCUUID"`
}

NpbPolicy [...]

func (NpbPolicy) TableName

func (NpbPolicy) TableName() string

type NpbTunnel

type NpbTunnel struct {
	ID           int       `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name         string    `gorm:"column:name;type:char(64);not null" json:"NAME"`
	IP           string    `gorm:"column:ip;type:char(64);default:null" json:"IP"`
	Type         int       `gorm:"column:type;type:int;default:null" json:"TYPE"`                         // (0-VXLAN;1-ERSPAN)
	VNIInputType int       `gorm:"column:vni_input_type;type:tinyint(1);default:1" json:"VNI_INPUT_TYPE"` // 1: entire one, 2: two parts
	CreatedAt    time.Time `gorm:"column:created_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"CREATED_AT"`
	UpdatedAt    time.Time `gorm:"column:updated_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"UPDATED_AT"`
	Lcuuid       string    `gorm:"column:lcuuid;type:char(64);default:null" json:"LCUUID"`
}

NpbTunnel [...]

func (NpbTunnel) TableName

func (NpbTunnel) TableName() string

type OperatedTime

type OperatedTime struct {
	CreatedAt time.Time `gorm:"autoCreateTime;column:created_at;type:datetime" json:"CREATED_AT" mapstructure:"CREATED_AT"`
	UpdatedAt time.Time `gorm:"autoUpdateTime;column:updated_at;type:datetime" json:"UPDATED_AT" mapstructure:"UPDATED_AT"`
}

type PcapPolicy

type PcapPolicy struct {
	ID               int       `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name             string    `gorm:"column:name;type:char(64);default:null" json:"NAME"`
	State            int       `gorm:"column:state;type:int;default:null;default:1" json:"STATE"` // 0-disable; 1-enable
	BusinessID       int       `gorm:"column:business_id;type:int;not null" json:"BUSINESS_ID"`
	ACLID            int       `gorm:"column:acl_id;type:int;default:null" json:"ACL_ID"`
	VtapIDs          string    `gorm:"column:vtap_ids;type:text;default:null" json:"VTAP_IDS"` // separated by ,
	PayloadSlice     *int      `gorm:"column:payload_slice;type:int;default:null" json:"PAYLOAD_SLICE"`
	PolicyACLGroupID int       `gorm:"column:policy_acl_group_id;type:int;default:null" json:"POLICY_ACL_GROUP_ID"`
	UserID           int       `gorm:"column:user_id;type:int;default:null" json:"USER_ID"`
	CreatedAt        time.Time `gorm:"column:created_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"CREATED_AT"`
	UpdatedAt        time.Time `gorm:"column:updated_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"UPDATED_AT"`
	Lcuuid           string    `gorm:"column:lcuuid;type:char(64);default:null" json:"LCUUID"`
}

PcapPolicy [...]

func (PcapPolicy) TableName

func (PcapPolicy) TableName() string

type PeerConnection

type PeerConnection struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Label          string `gorm:"column:label;type:char(64);default:''" json:"LABEL" mapstructure:"LABEL"`
	LocalVPCID     int    `gorm:"column:local_epc_id;type:int;default:0" json:"LOCAL_EPC_ID" mapstructure:"LOCAL_EPC_ID"`
	RemoteVPCID    int    `gorm:"column:remote_epc_id;type:int;default:0" json:"REMOTE_EPC_ID" mapstructure:"REMOTE_EPC_ID"`
	LocalRegionID  int    `gorm:"column:local_region_id;type:int;default:0" json:"LOCAL_REGION_ID" mapstructure:"LOCAL_REGION_ID"`
	RemoteRegionID int    `gorm:"column:remote_region_id;type:int;default:0" json:"REMOTE_REGION_ID" mapstructure:"REMOTE_REGION_ID"`
	CreateMethod   int    `gorm:"column:create_method;type:int;default:0" json:"CREATE_METHOD" mapstructure:"CREATE_METHOD"` // 0.learning 1.user_defined
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
}

type Plugin

type Plugin struct {
	ID        int             `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name      string          `gorm:"column:name;type:varchar(256);not null" json:"NAME"`
	Type      int             `gorm:"column:type;type:int" json:"TYPE"` // 1: wasm
	Image     compressedBytes `gorm:"column:image;type:logblob;not null" json:"IMAGE"`
	CreatedAt time.Time       `gorm:"column:created_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"CREATED_AT"`
	UpdatedAt time.Time       `gorm:"column:updated_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"UPDATED_AT"`
}

func (Plugin) TableName

func (Plugin) TableName() string

type Pod

type Pod struct {
	Base            `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase  `gorm:"embedded" mapstructure:",squash"`
	Name            string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Alias           string `gorm:"column:alias;type:char(64);default:''" json:"ALIAS" mapstructure:"ALIAS"`
	State           int    `gorm:"column:state;type:int;not null" json:"STATE" mapstructure:"STATE"`                            // 0.Exception 1.Running
	Label           string `gorm:"column:label;type:text;default:''" json:"LABEL" mapstructure:"LABEL"`                         // separated by ,
	Annotation      string `gorm:"column:annotation;type:text;default:''" json:"ANNOTATION" mapstructure:"ANNOTATION"`          // separated by ,
	ENV             string `gorm:"column:env;type:text;default:''" json:"ENV" mapstructure:"ENV"`                               // separated by ,
	ContainerIDs    string `gorm:"column:container_ids;type:text;default:''" json:"CONTAINER_IDS" mapstructure:"CONTAINER_IDS"` // separated by ,
	PodReplicaSetID int    `gorm:"column:pod_rs_id;type:int;default:null" json:"POD_RS_ID" mapstructure:"POD_RS_ID"`
	PodGroupID      int    `gorm:"column:pod_group_id;type:int;default:null" json:"POD_GROUP_ID" mapstructure:"POD_GROUP_ID"`
	PodNamespaceID  int    `gorm:"column:pod_namespace_id;type:int;default:null" json:"POD_NAMESPACE_ID" mapstructure:"POD_NAMESPACE_ID"`
	PodNodeID       int    `gorm:"column:pod_node_id;type:int;default:null" json:"POD_NODE_ID" mapstructure:"POD_NODE_ID"`
	PodClusterID    int    `gorm:"column:pod_cluster_id;type:int;default:null" json:"POD_CLUSTER_ID" mapstructure:"POD_CLUSTER_ID"`
	VPCID           int    `gorm:"column:epc_id;type:int;default:null" json:"VPC_ID" mapstructure:"VPC_ID"`
	AZ              string `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"`
	Region          string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	SubDomain       string `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
	Domain          string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
}

type PodCluster

type PodCluster struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	ClusterName    string `gorm:"column:cluster_name;type:varchar(256);default:''" json:"CLUSTER_NAME" mapstructure:"CLUSTER_NAME"`
	Version        string `gorm:"column:version;type:varchar(256);default:''" json:"VERSION" mapstructure:"VERSION"`
	VPCID          int    `gorm:"column:epc_id;type:int;default:null" json:"VPC_ID" mapstructure:"VPC_ID"`
	AZ             string `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"`
	Region         string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	SubDomain      string `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
}

type PodGroup

type PodGroup struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Alias          string `gorm:"column:alias;type:char(64);default:''" json:"ALIAS" mapstructure:"ALIAS"`
	Type           int    `gorm:"column:type;type:int;default:null" json:"TYPE" mapstructure:"TYPE"` // 1: Deployment 2: StatefulSet 3: ReplicationController
	PodNum         int    `gorm:"column:pod_num;type:int;default:1" json:"POD_NUM" mapstructure:"POD_NUM"`
	Label          string `gorm:"column:label;type:text;default:''" json:"LABEL" mapstructure:"LABEL"` // separated by ,
	PodNamespaceID int    `gorm:"column:pod_namespace_id;type:int;default:null" json:"POD_NAMESPACE_ID" mapstructure:"POD_NAMESPACE_ID"`
	PodClusterID   int    `gorm:"column:pod_cluster_id;type:int;default:null" json:"POD_CLUSTER_ID" mapstructure:"POD_CLUSTER_ID"`
	AZ             string `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"`
	Region         string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	SubDomain      string `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
}

type PodGroupPort

type PodGroupPort struct {
	Base         `gorm:"embedded" mapstructure:",squash"`
	Name         string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Protocol     string `gorm:"column:protocol;type:char(64);default:''" json:"PROTOCOL" mapstructure:"PROTOCOL"`
	Port         int    `gorm:"column:port;type:int;default:null" json:"PORT" mapstructure:"PORT"`
	PodGroupID   int    `gorm:"column:pod_group_id;type:int;default:null" json:"POD_GROUP_ID" mapstructure:"POD_GROUP_ID"`
	PodServiceID int    `gorm:"column:pod_service_id;type:int;default:null" json:"POD_SERVICE_ID" mapstructure:"POD_SERVICE_ID"`
	SubDomain    string `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
}

type PodIngress

type PodIngress struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Alias          string `gorm:"column:alias;type:char(64);default:''" json:"ALIAS" mapstructure:"ALIAS"`
	PodNamespaceID int    `gorm:"column:pod_namespace_id;type:int;default:null" json:"POD_NAMESPACE_ID" mapstructure:"POD_NAMESPACE_ID"`
	PodClusterID   int    `gorm:"column:pod_cluster_id;type:int;default:null" json:"POD_CLUSTER_ID" mapstructure:"POD_CLUSTER_ID"`
	AZ             string `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"`
	Region         string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	SubDomain      string `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
}

type PodIngressRule

type PodIngressRule struct {
	Base         `gorm:"embedded" mapstructure:",squash"`
	Name         string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Protocol     string `gorm:"column:protocol;type:char(64);default:''" json:"PROTOCOL" mapstructure:"PROTOCOL"`
	Host         string `gorm:"column:host;type:text;default:''" json:"HOST" mapstructure:"HOST"`
	PodIngressID int    `gorm:"column:pod_ingress_id;type:int;default:null" json:"POD_INGRESS_ID" mapstructure:"POD_INGRESS_ID"`
	SubDomain    string `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
}

type PodIngressRuleBackend

type PodIngressRuleBackend struct {
	Base             `gorm:"embedded" mapstructure:",squash"`
	Path             string `gorm:"column:path;type:text;default:''" json:"PATH" mapstructure:"PATH"`
	Port             int    `gorm:"column:port;type:int;default:null" json:"PORT" mapstructure:"PORT"`
	PodServiceID     int    `gorm:"column:pod_service_id;type:int;default:null" json:"POD_SERVICE_ID" mapstructure:"POD_SERVICE_ID"`
	PodIngressRuleID int    `gorm:"column:pod_ingress_rule_id;type:int;default:null" json:"POD_INGRESS_RULE_ID" mapstructure:"POD_INGRESS_RULE_ID"`
	PodIngressID     int    `gorm:"column:pod_ingress_id;type:int;default:null" json:"POD_INGRESS_ID" mapstructure:"POD_INGRESS_ID"`
	SubDomain        string `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
}

type PodNamespace

type PodNamespace struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string            `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Alias          string            `gorm:"column:alias;type:char(64);default:''" json:"ALIAS" mapstructure:"ALIAS"`
	PodClusterID   int               `gorm:"column:pod_cluster_id;type:int;default:null" json:"POD_CLUSTER_ID" mapstructure:"POD_CLUSTER_ID"`
	AZ             string            `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"`
	Region         string            `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	SubDomain      string            `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
	Domain         string            `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
	CloudTags      map[string]string `gorm:"column:cloud_tags;type:text;default:'';serializer:json" json:"CLOUD_TAGS" mapstructure:"CLOUD_TAGS"`
}

type PodNode

type PodNode struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Alias          string `gorm:"column:alias;type:char(64);default:''" json:"ALIAS" mapstructure:"ALIAS"`
	Type           int    `gorm:"column:type;type:int;default:null" json:"TYPE" mapstructure:"TYPE"`                      // 1: Master 2: Node
	ServerType     int    `gorm:"column:server_type;type:int;default:null" json:"SERVER_TYPE" mapstructure:"SERVER_TYPE"` // 1: Host 2: VM
	State          int    `gorm:"column:state;type:int;default:1" json:"STATE" mapstructure:"STATE"`                      // 0: Exception 1: Normal
	IP             string `gorm:"column:ip;type:char(64);default:''" json:"IP" mapstructure:"IP"`
	Hostname       string `gorm:"column:hostname;type:char(64);default:''" json:"HOSTNAME" mapstructure:"HOSTNAME"`
	VCPUNum        int    `gorm:"column:vcpu_num;type:int;default:0" json:"VCPU_NUM" mapstructure:"VCPU_NUM"`
	MemTotal       int    `gorm:"column:mem_total;type:int;default:0" json:"MEM_TOTAL" mapstructure:"MEM_TOTAL"` // unit: M
	PodClusterID   int    `gorm:"column:pod_cluster_id;type:int;default:null" json:"POD_CLUSTER_ID" mapstructure:"POD_CLUSTER_ID"`
	Region         string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	AZ             string `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"`
	VPCID          int    `gorm:"column:epc_id;type:int;default:null" json:"VPC_ID" mapstructure:"VPC_ID"`
	SubDomain      string `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
}

type PodReplicaSet

type PodReplicaSet struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Alias          string `gorm:"column:alias;type:char(64);default:''" json:"ALIAS" mapstructure:"ALIAS"`
	Label          string `gorm:"column:label;type:text;default:''" json:"LABEL" mapstructure:"LABEL"` // separated by ,
	PodNum         int    `gorm:"column:pod_num;type:int;default:1" json:"POD_NUM" mapstructure:"POD_NUM"`
	PodGroupID     int    `gorm:"column:pod_group_id;type:int;default:null" json:"POD_GROUP_ID" mapstructure:"POD_GROUP_ID"`
	PodNamespaceID int    `gorm:"column:pod_namespace_id;type:int;default:null" json:"POD_NAMESPACE_ID" mapstructure:"POD_NAMESPACE_ID"`
	PodClusterID   int    `gorm:"column:pod_cluster_id;type:int;default:null" json:"POD_CLUSTER_ID" mapstructure:"POD_CLUSTER_ID"`
	AZ             string `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"`
	Region         string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	SubDomain      string `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
}

func (PodReplicaSet) TableName

func (PodReplicaSet) TableName() string

type PodService

type PodService struct {
	Base             `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase   `gorm:"embedded" mapstructure:",squash"`
	Name             string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Label            string `gorm:"column:label;type:text;default:''" json:"LABEL" mapstructure:"LABEL"`                // separated by ,
	Annotation       string `gorm:"column:annotation;type:text;default:''" json:"ANNOTATION" mapstructure:"ANNOTATION"` // separated by ,
	Alias            string `gorm:"column:alias;type:char(64);default:''" json:"ALIAS" mapstructure:"ALIAS"`
	Type             int    `gorm:"column:type;type:int;default:null" json:"TYPE" mapstructure:"TYPE"`            // 1: ClusterIP 2: NodePort
	Selector         string `gorm:"column:selector;type:text;default:''" json:"SELECTOR" mapstructure:"SELECTOR"` // separated by ,
	ServiceClusterIP string `gorm:"column:service_cluster_ip;type:char(64);default:''" json:"SERVICE_CLUSTER_IP" mapstructure:"SERVICE_CLUSTER_IP"`
	PodIngressID     int    `gorm:"column:pod_ingress_id;type:int;default:null" json:"POD_INGRESS_ID" mapstructure:"POD_INGRESS_ID"`
	PodNamespaceID   int    `gorm:"column:pod_namespace_id;type:int;default:null" json:"POD_NAMESPACE_ID" mapstructure:"POD_NAMESPACE_ID"`
	PodClusterID     int    `gorm:"column:pod_cluster_id;type:int;default:null" json:"POD_CLUSTER_ID" mapstructure:"POD_CLUSTER_ID"`
	VPCID            int    `gorm:"column:epc_id;type:int;default:null" json:"VPC_ID" mapstructure:"VPC_ID"`
	AZ               string `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"`
	Region           string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	SubDomain        string `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
	Domain           string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
}

type PodServicePort

type PodServicePort struct {
	Base         `gorm:"embedded" mapstructure:",squash"`
	Name         string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Protocol     string `gorm:"column:protocol;type:char(64);default:''" json:"PROTOCOL" mapstructure:"PROTOCOL"`
	Port         int    `gorm:"column:port;type:int;default:null" json:"PORT" mapstructure:"PORT"`
	TargetPort   int    `gorm:"column:target_port;type:int;default:null" json:"TARGET_PORT" mapstructure:"TARGET_PORT"`
	NodePort     int    `gorm:"column:node_port;type:int;default:null" json:"NODE_PORT" mapstructure:"NODE_PORT"`
	PodServiceID int    `gorm:"column:pod_service_id;type:int;default:null" json:"POD_SERVICE_ID" mapstructure:"POD_SERVICE_ID"`
	SubDomain    string `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
}

type Process

type Process struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string    `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	VTapID         uint32    `gorm:"column:vtap_id;type:int;not null;default:0" json:"VTAP_ID" mapstructure:"VTAP_ID"`
	PID            uint64    `gorm:"column:pid;type:int;not null;default:0" json:"PID" mapstructure:"PID"`
	DeviceType     int       `gorm:"column:devicetype;type:int;default:null" json:"DEVICE_TYPE" mapstructure:"DEVICE_TYPE"`
	DeviceID       int       `gorm:"column:deviceid;type:int;default:null" json:"DEVICE_ID" mapstructure:"DEVICE_ID"`
	PodNodeID      int       `gorm:"column:pod_node_id;type:int;default:null" json:"POD_NODE_ID" mapstructure:"POD_NODE_ID"`
	VMID           int       `gorm:"column:vm_id;type:int;default:null" json:"VM_ID" mapstructure:"VM_ID"`
	VPCID          int       `gorm:"column:epc_id;type:int;default:null" json:"EPC_ID" mapstructure:"EPC_ID"`
	ProcessName    string    `gorm:"column:process_name;type:varchar(256);default:''" json:"PROCESS_NAME" mapstructure:"PROCESS_NAME"`
	CommandLine    string    `gorm:"column:command_line;type:text" json:"COMMAND_LINE" mapstructure:"COMMAND_LINE"`
	UserName       string    `gorm:"column:user_name;type:varchar(256);default:''" json:"USER_NAME" mapstructure:"USER_NAME"`
	StartTime      time.Time `gorm:"autoCreateTime;column:start_time;type:datetime" json:"START_TIME" mapstructure:"START_TIME"`
	OSAPPTags      string    `gorm:"column:os_app_tags;type:text" json:"OS_APP_TAGS" mapstructure:"OS_APP_TAGS"`
	ContainerID    string    `gorm:"column:container_id;type:char(64);default:''" json:"CONTAINER_ID" mapstructure:"CONTAINER_ID"`
	NetnsID        uint32    `gorm:"column:netns_id;type:int unsigned;default:0" json:"NETNS_ID" mapstructure:"NETNS_ID"` // used to associate processes with cloud and container resources
	SubDomain      string    `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
	Domain         string    `gorm:"column:domain;type:char(64);default:''" json:"DOMAIN" mapstructure:"DOMAIN"`
}

type PrometheusAutoIncID

type PrometheusAutoIncID struct {
	ID int `gorm:"primaryKey;autoIncrement;unique;column:id;type:int;not null"`
}

type PrometheusID

type PrometheusID struct {
	ID int `gorm:"primaryKey;column:id;type:int(10);unique;not null"`
}

type PrometheusLabel

type PrometheusLabel struct {
	PrometheusAutoIncID    `gorm:"embedded"`
	PrometheusOperatedTime `gorm:"embedded"`
	Name                   string `gorm:"column:name;type:varchar(256);not null"`
	Value                  string `gorm:"column:value;type:text;default:''"`
}

type PrometheusLabelName

type PrometheusLabelName struct {
	PrometheusID           `gorm:"embedded"`
	PrometheusOperatedTime `gorm:"embedded"`
	Name                   string `gorm:"column:name;type:varchar(256);unique;not null"`
}

type PrometheusLabelValue

type PrometheusLabelValue struct {
	PrometheusID           `gorm:"embedded"`
	PrometheusOperatedTime `gorm:"embedded"`
	Value                  string `gorm:"column:value;type:text;unique;default:''"`
}

type PrometheusMetricAPPLabelLayout

type PrometheusMetricAPPLabelLayout struct {
	PrometheusAutoIncID    `gorm:"embedded"`
	PrometheusOperatedTime `gorm:"embedded"`
	MetricName             string `gorm:"column:metric_name;type:varchar(256);not null"`
	APPLabelName           string `gorm:"column:app_label_name;type:varchar(256);not null"`
	APPLabelColumnIndex    uint8  `gorm:"column:app_label_column_index;type:tinyint(3) unsigned;not null"`
}

func (PrometheusMetricAPPLabelLayout) TableName

type PrometheusMetricLabelName

type PrometheusMetricLabelName struct {
	PrometheusAutoIncID    `gorm:"embedded"`
	PrometheusOperatedTime `gorm:"embedded"`
	MetricName             string `gorm:"column:metric_name;type:varchar(256);not null"`
	LabelNameID            int    `gorm:"column:label_name_id;type:int(10);not null"`
}

type PrometheusMetricName

type PrometheusMetricName struct {
	PrometheusID           `gorm:"embedded"`
	PrometheusOperatedTime `gorm:"embedded"`
	Name                   string `gorm:"column:name;type:varchar(256);unique;not null"`
}

type PrometheusMetricTarget

type PrometheusMetricTarget struct {
	PrometheusAutoIncID    `gorm:"embedded"`
	PrometheusOperatedTime `gorm:"embedded"`
	MetricName             string `gorm:"column:metric_name;type:varchar(256);not null"`
	TargetID               int    `gorm:"column:target_id;type:int(10);not null"`
}

type PrometheusOperatedTime

type PrometheusOperatedTime struct {
	CreatedAt time.Time `gorm:"autoCreateTime;column:created_at;type:datetime" json:"CREATED_AT"`
	SyncedAt  time.Time `gorm:"autoCreateTime;column:synced_at;type:datetime" json:"SYNCED_AT"`
}

type PrometheusTarget

type PrometheusTarget struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Instance       string `gorm:"column:instance;type:varchar(255);default:''" json:"INSTANCE" mapstructure:"INSTANCE"`
	Job            string `gorm:"column:job;type:varchar(255);default:''" json:"JOB" mapstructure:"JOB"`
	ScrapeURL      string `gorm:"column:scrape_url;type:varchar(2083);default:''" json:"SCRAPE_URL" mapstructure:"SCRAPE_URL"`
	OtherLabels    string `gorm:"column:other_labels;type:text;default:''" json:"OTHER_LABELS" mapstructure:"OTHER_LABELS"` // separated by ,
	VPCID          int    `gorm:"column:epc_id;type:int;default:0" json:"VPC_ID" mapstructure:"VPC_ID"`
	SubDomain      string `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
	PodClusterID   int    `gorm:"column:pod_cluster_id;type:int;default:null" json:"POD_CLUSTER_ID" mapstructure:"POD_CLUSTER_ID"`
	CreateMethod   int    `gorm:"column:create_method;type:tinyint(1);default:1" json:"CREATE_METHOD" mapstructure:"CREATE_METHOD"`
}

func (PrometheusTarget) TableName

func (PrometheusTarget) TableName() string

type RDSInstance

type RDSInstance struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Label          string `gorm:"column:label;type:char(64);default:''" json:"LABEL" mapstructure:"LABEL"`
	State          int    `gorm:"column:state;type:tinyint(1);not null;default:0" json:"STATE" mapstructure:"STATE"` // 0. Unknown 1. Running 2. Recovering
	Domain         string `gorm:"column:domain;type:char(64);default:''" json:"DOMAIN" mapstructure:"DOMAIN"`
	Region         string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	AZ             string `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"`
	VPCID          int    `gorm:"column:epc_id;type:int;default:0" json:"EPC_ID" mapstructure:"EPC_ID"`
	Type           int    `gorm:"column:type;type:int;default:0" json:"TYPE" mapstructure:"TYPE"` // 0. Unknown 1. MySQL 2. SqlServer 3. PPAS 4. PostgreSQL 5. MariaDB
	Version        string `gorm:"column:version;type:char(64);default:''" json:"VERSION" mapstructure:"VERSION"`
	Series         int    `gorm:"column:series;type:tinyint(1);not null;default:0" json:"SERIES" mapstructure:"SERIES"` // 0. Unknown 1. basic 2. HA
	Model          int    `gorm:"column:model;type:tinyint(1);not null;default:0" json:"MODEL" mapstructure:"MODEL"`    // 0. Unknown 1. Primary 2. Readonly 3. Temporary 4. Disaster recovery 5. share
	UID            string `gorm:"column:uid;type:char(64);default:''" json:"UID" mapstructure:"UID"`
}

func (RDSInstance) TableName

func (RDSInstance) TableName() string

type RVTapGroupConfiguration

type RVTapGroupConfiguration struct {
	ID                            int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	MaxCollectPps                 int    `gorm:"column:max_collect_pps;type:int;default:null" json:"MAX_COLLECT_PPS"`
	MaxNpbBps                     int64  `gorm:"column:max_npb_bps;type:bigint;default:null" json:"MAX_NPB_BPS"` // unit: bps
	MaxCPUs                       int    `gorm:"column:max_cpus;type:int;default:null" json:"MAX_CPUS"`
	MaxMemory                     int    `gorm:"column:max_memory;type:int;default:null" json:"MAX_MEMORY"` // unit: M
	SyncInterval                  int    `gorm:"column:sync_interval;type:int;default:null" json:"SYNC_INTERVAL"`
	StatsInterval                 int    `gorm:"column:stats_interval;type:int;default:null" json:"STATS_INTERVAL"`
	RsyslogEnabled                int    `gorm:"column:rsyslog_enabled;type:tinyint(1);default:null" json:"RSYSLOG_ENABLED"` // 0: disabled 1:enabled
	MaxTxBandwidth                int64  `gorm:"column:max_tx_bandwidth;type:bigint;default:null" json:"MAX_TX_BANDWIDTH"`   // unit: bps
	BandwidthProbeInterval        int    `gorm:"column:bandwidth_probe_interval;type:int;default:null" json:"BANDWIDTH_PROBE_INTERVAL"`
	TapInterfaceRegex             string `gorm:"column:tap_interface_regex;type:text;default:null" json:"TAP_INTERFACE_REGEX"`
	MaxEscapeSeconds              int    `gorm:"column:max_escape_seconds;type:int;default:null" json:"MAX_ESCAPE_SECONDS"`
	Mtu                           int    `gorm:"column:mtu;type:int;default:null" json:"MTU"`
	OutputVlan                    int    `gorm:"column:output_vlan;type:int;default:null" json:"OUTPUT_VLAN"`
	CollectorSocketType           string `gorm:"column:collector_socket_type;type:char(64);default:null" json:"COLLECTOR_SOCKET_TYPE"`
	CompressorSocketType          string `gorm:"column:compressor_socket_type;type:char(64);default:null" json:"COMPRESSOR_SOCKET_TYPE"`
	NpbSocketType                 string `gorm:"column:npb_socket_type;type:char(64);default:null" json:"NPB_SOCKET_TYPE"`
	NpbVlanMode                   int    `gorm:"column:npb_vlan_mode;type:int;default:null" json:"NPB_VLAN_MODE"`
	CollectorEnabled              int    `gorm:"column:collector_enabled;type:tinyint(1);default:null" json:"COLLECTOR_ENABLED"`       // 0: disabled 1:enabled
	VTapFlow1sEnabled             int    `gorm:"column:vtap_flow_1s_enabled;type:tinyint(1);default:null" json:"VTAP_FLOW_1S_ENABLED"` // 0: disabled 1:enabled
	L4LogTapTypes                 string `gorm:"column:l4_log_tap_types;type:text;default:null" json:"L4_LOG_TAP_TYPES"`               // tap type info, separate by ","
	L4LogIgnoreTapSides           string `gorm:"column:l4_log_ignore_tap_sides;type:text;default:null" json:"L4_LOG_IGNORE_TAP_SIDES"` // separate by ","
	L7LogIgnoreTapSides           string `gorm:"column:l7_log_ignore_tap_sides;type:text;default:null" json:"L7_LOG_IGNORE_TAP_SIDES"` // separate by ","
	NpbDedupEnabled               int    `gorm:"column:npb_dedup_enabled;type:tinyint(1);default:null" json:"NPB_DEDUP_ENABLED"`       // 0: disabled 1:enabled
	PlatformEnabled               int    `gorm:"column:platform_enabled;type:tinyint(1);default:null" json:"PLATFORM_ENABLED"`         // 0: disabled 1:enabled
	IfMacSource                   int    `gorm:"column:if_mac_source;type:int;default:null" json:"IF_MAC_SOURCE"`                      // 0: 接口MAC 1: 接口名称 2: 虚拟机MAC解析
	VMXMLPath                     string `gorm:"column:vm_xml_path;type:text;default:null" json:"VM_XML_PATH"`
	ExtraNetnsRegex               string `gorm:"column:extra_netns_regex;type:text;default:null" json:"EXTRA_NETNS_REGEX"`
	NatIPEnabled                  int    `gorm:"column:nat_ip_enabled;type:tinyint(1);default:null" json:"NAT_IP_ENABLED"` // 0: disabled 1:enabled
	CapturePacketSize             int    `gorm:"column:capture_packet_size;type:int;default:null" json:"CAPTURE_PACKET_SIZE"`
	InactiveServerPortEnabled     int    `gorm:"column:inactive_server_port_enabled;type:tinyint(1);default:null" json:"INACTIVE_SERVER_PORT_ENABLED"` // 0: disabled 1:enabled
	InactiveIPEnabled             int    `gorm:"column:inactive_ip_enabled;type:tinyint(1);default:null" json:"INACTIVE_IP_ENABLED"`                   // 0: disabled 1:enabled
	VTapGroupLcuuid               string `gorm:"column:vtap_group_lcuuid;type:char(64);default:null" json:"VTAP_GROUP_LCUUID"`
	LogThreshold                  int    `gorm:"column:log_threshold;type:int;default:null" json:"LOG_THRESHOLD"`
	LogLevel                      string `gorm:"column:log_level;type:char(64);default:null" json:"LOG_LEVEL"`
	LogRetention                  int    `gorm:"column:log_retention;type:int;default:null" json:"LOG_RETENTION"`
	HTTPLogProxyClient            string `gorm:"column:http_log_proxy_client;type:char(64);default:null" json:"HTTP_LOG_PROXY_CLIENT"`
	HTTPLogTraceID                string `gorm:"column:http_log_trace_id;type:text;default:null" json:"HTTP_LOG_TRACE_ID"`
	L7LogPacketSize               int    `gorm:"column:l7_log_packet_size;type:int;default:null" json:"L7_LOG_PACKET_SIZE"`
	L4LogCollectNpsThreshold      int    `gorm:"column:l4_log_collect_nps_threshold;type:int;default:null" json:"L4_LOG_COLLECT_NPS_THRESHOLD"`
	L7LogCollectNpsThreshold      int    `gorm:"column:l7_log_collect_nps_threshold;type:int;default:null" json:"L7_LOG_COLLECT_NPS_THRESHOLD"`
	L7MetricsEnabled              int    `gorm:"column:l7_metrics_enabled;type:tinyint(1);default:null" json:"L7_METRICS_ENABLED"`   // 0: disabled 1:enabled
	L7LogStoreTapTypes            string `gorm:"column:l7_log_store_tap_types;type:text;default:null" json:"L7_LOG_STORE_TAP_TYPES"` // l7 log store tap types, separate by ","
	CaptureSocketType             int    `gorm:"column:capture_socket_type;type:int;default:null" json:"CAPTURE_SOCKET_TYPE"`
	CaptureBpf                    string `gorm:"column:capture_bpf;type:varchar(512);default:null" json:"CAPTURE_BPF"`
	TapMode                       int    `gorm:"column:tap_mode;type:int;default:null" json:"TAP_MODE"` // 0: local 1: mirror 2: physical
	ThreadThreshold               int    `gorm:"column:thread_threshold;type:int;default:null" json:"THREAD_THRESHOLD"`
	ProcessThreshold              int    `gorm:"column:process_threshold;type:int;default:null" json:"PROCESS_THRESHOLD"`
	Lcuuid                        string `gorm:"column:lcuuid;type:char(64);default:null" json:"LCUUID"`
	NtpEnabled                    int    `gorm:"column:ntp_enabled;type:tinyint(1);default:null" json:"NTP_ENABLED"`                         // 0: disabled 1:enabled
	L4PerformanceEnabled          int    `gorm:"column:l4_performance_enabled;type:tinyint(1);default:null" json:"L4_PERFORMANCE_ENABLED"`   // 0: disabled 1:enabled
	PodClusterInternalIP          int    `gorm:"column:pod_cluster_internal_ip;type:tinyint(1);default:null" json:"POD_CLUSTER_INTERNAL_IP"` // 0:  1:
	Domains                       string `gorm:"column:domains;type:text;default:null" json:"DOMAINS"`                                       // domains info, separate by ","
	DecapType                     string `gorm:"column:decap_type;type:text;default:null" json:"DECAP_TYPE"`                                 // separate by ","
	HTTPLogSpanID                 string `gorm:"column:http_log_span_id;type:text;default:null" json:"HTTP_LOG_SPAN_ID"`
	SysFreeMemoryLimit            int    `gorm:"column:sys_free_memory_limit;type:int;default:null" json:"SYS_FREE_MEMORY_LIMIT"` // unit: %
	LogFileSize                   int    `gorm:"column:log_file_size;type:int;default:null" json:"LOG_FILE_SIZE"`                 // unit: MB
	HTTPLogXRequestID             string `gorm:"column:http_log_x_request_id;type:char(64);default:null" json:"HTTP_LOG_X_REQUEST_ID"`
	ExternalAgentHTTPProxyEnabled int    `gorm:"column:external_agent_http_proxy_enabled;type:tinyint(1);default:null" json:"EXTERNAL_AGENT_HTTP_PROXY_ENABLED"`
	ExternalAgentHTTPProxyPort    int    `gorm:"column:external_agent_http_proxy_port;type:int;default:null" json:"EXTERNAL_AGENT_HTTP_PROXY_PORT"`
	PrometheusHttpAPIAddresses    string `gorm:"column:prometheus_http_api_addresses;type:string;default:null" json:"PROMETHEUS_HTTP_API_ADDRESSES"` // ip:port, separate by ","
	AnalyzerPort                  int    `gorm:"column:analyzer_port;type:int;default:null" json:"ANALYZER_PORT"`
	ProxyControllerPort           int    `gorm:"column:proxy_controller_port;type:int;default:null" json:"PROXY_CONTROLLER_PORT"`
	ProxyControllerIP             string `gorm:"column:proxy_controller_ip;type:varchar(512);default:null" json:"PROXY_CONTROLLER_IP"`
	AnalyzerIP                    string `gorm:"column:analyzer_ip;type:varchar(512);default:null" json:"ANALYZER_IP"`
	WasmPlugins                   string `gorm:"column:wasm_plugin;type:text;default:null" json:"WASM_PLUGINS"`
	SoPlugins                     string `gorm:"column:so_plugin;type:text;default:null" json:"SO_PLUGINS"`
	YamlConfig                    string `gorm:"column:yaml_config;type:text;default:null" json:"yaml_config"`
}

VtapGroupConfiguration [...]

type RedisInstance

type RedisInstance struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Label          string `gorm:"column:label;type:char(64);default:''" json:"LABEL" mapstructure:"LABEL"`
	State          int    `gorm:"column:state;type:tinyint(1);not null;default:0" json:"STATE" mapstructure:"STATE"` // 0. Unknown 1. Running 2. Recovering
	Domain         string `gorm:"column:domain;type:char(64);default:''" json:"DOMAIN" mapstructure:"DOMAIN"`
	Region         string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	AZ             string `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"`
	VPCID          int    `gorm:"column:epc_id;type:int;default:0" json:"EPC_ID" mapstructure:"EPC_ID"`
	Version        string `gorm:"column:version;type:char(64);default:''" json:"VERSION" mapstructure:"VERSION"`
	InternalHost   string `gorm:"column:internal_host;type:varchar(128);default:''" json:"INTERNAL_HOST" mapstructure:"INTERNAL_HOST"`
	PublicHost     string `gorm:"column:public_host;type:varchar(128);default:''" json:"PUBLIC_HOST" mapstructure:"PUBLIC_HOST"`
	UID            string `gorm:"column:uid;type:char(64);default:''" json:"UID" mapstructure:"UID"`
}

type Region

type Region struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string  `gorm:"column:name;type:varchar(64);default:''" json:"NAME" mapstructure:"NAME"`
	CreateMethod   int     `gorm:"column:create_method;type:int;default:0" json:"CREATE_METHOD" mapstructure:"CREATE_METHOD"` // 0.learning 1.user_defined
	Label          string  `gorm:"column:label;type:varchar(64);default:''" json:"LABEL" mapstructure:"LABEL"`
	Longitude      float64 `gorm:"column:longitude;type:double(7,4);default:null" json:"LONGITUDE" mapstructure:"LONGITUDE"`
	Latitude       float64 `gorm:"column:latitude;type:double(7,4);default:null" json:"LATITUDE" mapstructure:"LATITUDE"`
}

type ResourceEvent

type ResourceEvent struct {
	ID             int       `gorm:"primaryKey;autoIncrement;unique;column:id;type:int;not null" json:"ID"`
	Domain         string    `gorm:"column:domain;type:char(64);default:''" json:"DOMAIN"`
	SubDomain      string    `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN"`
	ResourceLcuuid string    `gorm:"column:resource_lcuuid;type:char(64);default:''" json:"RESOURCE_LCUUID"`
	Content        string    `gorm:"column:content;type:text" json:"CONTENT"`
	CreatedAt      time.Time `gorm:"autoCreateTime;column:created_at;type:datetime" json:"CREATED_AT"`
}

type ResourceGroup

type ResourceGroup struct {
	ID            int       `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	BusinessID    int       `gorm:"column:business_id;type:int;not null" json:"BUSINESS_ID"`
	Lcuuid        string    `gorm:"column:lcuuid;type:varchar(64);not null" json:"LCUUID"`
	Name          string    `gorm:"column:name;type:varchar(200);not null;default:''" json:"NAME"`
	Type          int       `gorm:"column:type;type:int;not null" json:"TYPE"`            // 1:vm, 2:ip, 3: anonymous vm, 4: anonymous ip, 5: reserved for pod_group, 6: anonymous pod_group, 7: reserved for pod_service, 8: anonymous pod_service, 81: anonymous pod_service as pod_group, 9:lb_bk_rule, 10:reserved for anonymous lb_bk_rule, 11: tmp vm, 21: tmp ip, 13: reserve for vl2, 14: anonymous vl2
	IPType        int       `gorm:"column:ip_type;type:int;default:null" json:"IP_TYPE"`  // 1: single ip, 2: ip range, 3: cidr, 4.mix [1, 2, 3]
	IPs           string    `gorm:"column:ips;type:text;default:null" json:"IPS"`         // ips separated by ,
	VMIDs         string    `gorm:"column:vm_ids;type:text;default:null" json:"VM_IDS"`   // vm ids separated by ,
	NetworkIDs    string    `gorm:"column:vl2_ids;type:text;default:null" json:"VL2_IDS"` // vl2 ids separated by ,
	VPCID         int       `gorm:"column:epc_id;type:int;default:null" json:"VPC_ID"`
	PodClusterID  int       `gorm:"column:pod_cluster_id;type:int;default:null" json:"POD_CLUSTER_ID"`
	PodGroupIDs   string    `gorm:"column:pod_group_ids;type:text;default:null" json:"POD_GROUP_IDS"`     // pod group ids separated by ,
	PodServiceIDs string    `gorm:"column:pod_service_ids;type:text;default:null" json:"POD_SERVICE_IDS"` // pod service ids separated by ,
	LBID          int       `gorm:"column:lb_id;type:int;default:null" json:"LB_ID"`
	LBListenerID  int       `gorm:"column:lb_listener_id;type:int;default:null" json:"LB_LISTENER_ID"`
	ExtraInfoIDs  string    `gorm:"column:extra_info_ids;type:string;default:null" json:"EXTRA_INFO_IDS"`
	IconID        int       `gorm:"column:icon_id;type:int;default:-2" json:"ICON_ID"`
	CreatedAt     time.Time `gorm:"column:created_at;type:datetime;not null;default:CURRENT_TIMESTAMP" json:"CREATED_AT"`
	UpdatedAt     time.Time `gorm:"column:updated_at;type:datetime;not null;default:CURRENT_TIMESTAMP" json:"UPDATED_AT"`
}

type ResourceGroupExtraInfo

type ResourceGroupExtraInfo struct {
	ID           int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	ResourceType int    `gorm:"column:resource_type;type:int;not null" json:"RESOURCE_TYPE"` // 1: epc, 2: vm, 3: pod_group, 4: pod_service
	ResourceID   int    `gorm:"column:resource_id;type:int;not null" json:"RESOURCE_ID"`
	ResourceName string `gorm:"column:resource_name;type:char(64);not null" json:"RESOURCE_NAME"`
}

ResourceGroupExtraInfo [...]

func (ResourceGroupExtraInfo) TableName

func (ResourceGroupExtraInfo) TableName() string

type ResourceGroupPort

type ResourceGroupPort struct {
	ID              int       `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name            string    `gorm:"column:name;type:varchar(256);default:''" json:"NAME"`
	Ports           string    `gorm:"column:ports;type:text;default:null" json:"PORTS"` // Save server ports list when type is customize
	BusinessID      int       `gorm:"column:business_id;type:int;not null" json:"BUSINESS_ID"`
	ResourceGroupID int       `gorm:"column:rg_id;type:int;not null" json:"RG_ID"`
	CreatedAt       time.Time `gorm:"column:created_at;type:datetime;default:CURRENT_TIMESTAMP" json:"CREATED_AT"`
	UpdatedAt       time.Time `gorm:"column:updated_at;type:datetime;default:CURRENT_TIMESTAMP" json:"UPDATED_AT"`
	Lcuuid          string    `gorm:"column:lcuuid;type:char(64);not null" json:"LCUUID"`
}

type RoutingTable

type RoutingTable struct {
	Base        `gorm:"embedded" mapstructure:",squash"`
	VRouterID   int    `gorm:"column:vnet_id;type:int;default:null" json:"VNET_ID" mapstructure:"VNET_ID"`
	Destination string `gorm:"column:destination;type:text;default:''" json:"DESTINATION" mapstructure:"DESTINATION"`
	NexthopType string `gorm:"column:nexthop_type;type:text;default:''" json:"NEXTHOP_TYPE" mapstructure:"NEXTHOP_TYPE"`
	Nexthop     string `gorm:"column:nexthop;type:text;default:''" json:"NEXTHOP" mapstructure:"NEXTHOP"`
}

type SecurityGroup

type SecurityGroup struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Label          string `gorm:"column:label;type:varchar(64);default:''" json:"LABEL" mapstructure:"LABEL"`
	Alias          string `gorm:"column:alias;type:char(64);default:''" json:"ALIAS" mapstructure:"ALIAS"`
	VPCID          int    `gorm:"column:epc_id;type:int;default:0" json:"EPC_ID" mapstructure:"EPC_ID"`
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
	Region         string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	Topped         int    `gorm:"column:topped;type:int;default:0" json:"TOPPED" mapstructure:"TOPPED"`
}

type SecurityGroupRule

type SecurityGroupRule struct {
	Base            `gorm:"embedded" mapstructure:",squash"`
	SecurityGroupID int    `gorm:"column:sg_id;type:int;not null" json:"SG_ID" mapstructure:"SG_ID"`
	Direction       int    `gorm:"column:direction;type:tinyint(1);not null;default:0" json:"DIRECTION" mapstructure:"DIRECTION"` // 0.Unknow 1.Ingress 2.Egress
	Protocol        string `gorm:"column:protocol;type:char(64);default:''" json:"PROTOCOL" mapstructure:"PROTOCOL"`
	EtherType       int    `gorm:"column:ethertype;type:tinyint(1);not null;default:0" json:"ETHERTYPE" mapstructure:"ETHERTYPE"` // 0.Unknow 1.IPv4 2.IPv6
	LocalPortRange  string `gorm:"column:local_port_range;type:text;default:''" json:"LOCAL_PORT_RANGE" mapstructure:"LOCAL_PORT_RANGE"`
	RemotePortRange string `gorm:"column:remote_port_range;type:text;default:''" json:"REMOTE_PORT_RANGE" mapstructure:"REMOTE_PORT_RANGE"`
	Local           string `gorm:"column:local;type:text;default:''" json:"LOCAL" mapstructure:"LOCAL"`
	Remote          string `gorm:"column:remote;type:text;default:''" json:"REMOTE" mapstructure:"REMOTE"`
	Priority        int    `gorm:"column:priority;type:int;not null" json:"PRIORITY" mapstructure:"PRIORITY"`
	Action          int    `gorm:"column:action;type:tinyint(1);not null;default:0" json:"ACTION" mapstructure:"ACTION"` // 0.Unknow 1.Accept 2.Drop
}

type SoftDeleteBase

type SoftDeleteBase struct {
	OperatedTime `mapstructure:",squash"`
	DeletedAt    gorm.DeletedAt `gorm:"column:deleted_at;type:datetime;default:null" json:"DELETED_AT" mapstructure:"DELETED_AT"`
}

type SubDomain

type SubDomain struct {
	Base         `gorm:"embedded" mapstructure:",squash"`
	OperatedTime `gorm:"embedded" mapstructure:",squash"`
	SyncedAt     *time.Time `gorm:"column:synced_at" json:"SYNCED_AT" mapstructure:"SYNCED_AT"`
	Domain       string     `gorm:"column:domain;type:char(64);default:''" json:"DOMAIN" mapstructure:"DOMAIN"`
	Name         string     `gorm:"column:name;type:varchar(64);default:''" json:"NAME" mapstructure:"NAME"`
	DisplayName  string     `gorm:"column:display_name;type:varchar(64);default:''" json:"DISPLAY_NAME" mapstructure:"DISPLAY_NAME"`
	CreateMethod int        `gorm:"column:create_method;type:int;default:0" json:"CREATE_METHOD" mapstructure:"CREATE_METHOD"` // 0.learning 1.user_defined
	ClusterID    string     `gorm:"column:cluster_id;type:char(64);default:''" json:"CLUSTER_ID" mapstructure:"CLUSTER_ID"`
	Config       string     `gorm:"column:config;type:text;default:''" json:"CONFIG" mapstructure:"CONFIG"`
	ErrorMsg     string     `gorm:"column:error_msg;type:text;default:''" json:"ERROR_MSG" mapstructure:"ERROR_MSG"`
	Enabled      int        `gorm:"column:enabled;type:int;not null;default:1" json:"ENABLED" mapstructure:"ENABLED"` // 0.false 1.true
	State        int        `gorm:"column:state;type:int;not null;default:1" json:"STATE" mapstructure:"STATE"`       // 1.normal 2.deleting 3.exception
}

type Subnet

type Subnet struct {
	Base      `gorm:"embedded" mapstructure:",squash"`
	Prefix    string `gorm:"column:prefix;type:char(64);default:''" json:"PREFIX" mapstructure:"PREFIX"`
	Netmask   string `gorm:"column:netmask;type:char(64);default:''" json:"NETMASK" mapstructure:"NETMASK"`
	NetworkID int    `gorm:"column:vl2id;type:int;default:null" json:"VL2ID" mapstructure:"VL2ID"`
	NetIndex  int    `gorm:"column:net_index;type:int;default:0" json:"NET_INDEX" mapstructure:"NET_INDEX"`
	Name      string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Label     string `gorm:"column:label;type:varchar(64);default:''" json:"LABEL" mapstructure:"LABEL"`
	SubDomain string `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
}

func (Subnet) TableName

func (Subnet) TableName() string

type SysConfiguration

type SysConfiguration struct {
	ID        int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	ParamName string `gorm:"column:param_name;type:char(64);not null" json:"PARAM_NAME"`
	Value     string `gorm:"column:value;type:varchar(256);default:null" json:"VALUE"`
	Comments  string `gorm:"column:comments;type:text;default:null" json:"COMMENTS"`
	Lcuuid    string `gorm:"column:lcuuid;type:char(64);default:null" json:"LCUUID"`
}

SysConfiguration [...]

type TapType

type TapType struct {
	ID             int    `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name           string `gorm:"column:name;type:char(64);not null" json:"NAME"`
	Type           int    `gorm:"column:type;type:int;not null;default:1" json:"TYPE"` // 1:packet, 2:sFlow, 3:NetFlow V5 4:NetStream v5
	Region         string `gorm:"column:region;type:char(64);default:null" json:"REGION"`
	Value          int    `gorm:"column:value;type:int;not null" json:"VALUE"`
	VLAN           int    `gorm:"column:vlan;type:int;default:null" json:"VLAN"`
	SrcIP          string `gorm:"column:src_ip;type:char(64);default:null" json:"SRC_IP"`
	InterfaceIndex uint   `gorm:"column:interface_index;type:int unsigned;default:null" json:"INTERFACE_INDEX"` // 1 ~ 2^32-1
	InterfaceName  string `gorm:"column:interface_name;type:char(64);default:null" json:"INTERFACE_NAME"`
	SamplingRate   uint   `gorm:"column:sampling_rate;type:int unsigned;default:null" json:"SAMPLING_RATE"` // 1 ~ 2^32-1
	Description    string `gorm:"column:description;type:varchar(256);default:null" json:"DESCRIPTION"`
	Lcuuid         string `gorm:"column:lcuuid;type:char(64);not null" json:"LCUUID"`
}

type VIP

type VIP struct {
	Base   `gorm:"embedded" mapstructure:",squash"`
	IP     string `gorm:"column:ip;type:char(64);default:''" json:"IP" mapstructure:"IP"`
	Domain string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
	VTapID uint32 `gorm:"column:vtap_id;type:int;not null;default:0" json:"VTAP_ID" mapstructure:"VTAP_ID"`
}

func (VIP) TableName

func (VIP) TableName() string

type VInterface

type VInterface struct {
	Base         `gorm:"embedded" mapstructure:",squash"`
	Name         string    `gorm:"column:name;type:char(64);default:''" json:"NAME" mapstructure:"NAME"`
	Index        int       `gorm:"column:ifindex;type:int;not null" json:"IFINDEX" mapstructure:"IFINDEX"`
	State        int       `gorm:"column:state;type:int;not null" json:"STATE" mapstructure:"STATE"`                          // 1. Attached 2.Detached 3.Exception
	CreateMethod int       `gorm:"column:create_method;type:int;default:0" json:"CREATE_METHOD" mapstructure:"CREATE_METHOD"` // 0.learning 1.user_defined
	Type         int       `gorm:"column:iftype;type:int;default:0" json:"IFTYPE" mapstructure:"IFTYPE"`                      // 0.Unknown 1.Control 2.Service 3.WAN 4.LAN 5.Trunk 6.Tap 7.Tool
	Mac          string    `gorm:"index:mac_index;column:mac;type:char(32);default:''" json:"MAC" mapstructure:"MAC"`
	VMac         string    `gorm:"column:vmac;type:char(32);default:''" json:"VMAC" mapstructure:"VMAC"`
	TapMac       string    `gorm:"column:tap_mac;type:char(32);default:''" json:"TAP_MAC" mapstructure:"TAP_MAC"`
	NetworkID    int       `gorm:"column:subnetid;type:int;default:0" json:"SUBNET_ID" mapstructure:"SUBNET_ID"` // vl2 id
	VlanTag      int       `gorm:"column:vlantag;type:int;default:0" json:"VLANTAG" mapstructure:"VLANTAG"`
	DeviceType   int       `gorm:"column:devicetype;type:int;default:null" json:"DEVICE_TYPE" mapstructure:"DEVICE_TYPE"` // Type 0.unknown 1.vm 2.vgw 3.third-party-device 4.vmwaf 5.NSP-vgateway 6.host-device 7.network-device 9.DHCP-port 10.pod 11.pod_service 12. redis_instance 13. rds_instance 14. pod_node 15. load_balance 16. nat_gateway
	DeviceID     int       `gorm:"column:deviceid;type:int;default:null" json:"DEVICE_ID" mapstructure:"DEVICE_ID"`       // unknown: Senseless ID, vm: vm ID, vgw/NSP-vgateway: vnet ID, third-party-device: third_party_device ID, vmwaf: vmwaf ID, host-device: host_device ID, network-device: network_device ID
	NetnsID      uint32    `gorm:"column:netns_id;type:int unsigned;default:0" json:"NETNS_ID" mapstructure:"NETNS_ID"`   // used to associate processes with cloud and container resources
	VtapID       uint32    `gorm:"column:vtap_id;type:int;default:0" json:"VTAP_ID" mapstructure:"VTAP_ID"`
	SubDomain    string    `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
	Domain       string    `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
	Region       string    `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	CreatedAt    time.Time `gorm:"column:created_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"CREATED_AT" mapstructure:"CREATED_AT"`
	UpdatedAt    time.Time `gorm:"column:updated_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"UPDATED_AT" mapstructure:"UPDATED_AT"`
}

func (VInterface) TableName

func (VInterface) TableName() string

type VM

type VM struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	State          int               `gorm:"index:state_server_index;column:state;type:int;not null" json:"STATE" mapstructure:"STATE"` // 0.Temp 1.Creating 2.Created 3.To run 4.Running 5.To suspend 6.Suspended 7.To resume 8. To stop 9.Stopped 10.Modifing 11.Exception 12.Destroying
	Name           string            `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Alias          string            `gorm:"column:alias;type:char(64);default:''" json:"ALIAS" mapstructure:"ALIAS"`
	Label          string            `gorm:"column:label;type:char(64);default:''" json:"LABEL" mapstructure:"LABEL"`
	IP             string            `gorm:"column:ip;type:char(64);default:''" json:"IP" mapstructure:"IP"`
	Hostname       string            `gorm:"column:hostname;type:char(64);default:''" json:"HOSTNAME" mapstructure:"HOSTNAME"`
	CreateMethod   int               `gorm:"column:create_method;type:int;default:0" json:"CREATE_METHOD" mapstructure:"CREATE_METHOD"` // 0.learning 1.user_defined
	HType          int               `gorm:"column:htype;type:int;default:1" json:"HTYPE" mapstructure:"HTYPE"`                         // 1.vm-c 2.bm-c 3.vm-n 4.bm-n 5.vm-s 6.bm-s
	LaunchServer   string            ``                                                                                                 /* 127-byte string literal not displayed */
	VPCID          int               `gorm:"column:epc_id;type:int;default:0" json:"EPC_ID" mapstructure:"EPC_ID"`
	Domain         string            `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
	AZ             string            `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"`
	Region         string            `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	UID            string            `gorm:"column:uid;type:char(64);default:''" json:"UID" mapstructure:"UID"`
	CloudTags      map[string]string `gorm:"column:cloud_tags;type:text;default:'';serializer:json" json:"CLOUD_TAGS" mapstructure:"CLOUD_TAGS"`
}

func (VM) TableName

func (VM) TableName() string

type VMPodNodeConnection

type VMPodNodeConnection struct {
	Base      `gorm:"embedded" mapstructure:",squash"`
	VMID      int    `gorm:"column:vm_id;type:int;default:null" json:"VM_ID" mapstructure:"VM_ID"`
	PodNodeID int    `gorm:"column:pod_node_id;type:int;default:null" json:"POD_NODE_ID" mapstructure:"POD_NODE_ID"`
	Domain    string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
	SubDomain string `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
}

func (VMPodNodeConnection) TableName

func (VMPodNodeConnection) TableName() string

type VMSecurityGroup

type VMSecurityGroup struct {
	Base            `gorm:"embedded" mapstructure:",squash"`
	SecurityGroupID int `gorm:"column:sg_id;type:int;not null" json:"SG_ID" mapstructure:"SG_ID"`
	VMID            int `gorm:"column:vm_id;type:int;not null" json:"VM_ID" mapstructure:"VM_ID"`
	Priority        int `gorm:"column:priority;type:int;not null" json:"PRIORITY" mapstructure:"PRIORITY"`
}

func (VMSecurityGroup) TableName

func (VMSecurityGroup) TableName() string

type VPC

type VPC struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	CreateMethod   int    `gorm:"column:create_method;type:int;default:0" json:"CREATE_METHOD" mapstructure:"CREATE_METHOD"` // 0.learning 1.user_defined
	Label          string `gorm:"column:label;type:varchar(64);default:''" json:"LABEL" mapstructure:"LABEL"`
	Alias          string `gorm:"column:alias;type:char(64);default:''" json:"ALIAS" mapstructure:"ALIAS"`
	Domain         string `gorm:"column:domain;type:char(64);default:''" json:"DOMAIN" mapstructure:"DOMAIN"`
	Region         string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	AZ             string `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"` // TODO delete in future
	TunnelID       int    `gorm:"column:tunnel_id;type:int;default:0" json:"TUNNEL_ID" mapstructure:"TUNNEL_ID"`
	Mode           int    `gorm:"column:mode;type:int;default:2" json:"MODE" mapstructure:"MODE"` //  1:route, 2:transparent
	CIDR           string `gorm:"column:cidr;type:char(64);default:''" json:"CIDR" mapstructure:"CIDR"`
	UID            string `gorm:"column:uid;type:char(64);default:''" json:"UID" mapstructure:"UID"`
}

func (VPC) TableName

func (VPC) TableName() string

type VPCContact

type VPCContact struct {
	Base         `gorm:"embedded" mapstructure:",squash"`
	CreateMethod int `gorm:"column:create_method;type:int;default:0" json:"CREATE_METHOD" mapstructure:"CREATE_METHOD"` // 0.learning 1.user_defined
	VPCID        int `gorm:"column:epc_id;type:int;default:0" json:"VPC_ID" mapstructure:"VPC_ID"`
	ContactID    int `gorm:"column:contact_id;type:int;default:0" json:"CONTACT_ID" mapstructure:"CONTACT_ID"`
}

func (VPCContact) TableName

func (VPCContact) TableName() string

type VRouter

type VRouter struct {
	Base           `gorm:"embedded" mapstructure:",squash"`
	SoftDeleteBase `gorm:"embedded" mapstructure:",squash"`
	State          int    `gorm:"index:state_server_index;column:state;type:int;not null" json:"STATE" mapstructure:"STATE"` // 0.Temp 1.Creating 2.Created 3.Exception 4.Modifing 5.Destroying 6.To run 7.Running 8.To stop 9.Stopped
	Name           string `gorm:"column:name;type:varchar(256);default:''" json:"NAME" mapstructure:"NAME"`
	Label          string `gorm:"column:label;type:char(64);default:''" json:"LABEL" mapstructure:"LABEL"`
	Description    string `gorm:"column:description;type:varchar(256);default:''" json:"DESCRIPTION" mapstructure:"DESCRIPTION"`
	VPCID          int    `gorm:"column:epc_id;type:int;default:0" json:"EPC_ID" mapstructure:"EPC_ID"`
	GWLaunchServer string `` /* 136-byte string literal not displayed */
	Domain         string `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
	Region         string `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	AZ             string `gorm:"column:az;type:char(64);default:''" json:"AZ" mapstructure:"AZ"` // TODO delete in future
}

func (VRouter) TableName

func (VRouter) TableName() string

type VTap

type VTap struct {
	ID                 int       `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name               string    `gorm:"column:name;type:varchar(256);not null" json:"NAME"`
	State              int       `gorm:"column:state;type:int;default:1" json:"STATE"`   // 0.not-connected 1.normal
	Enable             int       `gorm:"column:enable;type:int;default:1" json:"ENABLE"` // 0: stop 1: running
	Type               int       `gorm:"column:type;type:int;default:0" json:"TYPE"`     // 1: process 2: vm 3: public cloud 4: analyzer 5: physical machine 6: dedicated physical machine 7: host pod 8: vm pod
	CtrlIP             string    `gorm:"column:ctrl_ip;type:char(64);not null" json:"CTRL_IP"`
	CtrlMac            string    `gorm:"column:ctrl_mac;type:char(64);default:null" json:"CTRL_MAC"`
	TapMac             string    `gorm:"column:tap_mac;type:char(64);default:null" json:"TAP_MAC"`
	AnalyzerIP         string    `gorm:"column:analyzer_ip;type:char(64);not null" json:"ANALYZER_IP"`
	CurAnalyzerIP      string    `gorm:"column:cur_analyzer_ip;type:char(64);not null" json:"CUR_ANALYZER_IP"`
	ControllerIP       string    `gorm:"column:controller_ip;type:char(64);not null" json:"CONTROLLER_IP"`
	CurControllerIP    string    `gorm:"column:cur_controller_ip;type:char(64);not null" json:"CUR_CONTROLLER_IP"`
	LaunchServer       string    `gorm:"column:launch_server;type:char(64);not null" json:"LAUNCH_SERVER"`
	LaunchServerID     int       `gorm:"column:launch_server_id;type:int;default:null" json:"LAUNCH_SERVER_ID"`
	AZ                 string    `gorm:"column:az;type:char(64);default:''" json:"AZ"`
	Region             string    `gorm:"column:region;type:char(64);default:''" json:"REGION"`
	Revision           string    `gorm:"column:revision;type:varchar(256);default:null" json:"REVISION"`
	SyncedControllerAt time.Time `gorm:"column:synced_controller_at;type:datetime;not null;default:CURRENT_TIMESTAMP" json:"SYNCED_CONTROLLER_AT"`
	SyncedAnalyzerAt   time.Time `gorm:"column:synced_analyzer_at;type:datetime;not null;default:CURRENT_TIMESTAMP" json:"SYNCED_ANALYZER_AT"`
	CreatedAt          time.Time `gorm:"column:created_at;type:datetime;not null;default:CURRENT_TIMESTAMP" json:"CREATED_AT"`
	BootTime           int       `gorm:"column:boot_time;type:int;default:0" json:"BOOT_TIME"`
	Exceptions         int64     `gorm:"column:exceptions;type:int unsigned;default:0" json:"EXCEPTIONS"`
	VTapLcuuid         string    `gorm:"column:vtap_lcuuid;type:char(64);default:null" json:"VTAP_LCUUID"`
	VtapGroupLcuuid    string    `gorm:"column:vtap_group_lcuuid;type:char(64);default:null" json:"VTAP_GROUP_LCUUID"`
	CPUNum             int       `gorm:"column:cpu_num;type:int;default:0" json:"CPU_NUM"` // logical number of cpu
	MemorySize         int64     `gorm:"column:memory_size;type:bigint;default:0" json:"MEMORY_SIZE"`
	Arch               string    `gorm:"column:arch;type:varchar(256);default:null" json:"ARCH"`
	Os                 string    `gorm:"column:os;type:varchar(256);default:null" json:"OS"`
	KernelVersion      string    `gorm:"column:kernel_version;type:varchar(256);default:null" json:"KERNEL_VERSION"`
	ProcessName        string    `gorm:"column:process_name;type:varchar(256);default:null" json:"PROCESS_NAME"`
	LicenseType        int       `gorm:"column:license_type;type:int;default:null" json:"LICENSE_TYPE"`   // 1: A类 2: B类 3: C类
	LicenseFunctions   string    `gorm:"column:license_functions;type:char(64)" json:"LICENSE_FUNCTIONS"` // separated by ,; 1: 流量分发 2: 网络监控 3: 应用监控
	TapMode            int       `gorm:"column:tap_mode;type:int;default:null" json:"TAP_MODE"`
	ExpectedRevision   string    `gorm:"column:expected_revision;type:text;default null" json:"EXPECTED_REVISION"`
	UpgradePackage     string    `gorm:"column:upgrade_package;type:text;default null" json:"UPGRADE_PACKAGE"`
	Lcuuid             string    `gorm:"column:lcuuid;type:char(64);not null" json:"LCUUID"`
}

func (VTap) TableName

func (VTap) TableName() string

type VTapGroup

type VTapGroup struct {
	ID        int       `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name      string    `gorm:"column:name;type:varchar(64);not null" json:"NAME"`
	CreatedAt time.Time `gorm:"column:created_at;type:datetime;default:CURRENT_TIMESTAMP" json:"CREATED_AT"`
	UpdatedAt time.Time `gorm:"column:updated_at;type:datetime;not null;default:CURRENT_TIMESTAMP" json:"UPDATED_AT"`
	Lcuuid    string    `gorm:"column:lcuuid;type:char(64);not null" json:"LCUUID"`
	ShortUUID string    `gorm:"column:short_uuid;type:char(32);default:null" json:"SHORT_UUID"`
}

func (VTapGroup) TableName

func (VTapGroup) TableName() string

type VTapGroupConfiguration

type VTapGroupConfiguration struct {
	ID                            int     `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	MaxCollectPps                 *int    `gorm:"column:max_collect_pps;type:int;default:null" json:"MAX_COLLECT_PPS"`
	MaxNpbBps                     *int64  `gorm:"column:max_npb_bps;type:bigint;default:null" json:"MAX_NPB_BPS"` // unit: bps
	MaxCPUs                       *int    `gorm:"column:max_cpus;type:int;default:null" json:"MAX_CPUS"`
	MaxMemory                     *int    `gorm:"column:max_memory;type:int;default:null" json:"MAX_MEMORY"` // unit: M
	SyncInterval                  *int    `gorm:"column:sync_interval;type:int;default:null" json:"SYNC_INTERVAL"`
	StatsInterval                 *int    `gorm:"column:stats_interval;type:int;default:null" json:"STATS_INTERVAL"`
	RsyslogEnabled                *int    `gorm:"column:rsyslog_enabled;type:tinyint(1);default:null" json:"RSYSLOG_ENABLED"` // 0: disabled 1:enabled
	MaxTxBandwidth                *int64  `gorm:"column:max_tx_bandwidth;type:bigint;default:null" json:"MAX_TX_BANDWIDTH"`   // unit: bps
	BandwidthProbeInterval        *int    `gorm:"column:bandwidth_probe_interval;type:int;default:null" json:"BANDWIDTH_PROBE_INTERVAL"`
	TapInterfaceRegex             *string `gorm:"column:tap_interface_regex;type:text;default:null" json:"TAP_INTERFACE_REGEX"`
	MaxEscapeSeconds              *int    `gorm:"column:max_escape_seconds;type:int;default:null" json:"MAX_ESCAPE_SECONDS"`
	Mtu                           *int    `gorm:"column:mtu;type:int;default:null" json:"MTU"`
	OutputVlan                    *int    `gorm:"column:output_vlan;type:int;default:null" json:"OUTPUT_VLAN"`
	CollectorSocketType           *string `gorm:"column:collector_socket_type;type:char(64);default:null" json:"COLLECTOR_SOCKET_TYPE"`
	CompressorSocketType          *string `gorm:"column:compressor_socket_type;type:char(64);default:null" json:"COMPRESSOR_SOCKET_TYPE"`
	NpbSocketType                 *string `gorm:"column:npb_socket_type;type:char(64);default:null" json:"NPB_SOCKET_TYPE"`
	NpbVlanMode                   *int    `gorm:"column:npb_vlan_mode;type:int;default:null" json:"NPB_VLAN_MODE"`
	CollectorEnabled              *int    `gorm:"column:collector_enabled;type:tinyint(1);default:null" json:"COLLECTOR_ENABLED"`       // 0: disabled 1:enabled
	VTapFlow1sEnabled             *int    `gorm:"column:vtap_flow_1s_enabled;type:tinyint(1);default:null" json:"VTAP_FLOW_1S_ENABLED"` // 0: disabled 1:enabled
	L4LogTapTypes                 *string `gorm:"column:l4_log_tap_types;type:text;default:null" json:"L4_LOG_TAP_TYPES"`               // tap type info, separate by ","
	L4LogIgnoreTapSides           *string `gorm:"column:l4_log_ignore_tap_sides;type:text;default:null" json:"L4_LOG_IGNORE_TAP_SIDES"` // separate by ","
	L7LogIgnoreTapSides           *string `gorm:"column:l7_log_ignore_tap_sides;type:text;default:null" json:"L7_LOG_IGNORE_TAP_SIDES"` // separate by ","
	NpbDedupEnabled               *int    `gorm:"column:npb_dedup_enabled;type:tinyint(1);default:null" json:"NPB_DEDUP_ENABLED"`       // 0: disabled 1:enabled
	PlatformEnabled               *int    `gorm:"column:platform_enabled;type:tinyint(1);default:null" json:"PLATFORM_ENABLED"`         // 0: disabled 1:enabled
	IfMacSource                   *int    `gorm:"column:if_mac_source;type:int;default:null" json:"IF_MAC_SOURCE"`                      // 0: 接口MAC 1: 接口名称 2: 虚拟机MAC解析
	VMXMLPath                     *string `gorm:"column:vm_xml_path;type:text;default:null" json:"VM_XML_PATH"`
	ExtraNetnsRegex               *string `gorm:"column:extra_netns_regex;type:text;default:null" json:"EXTRA_NETNS_REGEX"`
	NatIPEnabled                  *int    `gorm:"column:nat_ip_enabled;type:tinyint(1);default:null" json:"NAT_IP_ENABLED"` // 0: disabled 1:enabled
	CapturePacketSize             *int    `gorm:"column:capture_packet_size;type:int;default:null" json:"CAPTURE_PACKET_SIZE"`
	InactiveServerPortEnabled     *int    `gorm:"column:inactive_server_port_enabled;type:tinyint(1);default:null" json:"INACTIVE_SERVER_PORT_ENABLED"` // 0: disabled 1:enabled
	InactiveIPEnabled             *int    `gorm:"column:inactive_ip_enabled;type:tinyint(1);default:null" json:"INACTIVE_IP_ENABLED"`                   // 0: disabled 1:enabled
	VTapGroupLcuuid               *string `gorm:"column:vtap_group_lcuuid;type:char(64);default:null" json:"VTAP_GROUP_LCUUID"`
	LogThreshold                  *int    `gorm:"column:log_threshold;type:int;default:null" json:"LOG_THRESHOLD"`
	LogLevel                      *string `gorm:"column:log_level;type:char(64);default:null" json:"LOG_LEVEL"`
	LogRetention                  *int    `gorm:"column:log_retention;type:int;default:null" json:"LOG_RETENTION"`
	HTTPLogProxyClient            *string `gorm:"column:http_log_proxy_client;type:char(64);default:null" json:"HTTP_LOG_PROXY_CLIENT"`
	HTTPLogTraceID                *string `gorm:"column:http_log_trace_id;type:text;default:null" json:"HTTP_LOG_TRACE_ID"`
	L7LogPacketSize               *int    `gorm:"column:l7_log_packet_size;type:int;default:null" json:"L7_LOG_PACKET_SIZE"`
	L4LogCollectNpsThreshold      *int    `gorm:"column:l4_log_collect_nps_threshold;type:int;default:null" json:"L4_LOG_COLLECT_NPS_THRESHOLD"`
	L7LogCollectNpsThreshold      *int    `gorm:"column:l7_log_collect_nps_threshold;type:int;default:null" json:"L7_LOG_COLLECT_NPS_THRESHOLD"`
	L7MetricsEnabled              *int    `gorm:"column:l7_metrics_enabled;type:tinyint(1);default:null" json:"L7_METRICS_ENABLED"`   // 0: disabled 1:enabled
	L7LogStoreTapTypes            *string `gorm:"column:l7_log_store_tap_types;type:text;default:null" json:"L7_LOG_STORE_TAP_TYPES"` // l7 log store tap types, separate by ","
	CaptureSocketType             *int    `gorm:"column:capture_socket_type;type:int;default:null" json:"CAPTURE_SOCKET_TYPE"`
	CaptureBpf                    *string `gorm:"column:capture_bpf;type:varchar(512);default:null" json:"CAPTURE_BPF"`
	TapMode                       *int    `gorm:"column:tap_mode;type:int;default:null" json:"TAP_MODE"` // 0: local 1: mirror 2: physical
	ThreadThreshold               *int    `gorm:"column:thread_threshold;type:int;default:null" json:"THREAD_THRESHOLD"`
	ProcessThreshold              *int    `gorm:"column:process_threshold;type:int;default:null" json:"PROCESS_THRESHOLD"`
	Lcuuid                        *string `gorm:"column:lcuuid;type:char(64);default:null" json:"LCUUID"`
	NtpEnabled                    *int    `gorm:"column:ntp_enabled;type:tinyint(1);default:null" json:"NTP_ENABLED"`                         // 0: disabled 1:enabled
	L4PerformanceEnabled          *int    `gorm:"column:l4_performance_enabled;type:tinyint(1);default:null" json:"L4_PERFORMANCE_ENABLED"`   // 0: disabled 1:enabled
	PodClusterInternalIP          *int    `gorm:"column:pod_cluster_internal_ip;type:tinyint(1);default:null" json:"POD_CLUSTER_INTERNAL_IP"` // 0:  1:
	Domains                       *string `gorm:"column:domains;type:text;default:null" json:"DOMAINS"`                                       // domains info, separate by ","
	DecapType                     *string `gorm:"column:decap_type;type:text;default:null" json:"DECAP_TYPE"`                                 // separate by ","
	HTTPLogSpanID                 *string `gorm:"column:http_log_span_id;type:text;default:null" json:"HTTP_LOG_SPAN_ID"`
	SysFreeMemoryLimit            *int    `gorm:"column:sys_free_memory_limit;type:int;default:null" json:"SYS_FREE_MEMORY_LIMIT"` // unit: %
	LogFileSize                   *int    `gorm:"column:log_file_size;type:int;default:null" json:"LOG_FILE_SIZE"`                 // unit: MB
	HTTPLogXRequestID             *string `gorm:"column:http_log_x_request_id;type:char(64);default:null" json:"HTTP_LOG_X_REQUEST_ID"`
	ExternalAgentHTTPProxyEnabled *int    `gorm:"column:external_agent_http_proxy_enabled;type:tinyint(1);default:null" json:"EXTERNAL_AGENT_HTTP_PROXY_ENABLED"`
	ExternalAgentHTTPProxyPort    *int    `gorm:"column:external_agent_http_proxy_port;type:int;default:null" json:"EXTERNAL_AGENT_HTTP_PROXY_PORT"`
	PrometheusHttpAPIAddresses    *string `gorm:"column:prometheus_http_api_addresses;type:string;default:null" json:"PROMETHEUS_HTTP_API_ADDRESSES"` // ip:port, separate by ","
	AnalyzerPort                  *int    `gorm:"column:analyzer_port;type:int;default:null" json:"ANALYZER_PORT"`
	ProxyControllerPort           *int    `gorm:"column:proxy_controller_port;type:int;default:null" json:"PROXY_CONTROLLER_PORT"`
	ProxyControllerIP             *string `gorm:"column:proxy_controller_ip;type:varchar(512);default:null" json:"PROXY_CONTROLLER_IP"`
	AnalyzerIP                    *string `gorm:"column:analyzer_ip;type:varchar(512);default:null" json:"ANALYZER_IP"`
	WasmPlugins                   *string `gorm:"column:wasm_plugins;type:text;default:null" json:"WASM_PLUGINS"`
	SoPlugins                     *string `gorm:"column:so_plugins;type:text;default:null" json:"SO_PLUGINS"`
	YamlConfig                    *string `gorm:"column:yaml_config;type:text;default:null" json:"YAML_CONFIG"`
}

func (VTapGroupConfiguration) TableName

func (VTapGroupConfiguration) TableName() string

type VTapRepo

type VTapRepo struct {
	ID        int             `gorm:"primaryKey;column:id;type:int;not null" json:"ID"`
	Name      string          `gorm:"column:name;type:char(64);not null" json:"NAME"`
	Arch      string          `gorm:"column:arch;type:varchar(256);default:''" json:"ARCH"`
	OS        string          `gorm:"column:os;type:varchar(256);default:''" json:"OS"`
	Branch    string          `gorm:"column:branch;type:varchar(256);default:''" json:"BRANCH"`
	RevCount  string          `gorm:"column:rev_count;type:varchar(256);default:''" json:"REV_COUNT"`
	CommitID  string          `gorm:"column:commit_id;type:varchar(256);default:''" json:"COMMIT_ID"`
	Image     compressedBytes `gorm:"column:image;type:logblob;not null" json:"IMAGE"`
	CreatedAt time.Time       `gorm:"column:created_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"CREATED_AT"`
	UpdatedAt time.Time       `gorm:"column:updated_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"UPDATED_AT"`
}

func (VTapRepo) TableName

func (VTapRepo) TableName() string

type WANIP

type WANIP struct {
	Base         `gorm:"embedded" mapstructure:",squash"`
	IP           string    `gorm:"column:ip;type:char(64);default:''" json:"IP" mapstructure:"IP"`
	Alias        string    `gorm:"column:alias;type:char(64);default:''" json:"ALIAS" mapstructure:"ALIAS"`
	Netmask      int       `gorm:"column:netmask;type:int;default:null" json:"NETMASK" mapstructure:"NETMASK"`
	Gateway      string    `gorm:"column:gateway;type:char(64);default:''" json:"GATEWAY" mapstructure:"GATEWAY"`
	CreateMethod int       `gorm:"column:create_method;type:int;default:0" json:"CREATE_METHOD" mapstructure:"CREATE_METHOD"` // 0.learning 1.user_defined
	ISP          int       `gorm:"column:isp;type:int;default:null" json:"ISP" mapstructure:"ISP"`
	VInterfaceID int       `gorm:"column:vifid;type:int;default:0" json:"VINTERFACE_ID" mapstructure:"VINTERFACE_ID"`
	SubnetID     int       `gorm:"column:vl2_net_id;type:int;default:0" json:"SUBNET_ID" mapstructure:"SUBNET_ID"`
	SubDomain    string    `gorm:"column:sub_domain;type:char(64);default:''" json:"SUB_DOMAIN" mapstructure:"SUB_DOMAIN"`
	Domain       string    `gorm:"column:domain;type:char(64);not null" json:"DOMAIN" mapstructure:"DOMAIN"`
	Region       string    `gorm:"column:region;type:char(64);default:''" json:"REGION" mapstructure:"REGION"`
	CreatedAt    time.Time `gorm:"column:created_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"CREATED_AT" mapstructure:"CREATED_AT"`
	UpdatedAt    time.Time `gorm:"column:updated_at;type:timestamp;not null;default:CURRENT_TIMESTAMP" json:"UPDATED_AT" mapstructure:"UPDATED_AT"`
}

func (WANIP) TableName

func (WANIP) TableName() string

Directories

Path Synopsis
rawsql
DO NOT DELETE for go list to grab directory
DO NOT DELETE for go list to grab directory
migrator module
*
*

Jump to

Keyboard shortcuts

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