summaryrefslogtreecommitdiff
path: root/AUTHORS
diff options
context:
space:
mode:
authorNeil Alexander <neilalexander@users.noreply.github.com>2021-09-03 21:07:22 +0000
committerDamien Neil <dneil@google.com>2021-10-28 17:57:57 +0000
commit266626211e40d1f2c3a34fa4cd2023f5310cbd7d (patch)
tree12d22ceba0951d6e8351d46fbc845d354c3d7837 /AUTHORS
parent31249688487ca3a60f856ad082d4e84c4d5f79fb (diff)
downloadgo-git-266626211e40d1f2c3a34fa4cd2023f5310cbd7d.tar.gz
net/http: guarantee that the Transport dial functions are respected in js/wasm
The net/http package has a documented contract that if DialContext, DialDLSContext, Dial or DialTLS are specified in an instance of Transport, that they will be used to set up the connection. If they are not specified, then a reasonable fallback is made (e.g. using the net package). This is ordinarily true, except for when compiling for the js/wasm target, where the browser's Fetch API is preferred in all cases (except for when it is undefined/unavailable) and therefore the dial functions are all ignored. As a result, the http.Transport implementation under js/wasm doesn't meet that contract. This PR updates the RoundTrip behaviour of http.Transport so that if DialContext, DialTLSContext, Dial or DialTLS are specified, they are used as expected. The Fetch API will be used as a fallback if they are not specified. Fixes #27495 Change-Id: I88c6eb6ffdd077827b421d606f3e60ebdafd538f GitHub-Last-Rev: 948a0ed97ec4661f03cd346335f1d3d180f4c1ae GitHub-Pull-Request: golang/go#46923 Reviewed-on: https://go-review.googlesource.com/c/go/+/330852 Reviewed-by: Damien Neil <dneil@google.com> Trust: Damien Neil <dneil@google.com> Trust: Carlos Amedee <carlos@golang.org> Run-TryBot: Damien Neil <dneil@google.com> TryBot-Result: Go Bot <gobot@golang.org>
Diffstat (limited to 'AUTHORS')
-rw-r--r--AUTHORS1
1 files changed, 1 insertions, 0 deletions
diff --git a/AUTHORS b/AUTHORS
index 8d8d83605e..ad907967b4 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -1015,6 +1015,7 @@ Nathan Youngman <git@nathany.com>
Nathaniel Cook <nvcook42@gmail.com>
Naveen Kumar Sangi <naveenkumarsangi@protonmail.com>
Neelesh Chandola <neelesh.c98@gmail.com>
+Neil Alexander <neilalexander@neilalexander.dev>
Neil Lyons <nwjlyons@googlemail.com>
Netflix, Inc.
Neuman Vong <neuman.vong@gmail.com>