httpkit

module
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Oct 14, 2026 License: Apache-2.0

README

httpkit

Small, composable HTTP building blocks for Go's standard library.

Package Purpose
assets Serve embedded files with asset caching and gzip negotiation.
grace Run one HTTP server with bounded graceful shutdown.
middleware Compose handlers, log requests, recover panics, and enforce browser-origin write checks.
parse Parse header entries and status-code expressions from configuration.
prefix Mount handlers and generate URLs below an optional path prefix.
response Write JSON/XML responses, track final status, and validate local redirects.
server Run related graceful listeners as one unit.

Install

go get github.com/containeroo/httpkit

assets.Static serves embedded frontend files with cache control and optional gzip. response.NewRequestWriter and response.LogFailure correlate HTTP failures with access logs.

Directories

Path Synopsis
Package assets serves embedded files with configurable caching and gzip compression.
Package assets serves embedded files with configurable caching and gzip compression.
Package grace runs HTTP servers with graceful shutdown support.
Package grace runs HTTP servers with graceful shutdown support.
Package middleware provides composable HTTP handler wrappers.
Package middleware provides composable HTTP handler wrappers.
Package parse parses common HTTP configuration values.
Package parse parses common HTTP configuration values.
Package prefix provides small helpers for mounting net/http handlers under a configurable URL prefix.
Package prefix provides small helpers for mounting net/http handlers under a configurable URL prefix.
Package response provides small, transport-neutral HTTP response helpers.
Package response provides small, transport-neutral HTTP response helpers.
Package server runs related HTTP listeners with coordinated graceful shutdown.
Package server runs related HTTP listeners with coordinated graceful shutdown.

Jump to

Keyboard shortcuts

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