distribution/context
Aaron Lehmann 0e7462f1dd Fix CloseNotifier handling and avoid "the ResponseWriter does not implement CloseNotifier" warnings in logs
A change in #763 to address review comments caused problems. Originally,
instrumentedResponseWriter implemented the CloseNotifier interface, and
would panic if it was wrapping something that did not implement that
interface. This was split into a separate instrumentedResponseWriterCN
type that implements CloseNotifier, so there's a fallback if
instrumentedResponseWriter ever needs to wrap something that does not
implement this interface.

instrumentedResponseWriter's Value method would end up upcasting either
type back to instrumentedResponseWriter, which does not implement the
interface. In effect, instrumentedResponseWriterCN was never visible to
the handler.

This fixes the problem by implementing a wrapper Value method for
instrumentedResponseWriterCN.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
2015-08-18 17:28:51 -07:00
..
context.go Move context once to instanceContext from global scope 2015-07-30 13:59:44 -07:00
doc.go Context package to support context-aware logging 2015-02-06 16:20:38 -08:00
http.go Fix CloseNotifier handling and avoid "the ResponseWriter does not implement CloseNotifier" warnings in logs 2015-08-18 17:28:51 -07:00
http_test.go Don't panic when a http.ResponseWriter does not implement CloseNotifier 2015-08-06 15:50:54 -07:00
logger.go Only enable uuid generation warning when using registry handlers 2015-07-30 14:27:07 -07:00
trace.go Replace uuid dependency with internal library 2015-05-22 18:59:41 -07:00
trace_test.go Contextual tracing support for logs 2015-04-10 16:42:30 -07:00
util.go Improve context package 2015-04-01 15:40:21 -07:00