multithreading - Difference between thread-isolated and semaphore-isolated calls -


i going through netflix opensource feature hystrix... saw statement "today tens of billions of thread-isolated, , hundreds of billions of semaphore-isolated calls executed via hystrix every day @ netflix"

would know difference between these different type of calls..

first need see different between thread , semaphore. in general, calling thread more expensive semaphore because of overhead. large number of requests/second, semaphore can considere.

secondly semaphore, command executed within thread of caller. means concurrent calls not isolated other (not when use thread).

lastly, semaphore, when there timeout, can't terminated (unless set up). if don't know client's behaviour ,then not nice thing have.


Comments