code: private int getPriority(final ExecutableFlow exflow) {
      final ExecutionOptions options = exflow.getExecutionOptions();
      int priority = ExecutionOptions.DEFAULT_FLOW_PRIORITY;
      if (options != null
          && options.getFlowParameters() != null
          && options.getFlowParameters()
          .containsKey(ExecutionOptions.FLOW_PRIORITY)) {
        try {
          priority =
              Integer.valueOf(options.getFlowParameters().get(
                  ExecutionOptions.FLOW_PRIORITY));
        } catch (final NumberFormatException ex) {
          priority = ExecutionOptions.DEFAULT_FLOW_PRIORITY;
          logger.error(
              "Failed to parse flow priority for exec_id = "
                  + exflow.getExecutionId(), ex);
        }
      }
      return priority;
    }
docs: /* Helper method to fetch flow priority from flow props