Better handling of the fetch operation, to avoid 100% CPU usage while waiting for the completion handler call

Using a BOOL sentinel uses 100% CPU while waiting. Using a semaphore fixes this problem.