Example of using package context with HTTP Middleware in Golang
Run the server:
$ go run main.go
In another terminal cURL the endpoint:
$ curl localhost:8080 -H "X-Request-Id: UNIQUE_REQ_ID"
Hello request: UNIQUE_REQ_ID, from 127.0.0.1
This codebase was heavily inspired by the following blog posts and repositories: