credentials

package
v0.0.8 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Provider

type Provider interface {
	ContextWithAuth(context.Context) (context.Context, context.CancelFunc) // TODO(shmel1k@): think about compatibility
	// with ydb-go-sdk
	ContextWithoutAuth(context.Context) (context.Context, context.CancelFunc)

	GetToken() (string, error)
	Init() error
}

func New

func New(
	opts *command.BaseOptions,
	connectionsFactory connectionsfactory.Factory,
	logger *zap.SugaredLogger,
	impl Provider,
) Provider

func NewIamCreds added in v0.0.4

func NewIamCreds(keyfileName, iamEndpoint string) Provider

func NewIamToken

func NewIamToken(token string) Provider

func NewMetadata added in v0.0.4

func NewMetadata(logger *zap.SugaredLogger) Provider

func NewStatic

func NewStatic(
	login, password string,
	connectionsFactory connectionsfactory.Factory,
	logger *zap.SugaredLogger,
) Provider

Jump to

Keyboard shortcuts

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