From: Jason Foster <jafoster@uw...> - 2002-03-06 01:26:13
The Apache Cocoon project is currently looking at possible implementations
for web application programming. One of its goals is to avoid state
machine model, and to instead use a model that is loosely based on
continuations. The goal is something like:
1 - request comes in for the web application (.py)
2 - Cocoon launches Jython and executes the script
3 - the script requests a response of the user
3a - Cocoon saves the current state of the script
3b - Cocoon associates the saved state with an ID
3c - Cocoon sends a web page to the user with the ID encoded somehow
... time passes ...
3d - The user sends a new request with an embedded ID
3e - Cocoon retrieves the saved state of the script
3f - Cocoon sets the value of some variables in the script
3f - Cocoon restarts the script
4 - the script carries on
I'm wondering whether Jython currently supports this kind of behaviour? I
get the impression that it might, but I figure someone on this list will
know for sure. If Jython doesn't do this now, is it the kind of thing
that it might support in the future?
Thanks for your assistance!
P.S. I'm in digest mode, so if you would like an immediate reply, please
cc me on any replies to the list. Thanks!
> I'm wondering whether Jython currently supports this kind of behaviour? I
> get the impression that it might,
> but I figure someone on this list will
> know for sure.
> If Jython doesn't do this now, is it the kind of thing
> that it might support in the future?
very unlikely. We will support 1-frame-depth
generators, don't know if they are enough
for your purposes.
a scheme implementation doesn't
(now it supports only "up-ward" continuations) but
it seems will (although I don't
know under which restrictions).
regards, Samuele Pedroni.