From: Petr Baudis <pasky@suse.cz>
To: Junio C Hamano <junkio@cox.net>
Cc: Nick Hengeveld <nickh@reactrix.com>, git@vger.kernel.org
Subject: Re: [RFC] Timeouts on HTTP requests
Date: Wed, 19 Oct 2005 13:09:10 +0200 [thread overview]
Message-ID: <20051019110909.GO30889@pasky.or.cz> (raw)
In-Reply-To: <7voe5mgi3d.fsf@assigned-by-dhcp.cox.net>
Dear diary, on Wed, Oct 19, 2005 at 08:02:14AM CEST, I got a letter
where Junio C Hamano <junkio@cox.net> told me that...
> Nick Hengeveld <nickh@reactrix.com> writes:
>
> > Our QA department today checked what would happen if the network connection
> > went away completely in the middle of an HTTP transfer. It looks as though
> > the answer is that git-http-fetch sits there forever waiting for CURL to
> > return something.
>
> Ouch.
>
> > I'm thinking of taking advantage of CURL's capability of aborting a request
> > if the transfer rate drops below a threshold for a specified length of time
> > using a new pair of environment variables and/or config file settings:
> >
> > GIT_HTTP_LOW_SPEED_LIMIT/http.lowspeedlimit
> > GIT_HTTP_LOW_SPEED_TIME/http.lowspeedtime
> >
> > Does this make sense, and if so should there be defaults if nothing is
> > specified?
>
> I suspect these would be quite different between DSL and
> localnet, so I doubt if there is a reasonable default value to
> quick give-up.
>
> On the other hand, having _no_ activity for say 30 seconds would
> indicate a dead link on either modem or localnet.
I agree that we should definitely use timeout instead of some low speed
limit - can't curl do that?
But 30 seconds is too little (on bad links, I've seen TCP connections
stalled for much longer), I would use at least 120 seconds. Or perhaps
30 seconds, but retry three times or so.
--
Petr "Pasky" Baudis
Stuff: http://pasky.or.cz/
VI has two modes: the one in which it beeps and the one in which
it doesn't.
next prev parent reply other threads:[~2005-10-19 11:09 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-10-18 23:51 [RFC] Timeouts on HTTP requests Nick Hengeveld
2005-10-19 6:02 ` Junio C Hamano
2005-10-19 11:09 ` Petr Baudis [this message]
2005-10-19 15:34 ` Nick Hengeveld
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20051019110909.GO30889@pasky.or.cz \
--to=pasky@suse.cz \
--cc=git@vger.kernel.org \
--cc=junkio@cox.net \
--cc=nickh@reactrix.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).