Documentation ¶
Index ¶
Constants ¶
View Source
const (
PluginsRoot = root + ".plugins"
)
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Options ¶
type Options struct { Port int MaxConcurrentStreams int64 InitialWindowSize int32 InitialConnWindowSize int32 TLS struct { Enabled bool Auth struct { Type string } Type string Auto struct { Host string } File struct { Cert string Key string CA string `config:"ca"` } } `config:"tls"` }
Options grpc server options.
func NewOptions ¶
NewOptions returns options from config file or environment vars.
func NewOptionsWithPath ¶
NewOptionsWithPath unmarshals options based a given key path.
type Plugin ¶
type Plugin func(ctx context.Context) []grpc.ServerOption
Plugin defines a grpc server Plugin function to execute.
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server represents a grpc server.
func NewServerWithConfigPath ¶
NewServerWithConfigPath returns a new grpc server with options from config path.
func NewServerWithOptions ¶
NewServerWithOptions returns a new grpc server with options.
func (*Server) ServiceRegistrar ¶
func (s *Server) ServiceRegistrar() grpc.ServiceRegistrar
ServiceRegistrar returns grpc service register.
Click to show internal directories.
Click to hide internal directories.