orca.shirako.kernel
Class BrokerPolicyRecoverer

java.lang.Object
  extended by orca.shirako.kernel.BrokerPolicyRecoverer

public class BrokerPolicyRecoverer
extends java.lang.Object


Field Summary
protected  IBroker actor
          Actor the mapper belongs to.
protected  ReservationSet clientExtendingTicket
          A set of reservations for which the agent needs to extend tickets.
protected  ReservationSet clientTicketing
          A set of reservations for which the agent needs to obtain tickets.
protected  ReservationSet closing
          A set of reservations to be closed after recovery.
protected  ReservationSet extending
          Recovered reservations that need to extend tickets Populated during revisit.
protected  LoggingTool logger
          Logger.
protected  IBrokerPolicy policy
          Mapper to be recovered.
protected  ReservationSet ticketing
          Recovered reservations that need to obtain tickets.
 
Constructor Summary
BrokerPolicyRecoverer(IBrokerPolicy mapper, IBroker actor)
          Creates a new instance.
 
Method Summary
protected  void issueClientExtending()
          Issues a ticket extend request for all reservations that the recovery process has selected for (re)requesting a ticket extend.
protected  void issueClientTicketing()
          Issues a tickets request for all reservations that the recovery process has selected for (re)requesting a new ticket.
protected  void issueClosing()
          Closes all reservations that the recovery process has selected for closing.
protected  void issueExtending()
          Runs the ticket issuing policy for all reservations that the recovery process has determined that they have been in the process of requesting a new ticket.
protected  void issueTicketing()
          Runs the ticket issuing policy for all reservations that the recovery process has determined that they have been in the process of requesting a new ticket.
protected  java.lang.String printState(IReservation res)
          Converts the reservation to a state string.
 void reset()
          Post-recovery entry point
 void revisit(ResourceReservation reservation)
          Recovers the state of a single reservation.
protected  void revisitClient(ReservationClient r)
          Performs recovery for ReservationClients
protected  void revisitServer(BrokerReservation r)
          Performs recovery for BrokerReservations
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

policy

protected IBrokerPolicy policy
Mapper to be recovered.


actor

protected IBroker actor
Actor the mapper belongs to.


logger

protected LoggingTool logger
Logger.


ticketing

protected ReservationSet ticketing
Recovered reservations that need to obtain tickets. Populated during revisit. Emptied and set to null during reset.


extending

protected ReservationSet extending
Recovered reservations that need to extend tickets Populated during revisit. Emptied and set to null during reset.


closing

protected ReservationSet closing
A set of reservations to be closed after recovery. This field is cleared and set to null after reset() completes.


clientExtendingTicket

protected ReservationSet clientExtendingTicket
A set of reservations for which the agent needs to extend tickets. This field is cleared and set to null after reset() completes.


clientTicketing

protected ReservationSet clientTicketing
A set of reservations for which the agent needs to obtain tickets. This field is cleared and set to null after reset() completes.

Constructor Detail

BrokerPolicyRecoverer

public BrokerPolicyRecoverer(IBrokerPolicy mapper,
                             IBroker actor)
Creates a new instance.

Parameters:
mapper - mapper to recover
actor - actor the mapper belongs to
Method Detail

revisit

public void revisit(ResourceReservation reservation)
             throws java.lang.Exception
Recovers the state of a single reservation.

Parameters:
reservation - reservation to recover
Throws:
java.lang.Exception

printState

protected java.lang.String printState(IReservation res)
Converts the reservation to a state string.

Parameters:
res - reservation
Returns:
state string representing the reservation

revisitServer

protected void revisitServer(BrokerReservation r)
                      throws java.lang.Exception
Performs recovery for BrokerReservations

Parameters:
r - reservation to recover
Throws:
java.lang.Exception

revisitClient

protected void revisitClient(ReservationClient r)
                      throws java.lang.Exception
Performs recovery for ReservationClients

Parameters:
r - reservation to recover
Throws:
java.lang.Exception

reset

public void reset()
           throws java.lang.Exception
Post-recovery entry point

Throws:
java.lang.Exception

issueTicketing

protected void issueTicketing()
Runs the ticket issuing policy for all reservations that the recovery process has determined that they have been in the process of requesting a new ticket.


issueClientTicketing

protected void issueClientTicketing()
Issues a tickets request for all reservations that the recovery process has selected for (re)requesting a new ticket.


issueClosing

protected void issueClosing()
Closes all reservations that the recovery process has selected for closing.


issueExtending

protected void issueExtending()
Runs the ticket issuing policy for all reservations that the recovery process has determined that they have been in the process of requesting a new ticket.


issueClientExtending

protected void issueClientExtending()
Issues a ticket extend request for all reservations that the recovery process has selected for (re)requesting a ticket extend.



Copyright © 2007 Network/Internet Computing Lab. All Rights Reserved.