fix thread pool