Skip to content
mutablelogicPublic

About

General HTTP Server for golang with a plugin architecture

Topics

Resources

Stars

5 stars

Watchers

1 watching

Forks

Latest commit

 

History

811 Commits

Folders and files

Repository files navigation

go-server

go-server is a Go module of packages for building HTTP servers and their command-line clients. Applications import it:

go get github.com/mutablelogic/go-server

Packages

Package Description
pkg/cmd Command-line applications, with a server command, global flags and defaults which are kept between commands
pkg/httpserver The HTTP server, with its timeouts
pkg/httprouter The router, with cross-origin requests, and an OpenAPI specification of its paths
pkg/httprequest Reading requests: JSON, forms, queries, and files streamed from the request
pkg/httpresponse Writing responses: JSON, errors, streams, and files, with their caching and preconditions
pkg/jsonschema JSON schemas of Go types, and validating JSON with them
pkg/openapi OpenAPI specifications, and their documentation in markdown
pkg/otel OpenTelemetry tracing
pkg/logger Structured logging
pkg/tui Tables and other output for terminals
pkg/types Common types, such as files, content types and headers
pkg/version The version of a build

Building and testing

You need Go, the version in go.mod, and Make.

Target Description
make test Runs go vet, and the unit and coverage tests
make vet Runs go vet
make unit-test Runs the unit tests, verbosely with VERBOSE=1
make race-test Runs the unit tests with the race detector
make coverage-test Reports the tests' coverage
make tidy Runs go mod tidy
make clean Removes the build directory

The tests run in GitHub Actions for pull requests and pushes to main on Linux, and for releases on Windows and macOS too.

About

General HTTP Server for golang with a plugin architecture

Topics

Resources

Stars

5 stars

Watchers

1 watching

Forks

Releases

Used by

Contributors

Languages