org.objectweb.jonas.server.discovery
Class DiscoveryComm

java.lang.Object
  extended byorg.objectweb.jonas.server.discovery.DiscoveryComm
All Implemented Interfaces:
java.lang.Runnable

public class DiscoveryComm
extends java.lang.Object
implements java.lang.Runnable

Version:
1.0
Author:
Takoua Abdellatif

Constructor Summary
DiscoveryComm(DiscoveryManager dm)
           
 
Method Summary
 DiscEvent createNotifMessage(java.lang.String state)
           
 void run()
           
 void sendNotif(DiscEvent msg)
          sends a notification message to the server group.
 void stop()
          sends a notification message to notify that the server is stopping.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DiscoveryComm

public DiscoveryComm(DiscoveryManager dm)
Method Detail

sendNotif

public void sendNotif(DiscEvent msg)
sends a notification message to the server group.


createNotifMessage

public DiscEvent createNotifMessage(java.lang.String state)
                             throws java.lang.Exception
Parameters:
state - takes either RUNNING or STOPPING values in the case of a notification service, depending on the server state.
Returns:
a Discovery notification
Throws:
java.lang.Exception - is thrown if the jmx service is not reached.

run

public void run()
Specified by:
run in interface java.lang.Runnable
See Also:
Runnable.run()

stop

public void stop()
sends a notification message to notify that the server is stopping.