9
I'm having a system with hundreds of threads. Most of the thread are sleeping or waiting in a given time but they can wake up whenever they like. I would like to reduce the number of OS threads that are dedicated to my system. Do you know about a simple way of doing it? For example, is there a thread pool package that whenever a thread moves to sleep mode, it stores the state and kill the thread. whenever it wakes up, it starts new thread with the state of the old one.
Thanks