func (t *BodyTracer) CloseIdleConnections() {
	type closeIdler interface {
		CloseIdleConnections()
	}
	if tr, ok := t.Transport.(closeIdler); ok {
		tr.CloseIdleConnections()
	}
}
CloseIdleConnections closes the idle connections.
package oldhttptransport
import (
	"io"
	"net/http"
	"time"
	"github.com/ooni/probe-engine/legacy/netx/modelx"
	"github.com/ooni/probe-engine/legacy/netx/transactionid"
)
type BodyTracer struct {
	Transport http.RoundTripper
}
func NewBodyTracer(roundTripper http.RoundTripper) *BodyTracer {
	return &BodyTracer{Transport: roundTripper}
}
func (t *BodyTracer) RoundTrip(req *http.Request) (resp *http.Response, err error) {
	resp, err = t.Transport.RoundTrip(req)
	if err != nil {
		return
	}
	resp.Body = &bodyWrapper{
		ReadCloser: resp.Body,
		root:       modelx.ContextMeasurementRootOrDefault(req.Context()),
		tid:        transactionid.ContextTransactionID(req.Context()),
	}
	return
}