rpc

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2021 License: AGPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Conn

type Conn interface {
	GetClient() interface{}
	Open()
	Close() error
}

type GrpcConn

type GrpcConn struct {
	// contains filtered or unexported fields
}

func NewGrpcConn

func NewGrpcConn(host string, port uint16, tlsCert string, macaroon string, logger *logrus.Entry, newClientFunc func(*grpc.ClientConn) interface{}) *GrpcConn

func (*GrpcConn) Close

func (t *GrpcConn) Close() error

func (*GrpcConn) GetClient

func (t *GrpcConn) GetClient() interface{}

func (*GrpcConn) Open

func (t *GrpcConn) Open()

func (*GrpcConn) Update

func (t *GrpcConn) Update(host string, port uint16, tlsCert string, macaroon string) error

type HttpConn

type HttpConn struct {
}

type JsonrpcConn

type JsonrpcConn struct {
}

type MacaroonCredential

type MacaroonCredential string

MacaroonCredential implements the credentials.PerRPCCredentials interface.

func (MacaroonCredential) GetRequestMetadata

func (t MacaroonCredential) GetRequestMetadata(ctx context.Context, uri ...string) (map[string]string, error)

GetRequestMetadata implements the PerRPCCredentials interface. This method is required in order to pass the wrapped macaroon into the gRPC context. With this, the macaroon will be available within the request handling scope of the ultimate gRPC server implementation.

func (MacaroonCredential) RequireTransportSecurity

func (t MacaroonCredential) RequireTransportSecurity() bool

RequireTransportSecurity implements the PerRPCCredentials interface.

Jump to

Keyboard shortcuts

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