MaxBytes Middleware in Go: The Same Trap, Again

A follow-up to the timeout middleware post. The same file upload endpoint that needed a longer timeout also needed a larger request body limit, and the standard http.MaxBytesReader fails the same way – an inner middleware can shrink the limit set by an outer one, but never extend it. The fix is the same one the timeout post landed on, one layer down: share a single mutable limiter through the…