dead code removal, add mutex to manager