{"repo":"gol4ng/httpware","free":true,"listed":false,"github":"https://github.com/gol4ng/httpware","clone":"git clone https://github.com/gol4ng/httpware.git","description":"provide (http-server) middlewares and (http-client) tripperwares","language":"Go","stars":13,"topics":["middleware","middlewares","http-middleware","http","metric","prometheus","request-id","tracing","tripperware","roundtripper"],"license":"MIT","category":"analytics","readme_excerpt":"httpware Package httpware is a collection of middleware (net/http.Handler wrapper) and tripperware (net/http.RoundTripper wrapper) - CorrelationId gets or creates a correlation id and adds it to the http.request Context and in the http.response header (in order to propagate this ID throught all microservices) - Metrics will use a given Recorder to collect inflight request (current parrallel request count), request duration and response size . Name Middleware Tripperware ------ :--------: :--------: Authentication X AuthenticationForwarder X CorrelationId X X Metrics X X Interceptor X X Skip X X Enable X X RateLimiter X X Installation go get -u github.com/gol4ng/httpware Quick Start Client side Server side Middlewares A middleware is an http.Handler decorator, its role is to wrap arround http.Handler or another middleware A middleware stack is a collection of middleware ( []Middleware ) that acts has a single Middleware (Append/Prepend). A stack allows you to DecorateHandler and DecorateHandlerFunc Tripperwares A tripperware is an http.RoundTripper decorator, its role is to wrap arround http.RoundTripper or another tripperware A tripperware stack is a collection of tripperware ( []Tripperware ) that acts has a single Tripperware (RoundTrip/DecorateClient/Append/Prepend). A stack allows you to DecorateRoundTripper and DecorateRoundTripFunc. Decorate existing client You can decorate an existing http.Client Act has http.RoundTripper A tripperware can be use has an http.RoundTripp","default_branch":null,"files":null,"tree":[],"storefront":"/r/gol4ng","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/gol4ng/httpware/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}