client_golang
client_golang copied to clipboard
Support the SetWriteDeadline and SetReadDeadline interfaces
I'm using the new ResponseController, introduced in Go 1.20 to set a timeout on the response writer.
Your delegator did not respect the new interfaces SetWriteDeadline and SetReadDeadline.
Example:
rc := http.NewResponseController(w)
err = rc.SetWriteDeadline(time.Now().Add(5 * time.Second)) // returns ErrNotSupported
It would be nice, if the InstrumentHandlerDuration or InstrumentHandlerCounter would support this.
I'm currently using v1.18.0.