org.apache.directory.server.ldap.replication.consumer
Class PingerThread

java.lang.Object
  extended by java.lang.Thread
      extended by org.apache.directory.server.ldap.replication.consumer.PingerThread
All Implemented Interfaces:
Runnable

public class PingerThread
extends Thread

A thread used to ping the provider o check if they are alive or not.

Author:
Apache Directory Project

Nested Class Summary
 
Nested classes/interfaces inherited from class java.lang.Thread
Thread.State, Thread.UncaughtExceptionHandler
 
Field Summary
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
PingerThread()
          Create a new instance of this thread.
 
Method Summary
 void addConsumer(ReplicationConsumer consumer)
          Add a new consumer to ping
 void removeConsumer(ReplicationConsumer consumer)
          Remove a consumer to ping
 void run()
          Starts the thread
 void stopPinging()
          Stops the ping for all the consumers
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

PingerThread

public PingerThread()
Create a new instance of this thread.

Method Detail

run

public void run()
Starts the thread

Specified by:
run in interface Runnable
Overrides:
run in class Thread

addConsumer

public void addConsumer(ReplicationConsumer consumer)
Add a new consumer to ping

Parameters:
consumer - The consumer we want to ping

removeConsumer

public void removeConsumer(ReplicationConsumer consumer)
Remove a consumer to ping

Parameters:
consumer - The consumer we want to remove

stopPinging

public void stopPinging()
Stops the ping for all the consumers



Copyright © 2003-2013 The Apache Software Foundation. All Rights Reserved.