server

package
v0.12.0 Latest Latest
Warning

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

Go to latest
Published: Sep 22, 2026 License: Apache-2.0 Imports: 65 Imported by: 0

Documentation

Index

Constants

View Source
const StatusClientClosed = 499

Variables

View Source
var InterruptFlags = []os.Signal{os.Interrupt, syscall.SIGTERM}

Signals that begin a graceful shutdown. SIGTERM is what container runtimes send on stop; without it the process dies on Go's default disposition and nothing gets flushed. Tests override this to send a signal they control.

Functions

func ListenAndServe

func ListenAndServe(config *config.Config, ent *entities.Entities, reloadPtr *func(*config.Config, *entities.Entities) error) error

func SetupHealth added in v0.8.0

func SetupHealth(ctx context.Context, cfg *config.Config, layerGroup *layer.LayerGroup, caches *cache.CacheRegistry) (func(context.Context) error, func(), error)

func ValidateCORS added in v0.12.0

func ValidateCORS(cfg config.CORSConfig, errorMessages config.ErrorMessages) error

func ValidateCacheControl added in v0.12.0

func ValidateCacheControl(cfg config.CacheControlConfig, path string, errorMessages config.ErrorMessages) error

The path is the dotted prefix the block was found at so the message names the right place

Types

type CheckResult added in v0.8.0

type CheckResult struct {
	// contains filtered or unexported fields
}

type MultiHandler added in v0.6.0

type MultiHandler struct {
	// contains filtered or unexported fields
}

Simple slog.Handler that sends all requests to children handlers

func (MultiHandler) Enabled added in v0.6.0

func (h MultiHandler) Enabled(c context.Context, l slog.Level) bool

func (MultiHandler) Handle added in v0.6.0

func (h MultiHandler) Handle(c context.Context, r slog.Record) error

func (MultiHandler) WithAttrs added in v0.6.0

func (h MultiHandler) WithAttrs(attrs []slog.Attr) slog.Handler

func (MultiHandler) WithGroup added in v0.6.0

func (h MultiHandler) WithGroup(name string) slog.Handler

Jump to

Keyboard shortcuts

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