ObjectWeb Consortium
Search ObjectWeb Mail Archive: 

Advanced Search - Powered by Google


Mail Archive Home | proactive List | April 2006 Index

<--  Date Index  --> <--  Thread Index  -->

Re: [proactive] Re: Monitoring the Futures: Monitoring Active Objets to detect futures that will stay awaited forever



> a frist one to monitor a vector of futures:
>    ProActive.monitorFutures(vectorOfFutures);

That idea is good. To keep the same method name with overloading as usual, it should mostlikely be:
        ProActive.setFutureForMonitoring(vectorOfFutures);

>
> and a second one to get the index of the first future failed and remove
> it from the vector:
>    int indexOfFailedFuture = ProActive.getMonitoredFailedFutureAnd
> RemoveIt(vectorOfFutures);

This one is not so clear as it says RemoveIt and also returns an index.

My feeling is that we should decoupled things:
- when a future is monitored, it provides the guaranty that it will be filled 
up
  with an exception if the target AO died.

Then it is up to the user to use other mechanisms to achieve proper action.
For instance, using NFE to have a handler.

On top of the basic API above, then we can write structured that are fully managed; like the API suggested above by Alexandre which seems to manage the vector as it might remove future from it.

Just a thought,
Denis



Alexandre di Costanzo wrote:
On Thu, 2006-04-13 at 17:27 +0200, Denis Caromel wrote:
Monitoring the futures:

It seems there are needs in several applications to monitor Active Objects: especially make sure an AO is still alive when one is having one or several futures being expected from it.

In some cases, for reactivity reason, it might be important to detect "as soon as possible" that one has failed (building something relying on a DGC might not be an option because of a too long general TTU). Such problem was raised by users at Supelec.

So we are considering various options to achieve that:

- Active Object Monitoring:
   A pattern put together by Ludovic Henrio and Virginie Legrand.
   Main idea: an AO is monitoring a set of active objects. Upon an AO 
failure, it
   returns in a dedicated future the failed AO.

- A general mechanism allowing to have a hidden thread in ProActive 
monitoring a
   set of future.
   For instance, a future could be set for monitoring with a static call:
       ProActive.setFutureForMonitoring(fut);
   if the AO supposed to return a future being monitored seems to have failed,
   the future is filled up (no longer awaited) with:
        - an exception indicating the failed AO, etc.

   Note that this mechanism should be compatible with Automatic Continuation
   (forwarding the failure to other AOs expecting the same future value).

   We could also have an API:
      ProActive.setFutureForMonitoringAll();
   that will monitor all futures being created by an AO, and
      ProActive.setFutureForMonitoringTTU(x ms);
   to configurate the frequency of monitoring.

                         ----------------------------

Those two solutions are not incompatible, and could fit specific needs.

Potentially to be thought about is also a mechanism for activating the monitoring of AO.

We are planning to discuss those issues soon.
Please send us suggestions and comments,
Regards,
Denis, Francoise, Ludovic, Virginie

It is really what I need for the Branch and Bound API.

For the moment I manage a Vector of Futures. I have to frequently ping
workers with a one-way call to check if the active object is still
alive. When I detect a worker down, I remove its future in my Vector,
etc.

That is why I suggest an another method for monitoring futures:

a frist one to monitor a vector of futures:
        ProActive.monitorFutures(vectorOfFutures);

and a second one to get the index of the first future failed and remove
it from the vector:
        int indexOfFailedFuture = ProActive.getMonitoredFailedFutureAnd
RemoveIt(vectorOfFutures);

Alexandre


------------------------------------------------------------------------





--
   Denis Caromel mailto:caromel@xxxxxxxx   Tel.: +33 4 92 38 76 31  Fax: 76 44
   Professor                               http://www.inria.fr/oasis/caromel
   IUF, Institut universitaire de France
   Univ. de Nice Sophia Antipolis          INRIA, 2004 Rt. des Lucioles,  BP 
93
   OASIS, INRIA - I3S CNRS - UNSA          F-06902 Sophia Antipolis Cedex



<--  Date Index  --> <--  Thread Index  -->

Reply via email to:

Powered by MHonArc.

Copyright © 1999-2005, ObjectWeb Consortium | contact | webmaster.