node

package
v0.32.3 Latest Latest
Warning

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

Go to latest
Published: Dec 29, 2025 License: BSD-3-Clause Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNodesNotFound = fmt.Errorf("nodes not found")
View Source
var ErrNotSet = errors.New("node client not initialized")

ErrNotSet represents error when NodeClient is not set

Functions

This section is empty.

Types

type Client

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

func New

func New(cfg *ClientConfig) *Client

func (*Client) GetNodes

func (sc *Client) GetNodes(ctx context.Context) (nodes NodeList, err error)

func (*Client) Namespace added in v0.31.0

func (sc *Client) Namespace() string

type ClientConfig

type ClientConfig struct {
	Log            logging.Logger
	HTTPClient     *http.Client
	K8sClient      *k8s.Client
	BeeClients     orchestration.ClientMap
	Namespace      string
	LabelSelector  string
	DeploymentType DeploymentType
	InCluster      bool
	UseNamespace   bool     // Overrides the usage of the bee clients
	NodeGroups     []string // Node groups for filtering nodes (only used with beekeeper deployment)
}

type DeploymentType

type DeploymentType string
const (
	DeploymentTypeBeekeeper DeploymentType = "beekeeper"
	DeploymentTypeHelm      DeploymentType = "helm"
)

type Node

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

func NewNode

func NewNode(client *api.Client, name string) *Node

func (*Node) Client

func (n *Node) Client() *api.Client

func (*Node) Name

func (n *Node) Name() string

type NodeList

type NodeList []Node

func (NodeList) Get

func (ns NodeList) Get(name string) *Node

func (NodeList) Sort added in v0.31.0

func (ns NodeList) Sort() NodeList

type NodeProvider

type NodeProvider interface {
	GetNodes(ctx context.Context) (NodeList, error)
	Namespace() string
}

type NotSet

type NotSet struct{}

func (*NotSet) GetNodes

func (n *NotSet) GetNodes(ctx context.Context) (NodeList, error)

GetNodes implements NodeProvider.

func (*NotSet) Namespace added in v0.31.0

func (n *NotSet) Namespace() string

Jump to

Keyboard shortcuts

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