Documentation
¶
Overview ¶
Package grpc provides basic gRPC functions.
Package grpc provides basic gRPC functions.
Package grpc provides basic gRPC functions.
Package grpc provides basic gRPC functions.
Package grpc provides basic gRPC functions.
Index ¶
- type Client
- func (c *Client) AddImport(path ...string)
- func (c *Client) AddProtobuf(path ...string)
- func (c *Client) CancelQuery()
- func (c *Client) Close()
- func (c *Client) Connect(addr string, opts ...ClientOpt) error
- func (c *Client) LoadFromProtobuf() ([]*entity.Service, []*entity.ProtobufError, *entity.ProtobufError)
- func (c *Client) LoadFromReflection() ([]*entity.Service, error)
- func (c *Client) Query(method *entity.Method, data map[string]interface{}, requestMetadata []string) (qResp *entity.QueryResponse, err error)
- type ClientOpt
- type ClientOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client object capable of interacting with Client
func (*Client) AddProtobuf ¶
AddProtobuf adds protobuf files
func (*Client) CancelQuery ¶
func (c *Client) CancelQuery()
CancelQuery aborting a running gRPC request
func (*Client) LoadFromProtobuf ¶
func (c *Client) LoadFromProtobuf() ([]*entity.Service, []*entity.ProtobufError, *entity.ProtobufError)
LoadFromProtobuf loads services from protobuf
func (*Client) LoadFromReflection ¶
LoadFromReflection loads services using reflection
type ClientOpt ¶
type ClientOpt func(options *ClientOptions)
func WithClientCertificate ¶
WithClientCertificate returns ClientOpt which sets client certificate
func WithClientKey ¶
WithClientKey returns ClientOpt which sets client certificate private key
func WithInsecure ¶
func WithInsecure() ClientOpt
WithInsecure returns ClientOpt which disables server certificate chain verification and hostname
func WithNoTLS ¶
func WithNoTLS() ClientOpt
WithNoTLS returns ClientOpt which disables transport security
func WithRootCertificate ¶
WithRootCertificate returns ClientOpt which sets server CA certificate
type ClientOptions ¶
type ClientOptions struct {
// contains filtered or unexported fields
}
ClientOptions represents Client options