1. A method comprising: detecting, by a processor, that a job executing on an executor failed; determining, by the processor, based on at least one factor from a predetermined set of executor-related factors, that the job executing on the executor failed due to a state of the executor; and adjusting, by the processor, in response to determining that the job executing on the executor failed due to the state of the executor, the state of the executor to a known good state selected from a stored set of known good states, wherein adjusting the state of the executor to the known good state comprises: computing a difference between the state of the executor and each of a plurality of known good states in the stored set of known good states, wherein computing the difference comprises computing an amount of software or hardware that needs to be modified; and selecting the known good state to which the state of the executor is to be adjusted based on the difference being smaller than a threshold difference.