Added logic and tests for handling job updates and timeouts.