Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

net/http: client `Expect: 100-continue` docs not clear #16003

Closed
ncw opened this issue Jun 8, 2016 · 1 comment

Comments

Projects
None yet
5 participants
@ncw
Copy link
Contributor

commented Jun 8, 2016

It doesn't actually say in the docs that you MUST set ExpectContinueTimeout in order for the Expect: 100-continue mechanism to work. See later for test programs which make me think this is so.

Here are what the docs say at the moment.

    // ExpectContinueTimeout, if non-zero, specifies the amount of
    // time to wait for a server's first response headers after fully
    // writing the request headers if the request has an
    // "Expect: 100-continue" header. Zero means no timeout.
    // This time does not include the time to send the request header.
    ExpectContinueTimeout time.Duration

What version of Go are you using (go version)?

go version devel +3c6b668 Thu Jun 2 00:22:03 2016 +0000 linux/amd64

What operating system and processor architecture are you using?

GOARCH="amd64"
GOBIN=""
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/home/ncw/Code/Go"
GORACE=""
GOROOT="/home/ncw/Code/go"
GOTOOLDIR="/home/ncw/Code/go/pkg/tool/linux_amd64"
CC="gcc"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build375906555=/tmp/go-build -gno-record-gcc-switches"
CXX="g++"
CGO_ENABLED="1"

What did you do?
What did you expect to see?
What did you see instead?

Here are some examples demonstrating that you need to set ExpectContinueTimeout

@gopherbot

This comment has been minimized.

Copy link

commented Oct 22, 2016

CL https://golang.org/cl/31723 mentions this issue.

@gopherbot gopherbot closed this in ece4e23 Oct 22, 2016

@golang golang locked and limited conversation to collaborators Oct 22, 2017

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.