use semaphore for workers