|  | setStatus(NodeStatus::IDLE); | 
    
   
 
Often actionclients can stop at once if they are asked to (like calculating fibonacci numbers).
But somethings it takes time to cleanup (PREEMPTING state). Like writing large files, getting to a safe state.
I would say the NodeStatus should only be idle when the state is PREEMPTED, not PREEMPTING.

source