fixing threadpool