Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type Authenticator ¶
type Authenticator interface {
GetToken() string
}
type Connection ¶
type Connection struct { *grpc.ClientConn // contains filtered or unexported fields }
func NewConnection ¶
func NewConnection( ctx context.Context, endpoint string, creds credentials.TransportCredentials, auth Authenticator, db string, ) (*Connection, error)
func (*Connection) Alive ¶
func (c *Connection) Alive() bool
func (*Connection) Close ¶
func (c *Connection) Close() error
func (*Connection) Invoke ¶
func (c *Connection) Invoke(ctx context.Context, method string, args any, reply any, opts ...grpc.CallOption) error
func (*Connection) NewStream ¶
func (c *Connection) NewStream( ctx context.Context, desc *grpc.StreamDesc, method string, opts ...grpc.CallOption, ) (grpc.ClientStream, error)
Click to show internal directories.
Click to hide internal directories.