code: public void store(JobInProgress job) {
      if (active && retainTime > 0) {
        JobID jobId = job.getStatus().getJobID();
        Path jobStatusFile = getInfoFilePath(jobId);
        try {
          FSDataOutputStream dataOut = fs.create(jobStatusFile);
  
          job.getStatus().write(dataOut);
  
          job.getProfile().write(dataOut);
  
          job.getCounters().write(dataOut);
  
          TaskCompletionEvent[] events = 
                  job.getTaskCompletionEvents(0, Integer.MAX_VALUE);
          dataOut.writeInt(events.length);
          for (TaskCompletionEvent event : events) {
            event.write(dataOut);
          }
  
          dataOut.close();
        } catch (IOException ex) {
          LOG.warn("Could not store [" + jobId + "] job info : " +
                   ex.getMessage(), ex);
          try {
            fs.delete(jobStatusFile, true);
          }
          catch (IOException ex1) {
            //ignore
          }
        }
      }
    }
docs: Persists a job in DFS.
  
  @param job the job about to be 'retired'