vlad
vlad

Reputation: 15

Sense of Hystrix thread pool

Why Hystrix choose to use thread pool for executing http requests?

I realize that Hystrix thread pool is separate from application thread pool, but anyway.

I already read about isolation, separate resource management and so on. But still not totally understood the benefits of using separate thread pool for this purpose.

Isn't it be better and effective to implement fault tolerance patterns in Hystrix without it?

Predefined thread pool still consumes some app resources.

For example, when thread that processes some request (for example in a Spring Boot application) want to call http request using Hystrix, then Hystrix internally uses another thread from its thread pool, while the parent thread can wait for its response (i.e. 2 threads are doing same task). Wouldn't it be more effective if this thread will be used used for example for incoming requests handling while Hystrix would be implemented via some simple counters and blocks for example? And if the request should be executed asynchronously - then simply manually run a new thread.

Upvotes: 0

Views: 102

Answers (0)

Related Questions