cluster

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Aug 1, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Discovery string `yaml:"discovery"`
	Namespace string `yaml:"namespace"`
	Service   string `yaml:"service"`
}

Config contains the cluster configuration.

type Connection

type Connection interface {
	Endpoints(portname string) []Endpoint
	Broadcast(req *http.Request, portname string, path string)
}

Connection is the cluster connection interface.

func NewConnection

func NewConnection(config *Config) (Connection, error)

NewConnection create a new cluster connection.

func NewKubernetesClient

func NewKubernetesClient(namespace string, service string) (Connection, error)

NewKubernetesClient create a new kubernetes clientset.

type Endpoint

type Endpoint struct {
	Name string
	Host string
	Port int
}

Endpoint contains kubernetes endpoint information.

Jump to

Keyboard shortcuts

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