com.hazelcast.spi.impl.operationexecutor.classic
Class ResponseThread

java.lang.Object
  extended by java.lang.Thread
      extended by com.hazelcast.spi.impl.operationexecutor.classic.ResponseThread
All Implemented Interfaces:
OperationHostileThread, Runnable

public final class ResponseThread
extends Thread
implements OperationHostileThread

The ResponseThread is responsible for processing responses-packets. So when a response is received from a remote system, it is put in the workQueue of the ResponseThread. Then the ResponseThread takes it from this workQueue and calls the ResponsePacketHandler for the actual processing. The reason that the IO thread doesn't immediately deals with the response is that deserializing the Response and let the invocation-future deal with the response can be rather expensive currently. This class needs to implement the OperationHostileThread interface to make sure that the OperationExecutor is not going to schedule any operations on this task due to retry.


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
ResponseThread(HazelcastThreadGroup threadGroup, ILogger logger, ResponsePacketHandler responsePacketHandler)
           
 
Method Summary
 void run()
           
 void shutdown()
           
 
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

ResponseThread

public ResponseThread(HazelcastThreadGroup threadGroup,
                      ILogger logger,
                      ResponsePacketHandler responsePacketHandler)
Method Detail

run

public void run()
Specified by:
run in interface Runnable
Overrides:
run in class Thread

shutdown

public void shutdown()


Copyright © 2015 Hazelcast, Inc.. All Rights Reserved.