]> Cypherpunks repositories - gostls13.git/commit
net/http: add js/wasm compatible DefaultTransport
authorJohan Brandhorst <johan.brandhorst@gmail.com>
Wed, 30 May 2018 17:11:31 +0000 (17:11 +0000)
committerBrad Fitzpatrick <bradfitz@golang.org>
Wed, 30 May 2018 17:23:57 +0000 (17:23 +0000)
commitb12e341616365cafd6f7eab9aaaa29c4155c1a76
treed2693a24d03375fafeb14286d38783b8df2da259
parent31e1c30f55165785dd12e7c67babedeb950a721d
net/http: add js/wasm compatible DefaultTransport

Adds a new Transport type for the js/wasm target that uses the
JavaScript Fetch API for sending HTTP requests. Support for
streaming response bodies is used when available, falling back
to reading the entire response into memory at once.

Updates #25506

Change-Id: Ie9ea433a1a2ed2f65b03c6cc84a16e70c06fcf5c
GitHub-Last-Rev: 6df646745b8e0474781f4b1a3084536e573e8e8c
GitHub-Pull-Request: golang/go#25550
Reviewed-on: https://go-review.googlesource.com/114515
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
src/go/build/deps_test.go
src/net/http/roundtrip.go [new file with mode: 0644]
src/net/http/roundtrip_js.go [new file with mode: 0644]
src/net/http/transport.go