added timeout/retry logic for cwbquery multithreading block