fix(engine): Clear UnitState before Job target

The rest of the cluster reacts to clearing the Job target, so we must
clear the UnitState first to prevent race conditions.