Re: Continuation based app servers



On May 31, 2:33 pm, Pascal Bourguignon <p...@xxxxxxxxxxxxxxxxx> wrote:
Slava Akhmechet <coffee...@xxxxxxxxx> writes:
Here is what I want to support:

(defun authenticatedp ()
(if *authenticatedp*
t
(do-modal #'login-or-register)))

(defun some-action ()
(when (authenticatedp)
(do-action)))

The key is 'do-modal' - a construct that shows a login page (which can
manage rounds of user interaction), and returns the result of the
login operation as if it were a simple function call.

I don't need continuations to achieve this functionality. The trick,
saving the stack, can be done with threads. Whenever 'do-modal' is
called, it can spawn a thread and assign it to the current
session. All interaction will then be executed by that thread while
'do-modal' blocks the original thread and waits for some signal from
the new one.

It can work.

The problem you have is that there is a limited number of threads
possible in a process (around 300 or 400). Therefore you can handle
only a limited number of concurent modal sessions (around 150 or 200
if you call recursively do-modal only once per session).

--
__Pascal Bourguignon__ http://www.informatimago.com/

NOTE: The most fundamental particles in this product are held
together by a "gluing" force about which little is currently known
and whose adhesive power can therefore not be permanently
guaranteed.- Hide quoted text -

- Show quoted text -

Slightly out of topic , how do you handle number of concurrent
threads. (Purely theoretical) I was thinking of something like
prespecified maximum number slots and a waiting list .

.



Relevant Pages

  • Re: Count visitors on my website
    ... logged in" in the original post ... without any user interaction. ... of his monitor and his session would still be open. ... You can only go on the connections. ...
    (comp.lang.php)
  • Re: Count visitors on my website
    ... logged in" in the original post ... without any user interaction. ... of his monitor and his session would still be open. ... JDS Computer Training Corp. ...
    (comp.lang.php)
  • Re: Starting a program before login
    ... You can use SRVANY from the Resource Kit to run executables as a service, ... and optionally allow user interaction in a session. ... You can schedule a task ...
    (microsoft.public.windows.server.general)
  • Re: This doesnt "set" a cookie to expire - why?
    ... Cookies will not be deleted before the ... considered the end of the session regarding cookies ... Usually user interaction will initially cause it to end, ... Let's keep "session" where it is usefull, on the server. ...
    (comp.lang.javascript)