cluster

package
v1.4.0 Latest Latest
Warning

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

Go to latest
Published: Nov 16, 2021 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cluster

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

Cluster cluster

func New

func New(options ...Option) *Cluster

New new cluster

func (*Cluster) Create

func (c *Cluster) Create(req *apistructs.ClusterCreateRequest) error

Create create cluster

func (*Cluster) CreateWithEvent

func (c *Cluster) CreateWithEvent(req *apistructs.ClusterCreateRequest) error

CreateWithEvent create cluster with event request

func (*Cluster) DeleteByName

func (c *Cluster) DeleteByName(clusterName string) error

DeleteByName delete cluster by name

func (*Cluster) DeleteWithEvent

func (c *Cluster) DeleteWithEvent(clusterName string) error

DeleteWithEvent delete cluster with delete event

func (*Cluster) GetCluster

func (c *Cluster) GetCluster(idOrName string) (*apistructs.ClusterInfo, error)

GetCluster get cluster by name

func (*Cluster) ListCluster

func (c *Cluster) ListCluster() (*[]apistructs.ClusterInfo, error)

ListCluster list all cluster

func (*Cluster) ListClusterByType

func (c *Cluster) ListClusterByType(clusterType string) (*[]apistructs.ClusterInfo, error)

func (*Cluster) PatchWithEvent

func (c *Cluster) PatchWithEvent(req *apistructs.ClusterPatchRequest) error

PatchWithEvent patch with event

func (*Cluster) Update

func (c *Cluster) Update(req *apistructs.ClusterUpdateRequest) error

Update update cluster

func (*Cluster) UpdateWithEvent

func (c *Cluster) UpdateWithEvent(req *apistructs.ClusterUpdateRequest) error

UpdateWithEvent update cluster & sender cluster update event

type Option

type Option func(*Cluster)

func WithBundle

func WithBundle(bdl *bundle.Bundle) Option

func WithDBClient

func WithDBClient(db *dbclient.DBClient) Option

Jump to

Keyboard shortcuts

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