Type: New Feature
Affects Version/s: None
Fix Version/s: None
Currently if a workunit is blocked in an external call (e.g., spraying a file), the status is shown as running, but there is no indication why it is not progressing.
It would be much better if the status was updated to indicate it was blocked, and some indication of why.
An outline implementation:
- For functions that are timed, (optionally) save some details in the call to get the initial start time.
- Add a thread which periodically checks if an external call has been waiting for more than <n> seconds, and if so update the workunit.
- clear the information on failure.
- How do we ensure the state is cleared on failure
- What level of description is added to the state. It is important to minimize the overhead, so dynamically evaluating a string to put in the status on each call may be too expensive. That would limit whether the spray filename was included etc.
- Do some calls (e.g., spray) want to unconditionally update the state as soon as it starts?
- If a call exceeds a threshold, a timestamp could be added to the workunit indicating when the spray started.
- Thor may also have some long running external calls, so a class that could be shared would be good.