Skip to content
This repository has been archived by the owner on Aug 31, 2018. It is now read-only.

fix issue #116 #121

Closed
wants to merge 1 commit into from
Closed

fix issue #116 #121

wants to merge 1 commit into from

Conversation

Antman2023
Copy link

Is it easy way to fix #116?

@marcosnils
Copy link
Member

@pathletboy haven't had the time look at it, but at a first glance tests are failing.

@Antman2023
Copy link
Author

type *http.Client has no field or method Timeout in go1.2, go1.5.1 passed.

@sschepens
Copy link
Contributor

@pathletboy this is not good, it adds yet another race condition to goreq. This is setting the default client's timeout. We have similar issues now, and i'm not happy about them.
If two requests were made concurrently then there is a chance that one would step over the previous value of timeout before the first request actually starts.

@marcosnils marcosnils closed this Jan 25, 2016
@marcosnils
Copy link
Member

@sschepens we were already having race conditions with the previous timeout implementation. I've moved our strategy to golang default timeout method. This will be automatically resolved when / if we decide what to do with current race conditions.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

goreq.Request.Timeout behavior is different from http.Client.Timeout
3 participants