Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Options ¶
type Options struct { BindAddress string `json:"bind-address" mapstructure:"bind-address"` BindPort int `json:"bind-port" mapstructure:"bind-port"` MaxMsgSize int `json:"max-msg-size" mapstructure:"max-msg-size"` TLS TLSOptions `json:"tls" mapstructure:"tls"` }
Options contains configuration options for grpc server.
type Server ¶
type Server interface { // Setup setups the grpc server. Setup should be called before Run. Setup(SetupFunc) error // Run starts the grpc server. Run() error // Close shutdowns the grpc server. Close() }
Server is the interface of grpc server.
type TLSOptions ¶
type TLSOptions struct { Enabled bool `json:"enabled" mapstructure:"enabled"` // CertFile is a file containing a PEM-encoded certificate, and possibly the complete certificate chain CertFile string `json:"cert-file" mapstructure:"cert-file"` // KeyFile is a file containing a PEM-encoded private key for the certificate specified by CertFile KeyFile string `json:"private-key-file" mapstructure:"private-key-file"` }
TLSOptions contains configuration for TLS.
Click to show internal directories.
Click to hide internal directories.