added some lines for output. It now states when killing thread and total number of retries in standard out.