SERVER-13498: move some command locking into Command::run