add thread monitor for optimize thread pool dynamically