comp.lang.ada
 help / color / mirror / Atom feed
From: Jean-Pierre Rosen <rosen@adalog.fr>
Subject: Re: Starting a Task and Immediately Returning
Date: Fri, 14 Nov 2008 16:13:00 +0100
Date: 2008-11-14T16:13:00+01:00	[thread overview]
Message-ID: <th4kfg.u0g.ln@hunter.axlog.fr> (raw)
In-Reply-To: <811556bd-60c9-43c0-927d-0e5d093dcfbd@i18g2000prf.googlegroups.com>

Maciej Sobczak a �crit :
> On 14 Lis, 14:26, Graham Stark <graham.st...@virtual-worlds.biz>

>> But,
>> obviously, you can't wait 10 minutes to reply to a web request.
> 
> Then you need a task that will exist independently on Web_Callback.
> Make such a task (or even a whole bunch of them if that makes sense
> for this particular server) at the library level, which will give them
> independence on any scope. Add some facility for communicating to this
> task the description of what needs to be done (the "job") - for this
> you can use rendezvous or (better) job queue(s).
Or more simply, create the task with an allocator (new). The tricky 
thing will be to deallocate the tasks' space after it is terminated. Web 
server are generally expected to run 24/7, so no memory leak allowed...
-- 
---------------------------------------------------------
            J-P. Rosen (rosen@adalog.fr)
Visit Adalog's web site at http://www.adalog.fr



  reply	other threads:[~2008-11-14 15:13 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-14 13:26 Starting a Task and Immediately Returning Graham Stark
2008-11-14 13:41 ` Maciej Sobczak
2008-11-14 15:13   ` Jean-Pierre Rosen [this message]
2008-11-15 12:04     ` Samuel Tardieu
2008-11-15 15:53       ` sjw
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox