bootstrap

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package bootstrap provides the functionality to register possible options for aspects of the xDS client through the bootstrap file.

Experimental

Notice: This package is EXPERIMENTAL and may be changed or removed in a later release.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterCredentials

func RegisterCredentials(c Credentials)

RegisterCredentials registers Credentials used for connecting to the xds management server.

NOTE: this function must only be called during initialization time (i.e. in an init() function), and is not thread-safe. If multiple credentials are registered with the same name, the one registered last will take effect.

Types

type Credentials

type Credentials interface {
	// Build returns a credential bundle associated with this credential, and
	// a function to cleans up additional resources associated with this bundle
	// when it is no longer needed.
	Build(config json.RawMessage) (credentials.Bundle, func(), error)
	// Name returns the credential name associated with this credential.
	Name() string
}

Credentials interface encapsulates a credentials.Bundle builder that can be used for communicating with the xDS Management server.

func GetCredentials

func GetCredentials(name string) Credentials

GetCredentials returns the credentials associated with a given name. If no credentials are registered with the name, nil will be returned.

Jump to

Keyboard shortcuts

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