
public class HystrixThreadEventStream
extends java.lang.Object
HystrixThreadPool.
However, many situations arise where a single thread may serve many different commands. Examples include:
* Application caller threads (semaphore-isolated commands, or thread-pool-rejections)
* Timer threads (timeouts or collapsers)
I don't think that a thread-level view is an interesting one to consume (I could be wrong), so at the moment there is no public way to consume it. I can always add it later, if desired.
Instead, this stream writes to the following streams, which have more meaning to metrics consumers:
Also note that any observers of this stream do so on the thread that writes the metric. This is the command caller thread in the SEMAPHORE-isolated case, and the Hystrix thread in the THREAD-isolated case. I determined this to be more efficient CPU-wise than immediately hopping off-thread and doing all the metric calculations in the RxComputationThreadPool.| Modifier and Type | Method and Description |
|---|---|
void |
collapserBatchExecuted(HystrixCollapserKey collapserKey,
int batchSize) |
void |
collapserResponseFromCache(HystrixCollapserKey collapserKey) |
void |
commandExecutionStarted(HystrixCommandKey commandKey,
HystrixThreadPoolKey threadPoolKey,
HystrixCommandProperties.ExecutionIsolationStrategy isolationStrategy,
int currentConcurrency) |
void |
executionDone(ExecutionResult executionResult,
HystrixCommandKey commandKey,
HystrixThreadPoolKey threadPoolKey) |
static HystrixThreadEventStream |
getInstance() |
void |
shutdown() |
java.lang.String |
toString() |
public static HystrixThreadEventStream getInstance()
public void shutdown()
public void commandExecutionStarted(HystrixCommandKey commandKey, HystrixThreadPoolKey threadPoolKey, HystrixCommandProperties.ExecutionIsolationStrategy isolationStrategy, int currentConcurrency)
public void executionDone(ExecutionResult executionResult, HystrixCommandKey commandKey, HystrixThreadPoolKey threadPoolKey)
public void collapserResponseFromCache(HystrixCollapserKey collapserKey)
public void collapserBatchExecuted(HystrixCollapserKey collapserKey, int batchSize)
public java.lang.String toString()
toString in class java.lang.Object