added failure capturing without stopping the job