[plt-scheme] Web Server Port Query (v371)

From: Noel Welsh (noelwelsh at gmail.com)
Date: Tue Apr 15 12:50:19 EDT 2008

On Tue, Apr 15, 2008 at 5:21 PM, Eric Domeshek
<domeshek at stottlerhenke.com> wrote:
> Am I correct that I don't HAVE to specify the #:port argument here, but
> could leave it to be managed by the config.scm file?

I believe so, but it has been a while since I wrote this kind of code.

> In v371, the only problem I've seen (beyond growing memory consumption from
> continuation management) is that sometimes the server gets running in some
> kind of loop that pegs the processor near 100% utilization (but it remains
> responsive to further requests).  Do you think v372 would fix that issue?

Quite possibly.  Back when we started developing for the web server
there was a fairly serious bug (an allocating infinite loop) that
could well lead to the behaviour you describe.  Have you tried running
the server for an extended period of time?  If it runs out of memory
and crashes it is probably that bug.

(Additionally, the LRU manager gives much better control over
continuations than the timeout manager, and I recommend using it
regardless of the version of PLT you run.)

>  ...  I'm not
> sure what the "#:listen-ip #f" argument to configuration-table->web-config@
> above is doing.

It probably tells the web server to listen on all available IP
addresses.  If you set it to, say, "127.0.0.1" the web server would
only listen to connects sent to this address, which in this case is
the loopback / localhost.

N.


Posted on the users mailing list.