jgroup.relacs.gm
Class LeaseLayer

java.lang.Object
  extended by jgroup.relacs.gm.LeaseLayer
All Implemented Interfaces:
java.lang.Runnable, Layer, LeaseService

public class LeaseLayer
extends java.lang.Object
implements LeaseService, java.lang.Runnable

The LeaseLayer implements a lease based refresh mechanism towards the dependable registry. This layer must be configured within a server group, allowing each server to perform refresh calls towards the dependable registry.

Since:
Jgroup 2.1
Author:
Henning Hommeland, Jo Andreas Lind, Hein Meling

Nested Class Summary
 
Nested classes/interfaces inherited from interface jgroup.core.Layer
Layer.FinalizeLayer
 
Field Summary
 
Fields inherited from interface jgroup.relacs.gm.LeaseService
DEFAULT_REFRESH_RATE
 
Method Summary
 void addListener(java.lang.Object listener)
          We obtain the refresh rate for the given server and start the lease refresh thread.
static LeaseLayer getLayer(RegistryService regs)
           
 void run()
          This method will execute in a new thread, started from the constructor.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getLayer

public static LeaseLayer getLayer(RegistryService regs)
                           throws java.rmi.RemoteException
Throws:
java.rmi.RemoteException

addListener

public void addListener(java.lang.Object listener)
We obtain the refresh rate for the given server and start the lease refresh thread.

Specified by:
addListener in interface Layer
Parameters:
listener - An Object representation of the listener interface. This will typically be cast to the appropriate listener interface type after checking the type with the instanceof operator.

run

public void run()
This method will execute in a new thread, started from the constructor. It will preform a refresh every refreshrate seconds.

Specified by:
run in interface java.lang.Runnable


Copyright © 1998-2006 The Jgroup/ARM development team. All Rights Reserved.