[Zope] asynchronous task

Andreas Jung Andreas Jung <andreas@andreas-jung.com>
Wed, 16 Jul 2003 14:50:36 +0200


--On Mittwoch, 16. Juli 2003 14:36 Uhr +0200 Florian Reiser 
<florian.reiser@ra-bc.de> wrote:

> Hi folks,
>
> I need to compute large pdf-files on the fly.
> Can somebody plz tell me how I can start the asynchronous computation of
> the pdf, display the user a waiting form
> and show him the results after the asynchronous computation has
> finished.
>
>

I would dispatch all long-running actions to a dedicated instance of some
"worker" class that gets a request to "do something", starts this job
a thread or external process and keeps track of the progress. Such a 
"worker"
can handle multiple requests at the same time so you return an ID to the 
caller.
Then you can create your own "please wait" page based on the progress
information returned from the "worker" instance..,...that's the theory :-)

-aj