private FlowExecution getFlowExecution(TuningInput tuningInput) {
    FlowExecution flowExecution =
        FlowExecution.find.where().eq(FlowExecution.TABLE.flowExecId, tuningInput.getFlowExecId()).findUnique();

    if (flowExecution == null) {
      flowExecution = new FlowExecution();
      flowExecution.flowExecId = tuningInput.getFlowExecId();
      flowExecution.flowExecUrl = tuningInput.getFlowExecUrl();
      flowExecution.flowDefinition = getFlowDefinition(tuningInput);
      flowExecution.save();
    }
    return flowExecution;
  }
Returns flow execution corresponding to the given tuning input if it exists, else creates one and returns it
@param tuningInput TuningInput containing the flow execution id corresponding to which flow execution
                   is to be returned
@return FlowExecution flow execution
app/com/linkedin/drelephant/tuning/AutoTuningAPIHelper.java