service

package
v0.0.0-...-a3a5c94 Latest Latest
Warning

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

Go to latest
Published: Aug 21, 2021 License: MIT Imports: 30 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Duplicate

func Duplicate(a interface{}) (ret []interface{})

Duplicate

Types

type AppService

type AppService struct {
	Prefix string
	// contains filtered or unexported fields
}

AppService

func CreateAppService

func CreateAppService(c *option.Conf) *AppService

CreateAppService

func (*AppService) FindAppEndpoints

func (a *AppService) FindAppEndpoints(appName string) []*config.Endpoint

FindAppEndpoints

type DiscoverAction

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

DiscoverAction

func CreateDiscoverActionManager

func CreateDiscoverActionManager(conf *option.Conf, kubecli kubecache.KubeClient) *DiscoverAction

CreateDiscoverActionManager

func (*DiscoverAction) DiscoverClusters

func (d *DiscoverAction) DiscoverClusters(
	tenantService,
	serviceCluster string) (*envoyv1.CDSCluter, *util.APIHandleError)

DiscoverClusters cds discover create cluster by get depend app endpoints from plugin config

func (*DiscoverAction) DiscoverListeners

func (d *DiscoverAction) DiscoverListeners(
	tenantService, serviceCluster string) (*envoyv1.LDSListener, *util.APIHandleError)

DiscoverListeners lds create listens by get depend app endpoints from plugin config

func (*DiscoverAction) DiscoverService

func (d *DiscoverAction) DiscoverService(serviceInfo string) (*envoyv1.SDSHost, *util.APIHandleError)

DiscoverService

func (*DiscoverAction) GetPluginConfigAndType

func (d *DiscoverAction) GetPluginConfigAndType(namespace, sourceAlias, pluginID string) (*api_model.ResourceSpec, bool, error)

GetPluginConfigAndType get plugin configs and plugin type (default mesh or custom mesh) if not exist return error

func (*DiscoverAction) GetPluginConfigs

func (d *DiscoverAction) GetPluginConfigs(namespace, sourceAlias, pluginID string) (*api_model.ResourceSpec, error)

GetPluginConfigs if not exist return error

type NodeService

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

NodeService

func CreateNodeService

func CreateNodeService(c *option.Conf, nodecluster *node.Cluster, kubecli kubecache.KubeClient) *NodeService

CreateNodeService

func (*NodeService) AddNode

AddNode

func (*NodeService) AsynchronousInstall

func (n *NodeService) AsynchronousInstall(node *client.HostNode, eventID string)

AsynchronousInstall

func (*NodeService) CheckNode

func (n *NodeService) CheckNode(nodeUID string) (*model.InstallStatus, *utils.APIHandleError)

CheckNode install status

func (*NodeService) CordonNode

func (n *NodeService) CordonNode(nodeID string, unschedulable bool) *utils.APIHandleError

CordonNode set node as unscheduler

func (*NodeService) DeleteNode

func (n *NodeService) DeleteNode(nodeID string) *utils.APIHandleError

DeleteNode only node status is offline and node can be deleted

func (*NodeService) DeleteNodeCondition

func (n *NodeService) DeleteNodeCondition(nodeUID string, condition client.NodeConditionType) (*client.HostNode, *utils.APIHandleError)

DeleteNodeCondition

func (*NodeService) DeleteNodeLabel

func (n *NodeService) DeleteNodeLabel(nodeID string, labels map[string]string) (map[string]string, *utils.APIHandleError)

DeleteNodeLabel

func (*NodeService) DownNode

func (n *NodeService) DownNode(nodeID string) (*client.HostNode, *utils.APIHandleError)

DownNode

func (*NodeService) GetAllNode

func (n *NodeService) GetAllNode() ([]*client.HostNode, *utils.APIHandleError)

GetAllNode

func (*NodeService) GetNode

func (n *NodeService) GetNode(nodeID string) (*client.HostNode, *utils.APIHandleError)

GetNode info

func (*NodeService) GetNodeLabels

func (n *NodeService) GetNodeLabels(nodeID string) (*model.LabelsResp, *utils.APIHandleError)

GetNodeLabels returns node labels, including system labels and custom labels

func (*NodeService) GetNodeResource

func (n *NodeService) GetNodeResource(nodeUID string) (*model.NodePodResource, *utils.APIHandleError)

GetNodeResource

func (*NodeService) GetServicesHealthy

func (n *NodeService) GetServicesHealthy() (map[string][]map[string]string, *utils.APIHandleError)

GetServicesHealthy

func (*NodeService) InstallNode

func (n *NodeService) InstallNode(node *client.HostNode) *utils.APIHandleError

InstallNode

func (*NodeService) PutNodeLabel

func (n *NodeService) PutNodeLabel(nodeID string, labels map[string]string) (map[string]string, *utils.APIHandleError)

PutNodeLabel update node label

func (*NodeService) UpNode

func (n *NodeService) UpNode(nodeID string) (*client.HostNode, *utils.APIHandleError)

UpNode

func (*NodeService) UpdateNodeStatus

func (n *NodeService) UpdateNodeStatus(nodeID, status string) *utils.APIHandleError

UpdateNodeStatus

type PrometheusService

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

PrometheusService

func CreatePrometheusService

func CreatePrometheusService(c *option.Conf, ms *masterserver.MasterServer) *PrometheusService

CreatePrometheusService

func (*PrometheusService) Exec

Exec prometheus query

func (*PrometheusService) ExecRange

func (ts *PrometheusService) ExecRange(expr, start, end, step string) (*model.Prome, *utils.APIHandleError)

ExecRange - exec prometheus query range

Jump to

Keyboard shortcuts

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