queue with mutexes