[plt-scheme] Re: Weird timeouts in web-server

From: Jay McCarthy (jay.mccarthy at gmail.com)
Date: Mon Nov 16 17:08:09 EST 2009

I've updated this to INCREMENT the timeout, rather than RESET it.


On Mon, Nov 16, 2009 at 2:54 PM, N N <nothere44 at gmail.com> wrote:
> I solved my own problem.  Here's what caused it:
> web-server/http/request.ss, line 39.  This is in the function read-request.
>  When it reads a POST request, it changes the timeout of whatever connection
> the request was sent over to be Content Length seconds later.  I'm not sure
> when it makes sense to do this, but in my case with a very short request
> (Like doit="Go") calling an expensive operation this caused it to timeout.
>  I've now copied web-server code to a personal collection where I just
> commented this line out.
> ~NT
> On Mon, Nov 16, 2009 at 12:32 PM, N N <nothere44 at gmail.com> wrote:
>> With initial-connection-timeout set to 300 (5 minutes) I'm still getting
>> some deaths due to timeouts, and am at a loss.  I've hunted through
>> server code to try to figure out what is going on, but not with much
>> success.  Here is what is happening: I navigate to a page with a form.
>>  I click on submit for that form and it's intercepted by JavaScript to
>> send off to the server in the background a la AJAX and displays the
>> results when they return.  Now, I would expect that this background
>> submission has the full 5 minutes to complete (and if the time is
>> exceeded, it seems from my tests with a 30-second timeout to retry the
>> request once with the new connection and full timeout: if you could
>> point me to where the logic that does this is I'd be grateful).
>> However, in practice it is at times ended much more quickly (54 and 27
>> seconds seem the norm) and continues to die to timeouts in the same
>> timespan when resubmitted (which seems to me to indicate the time is
>> captured in the k-url of the form's action in some way, except that
>> the kill-time is stored as an absolute not an offset).
>> (It shouldn't matter, but we are using our own LRU continuation
>> manager that only differs in that not at maximum memory continuations
>> only live for 10 minutes and at maximum 2 minutes.)
>> Any insights are appreciated,
>> ~NT
> _________________________________________________
>  For list-related administrative tasks:
>  http://list.cs.brown.edu/mailman/listinfo/plt-scheme

Jay McCarthy <jay at cs.byu.edu>
Assistant Professor / Brigham Young University

"The glory of God is Intelligence" - D&C 93

Posted on the users mailing list.