Added a pid property to the thread worker so that the pool will work.