Use mutex to make completion check threadsafe