#HTTP

3 posts

Go Practice #5 Middleware Patterns
6 min read

Go Practice #5 Middleware Patterns

Standard middleware built from chains of http.Handler adapters — logging, auth, panic recovery, request ID, CORS.

Go Practice #2 Routing — Go 1.22+ ServeMux
5 min read

Go Practice #2 Routing — Go 1.22+ ServeMux

Method/pattern matching in the standard ServeMux from Go 1.22+. Where external routers like chi or gorilla/mux still fit.

Go Practice #1 First HTTP Server
5 min read

Go Practice #1 First HTTP Server

The smallest server, started with the single net/http package. ListenAndServe, HandleFunc, ResponseWriter, and graceful shutdown.