Skip to content

httpcli: introduce mutable, wrapped transports

Warren Gifford requested to merge mutable-wrapped-transports into main

Created by: bobheadxi

Re-implements https://github.com/sourcegraph/sourcegraph/pull/39702 with an approach that makes our wrapped transports fully unwrappable, such that a pointer to the implementation can be retrieved and replaced, namely with a clone of the underlying *http.Transport. I think this fixes the issue described in https://github.com/sourcegraph/sourcegraph/pull/39702, and removes what seems to be an old workaround around some options not supporting wrapped transports.

Test plan

Unit tests in httpcli to test the wrapping behaviour, and @mollylogue 's test of gitolite now passes.

Merge request reports

Loading