client

package
v0.9.2 Latest Latest
Warning

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

Go to latest
Published: Mar 18, 2024 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CustomCredentials

type CustomCredentials struct {
	oauth2.TokenSource
	*transport.ImpersonationConfig
}

CustomCredentials supplies PerRPCCredentials from a Token Source and Impersonation config.

func (*CustomCredentials) GetRequestMetadata

func (cc *CustomCredentials) GetRequestMetadata(ctx context.Context, uri ...string) (map[string]string, error)

GetRequestMetadata gets the request metadata as a map from a Custom.

func (*CustomCredentials) RequireTransportSecurity

func (cc *CustomCredentials) RequireTransportSecurity() bool

RequireTransportSecurity indicates whether the credentials requires transport security.

type GRPCClient

GRPCClient represents GRPC API client to connect to Tekton results api server.

func NewGRPCClient

func NewGRPCClient(serverAddress string, opts ...grpc.DialOption) (GRPCClient, error)

NewGRPCClient creates a new gRPC client.

type RESTClient

RESTClient represents rest API client to connect to Tekton results api server.

func NewRESTClient

func NewRESTClient(serverAddress string, opts ...RestOption) (RESTClient, error)

NewRESTClient creates a new REST client.

type RestOption

type RestOption func(client *restClient) error

RestOption is customization of the HTTP Client.

func WithConfig

func WithConfig(config *transport.Config) RestOption

WithConfig allows customization of the HTTP Client.

func WithTimeout

func WithTimeout(duration time.Duration) RestOption

WithTimeout adds universal timeout for all HTTP request.

Jump to

Keyboard shortcuts

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