• Clayton Coleman's avatar
    Logging request / response body should not allocate · ea2ab71f
    Clayton Coleman authored
    Putting string(data) in the critical path causes an allocation which can
    be very large, and happens regardless of whether logging is enabled.
    
    Also, use the more sophisticated logging of body output that avoids
    causing quoting of JSON output (current behavior is "{\"key\":...}" and
    should be {"key":...} for readability).
    ea2ab71f
request.go 36.5 KB