Add call to pool.terminate