remoteclient

package
v0.0.0-...-84ace31 Latest Latest
Warning

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

Go to latest
Published: Mar 17, 2020 License: Apache-2.0 Imports: 14 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Builder

type Builder interface {
	// Build will return a static kubeclient for the remote cluster.
	Build() (client.Client, error)

	// BuildDynamic will return a dynamic kubeclient for the remote cluster.
	BuildDynamic() (dynamic.Interface, error)

	// Unreachable returns true if Hive has not been able to reach the remote cluster.
	// Note that this function will not attempt to reach the remote cluster. It only checks the current conditions on
	// the ClusterDeployment to determine if the remote cluster is reachable.
	Unreachable() bool

	// APIURL returns the API URL used to connect to the remote cluster.
	APIURL() (string, error)

	// RESTConfig returns the config for a REST client that connects to the remote cluster.
	RESTConfig() (*rest.Config, error)

	// UsePrimaryAPIURL will use the primary API URL. If there is an API URL override, then that is the primary.
	// Otherwise, the primary is the default API URL.
	UsePrimaryAPIURL() Builder

	// UseSecondaryAPIURL will use the secondary API URL. If there is an API URL override, then the initial API URL
	// is the secondary.
	UseSecondaryAPIURL() Builder
}

Builder is used to build API clients to the remote cluster

func NewBuilder

func NewBuilder(c client.Client, cd *hivev1.ClusterDeployment, controllerName string) Builder

NewBuilder creates a new Builder for creating a client to connect to the remote cluster associated with the specified ClusterDeployment. The controllerName is needed for metrics.

Directories

Path Synopsis
Package mock is a generated GoMock package.
Package mock is a generated GoMock package.

Jump to

Keyboard shortcuts

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