AW: [Zope] asynchronous task

Florian Reiser florian.reiser@ra-bc.de
Wed, 16 Jul 2003 15:46:54 +0200


Hi Andreas,

thanks for your suggestion,
could you plz give me a point to start from
I want to save the results of the thread in a session variable.

Could you plz give me a fake example?

Regards
Florian Reiser

-----Urspr=FCngliche Nachricht-----
Von: Andreas Jung [mailto:andreas@andreas-jung.com]=20
Gesendet: Mittwoch, 16. Juli 2003 14:51
An: florian.reiser@ra-bc.de; 'Zope-allgemein'
Betreff: Re: [Zope] asynchronous task




--On Mittwoch, 16. Juli 2003 14:36 Uhr +0200 Florian Reiser=20
<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=20
> of the pdf, display the user a waiting form and show him the results=20
> 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