View definition

(*Transport).CancelRequest

Defined in github.com/golang/go/src/net/http/transport.go

Description

CancelRequest cancels an in-flight request by closing its connection. CancelRequest should only be called after RoundTrip has returned.

Deprecated: Use Request.WithContext to create a request with a cancelable context instead. CancelRequest cannot cancel HTTP/2 requests.