[racket] Continue: reentrant promises and custodian suicides

From: Dominic Pearson (lists at technoanimal.net)
Date: Thu Jul 14 10:31:18 EDT 2011

Hello folks!

I have been writing an application in Racket using Continue, and have
been stress testing it in the early development phase using `siege', to
see if it is suitable for future heavy lifting.

Under high load I get some very odd messages. Requests sometimes fail
with

	force: reentrant promise fun-p

and sometimes Racket just stalls and refuses to accept any additional
requests with the message

	thread: the custodian has been shut down: #<custodian>

which is the more serious of the two since it seems impossible to
recover from.

I am not using any fancy features, have quite decent amounts of RAM 
and CPU, am using few libraries (db.plt, neil/json-parsing and
dherman/json) -- indeed, the server itself has the primary goal of
accepting JSON posted to it, decoding it, optionally grabbing data
from a database, and constructing a JSON response -- not using
continuations or any such stuff. I seem to be able to hit these errors
quite regularly under heavy load and Ḯ'm not knowledgeable enough
about Racket internals to pin it down.

Any information would be greatly appreciated!

Cheers,
Dominic


Posted on the users mailing list.