• Michael Schurter's avatar
    client: ensure task is cleaned up when terminal · db9daf66
    Michael Schurter authored
    This commit is a significant change. TR.Run is now always executed, even
    for terminal allocations. This was changed to allow TR.Run to cleanup
    (run stop hooks) if a handle was recovered.
    
    This is intended to handle the case of Nomad receiving a
    DesiredStatus=Stop allocation update, persisting it, but crashing before
    stopping AR/TR.
    
    The commit also renames task runner hook data as it was very easy to
    accidently set state on Requests instead of Responses using the old
    field names.
    db9daf66