httpserver

package
v0.0.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 16, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FailResponseOnError

func FailResponseOnError(w http.ResponseWriter, err error)

func RunGracefully

func RunGracefully(ctx context.Context, handler http.Handler, opt ...Option) error

Types

type Option

type Option func(c *cfg)

func ListenAddr

func ListenAddr(listenAddr string) Option

func ListenPort

func ListenPort(port int) Option

func Logger

func Logger(log *slog.Logger) Option

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL