Constructor and Description |
---|
WatchdogGroup(String name,
long timeout,
int timeoutResolution,
com.gigaspaces.lrmi.nio.watchdog.TimeoutObserver observer)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
Watchdog.WatchedObject |
addIdleWatch(ConnectionResource client)
Add CPeer to the watched objects (idle group)
|
Watchdog.WatchedObject |
addRequestWatch(SocketChannel sock,
ConnectionResource client)
Add given socket to the watched objects (request group)
|
Watchdog.WatchedObject |
addResponseWatch(SocketChannel sock,
ConnectionResource client)
Add given socket and cpeer to the watched objects (response group)
|
protected void |
fireTimeoutOccured(Map<Watchdog.WatchedObject,Collection<Watchdog.WatchedObject>> watchedObjects)
Fire timeout event about the watched object to the TimeoutObserver
|
long |
getTimeout() |
void |
removeWatch(Watchdog.WatchedObject watched)
Remove given watched object from watch .
|
public WatchdogGroup(String name, long timeout, int timeoutResolution, com.gigaspaces.lrmi.nio.watchdog.TimeoutObserver observer)
timeout
- watchdog group timeout in millisecondstimeoutResolution
- in percentsprotected void fireTimeoutOccured(Map<Watchdog.WatchedObject,Collection<Watchdog.WatchedObject>> watchedObjects) throws Exception
Exception
TimeoutObserver
,
Watchdog.WatchedObject
public Watchdog.WatchedObject addRequestWatch(SocketChannel sock, ConnectionResource client)
sock
- socketpublic Watchdog.WatchedObject addResponseWatch(SocketChannel sock, ConnectionResource client)
sock
- socketpublic Watchdog.WatchedObject addIdleWatch(ConnectionResource client)
public void removeWatch(Watchdog.WatchedObject watched)
public long getTimeout()
Copyright © GigaSpaces.