Added ability to use SmartThreadPool