I'm working on a Java daemon that requires concurrency: an infinite loop that listens on a job queue (redis) and distributes each job to a worker. The worker doesn't necessarily have to return a value.
I found Executors pretty useful and I am using a ThreadPoolExecutor to maintain a number of worker threads.
Though, those workers run 3rd party code which needs to run as isolated as possible, avoiding sharing static properties.
My question: is there any Java library/framework that provides features similar to Executors, like:
- worker pools
- automatically adjusted pool size
..but spawning processes instead of threads?