Rio Project 4.2 API Documentation



org.rioproject.sla
Class RedeployPolicyHandler

java.lang.Object
  extended by org.rioproject.sla.SLAPolicyHandler
      extended by org.rioproject.sla.RedeployPolicyHandler
All Implemented Interfaces:
ThresholdListener

public class RedeployPolicyHandler
extends SLAPolicyHandler

The RedeployPolicyHandler will redeploy a service based on declared thresholds.

Author:
Dennis Reedy

Field Summary
 
Fields inherited from class org.rioproject.sla.SLAPolicyHandler
context, eventSource, initialized, thresholdManager
 
Constructor Summary
RedeployPolicyHandler(SLA sla)
          Construct a RedeployPolicyHandler
 
Method Summary
 void disconnect()
          Override parent's method to shutdown timer
 String getDescription()
          Override parent's method to return description for this SLA Handler
 void notify(Calculable calculable, ThresholdValues thresholdValues, int type)
          Notify for a threshold event
 void setSLA(SLA sla)
          Set or update the SLA
 
Methods inherited from class org.rioproject.sla.SLAPolicyHandler
getConfiguration, getEventSource, getID, getName, getSLA, getThresholdManager, initialize, notifyListeners, registerListener, sendSLAThresholdEvent, setName, setThresholdManager, unregisterListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RedeployPolicyHandler

public RedeployPolicyHandler(SLA sla)
Construct a RedeployPolicyHandler

Parameters:
sla - The SLA for the RedeployPolicyHandler
Method Detail

getDescription

public String getDescription()
Override parent's method to return description for this SLA Handler

Overrides:
getDescription in class SLAPolicyHandler
Returns:
The descriptive attribute for this SLA Handler

disconnect

public void disconnect()
Override parent's method to shutdown timer

Overrides:
disconnect in class SLAPolicyHandler

setSLA

public void setSLA(SLA sla)
Description copied from class: SLAPolicyHandler
Set or update the SLA

Overrides:
setSLA in class SLAPolicyHandler
Parameters:
sla - The SLA

notify

public void notify(Calculable calculable,
                   ThresholdValues thresholdValues,
                   int type)
Description copied from interface: ThresholdListener
Notify for a threshold event

Specified by:
notify in interface ThresholdListener
Overrides:
notify in class SLAPolicyHandler
Parameters:
calculable - The current metric
thresholdValues - The current thresholds
type - The type of threshold event, breached or cleared
See Also:
ThresholdListener.notify(org.rioproject.watch.Calculable, org.rioproject.watch.ThresholdValues, int)

Copyright © Rio Project.

Copyright © 2006-2011 Rio Project. All Rights Reserved.