Documentation
¶
Overview ¶
Package server provides tools to create http servers and handlers wrapping the turbo router
Index ¶
- Constants
- Variables
- func DefaultToHTTPError(_ error) int
- func InitHTTPDefaultTransport(cfg config.ServiceConfig)
- func NewServer(cfg config.ServiceConfig, handler http.Handler) *http.Server
- func ParseTLSConfig(cfg *config.TLS) *tls.Config
- func RunServer(ctx context.Context, cfg config.ServiceConfig, handler http.Handler) error
- type ToHTTPError
Constants ¶
View Source
const ( HeaderCompleteResponseValue = "true" HeaderIncompleteResponseValue = "false" )
Variables ¶
View Source
var ( CompleteResponseHeaderName = "X-Sonic-Completed" HeadersToSend = []string{"Content-Type"} UserAgentHeaderValue = []string{core.SonicUserAgent} ErrInternalError = errors.New("internal server error") ErrPrivateKey = errors.New("private key not defined") ErrPublicKey = errors.New("public key not defined") )
Functions ¶
func DefaultToHTTPError ¶
func InitHTTPDefaultTransport ¶
func InitHTTPDefaultTransport(cfg config.ServiceConfig)
Types ¶
type ToHTTPError ¶
Click to show internal directories.
Click to hide internal directories.