@Override
    public List<WorkflowModel> getPendingWorkflowsByType(String workflowName, int version) {
        Preconditions.checkNotNull(workflowName, "workflowName cannot be null");
        List<String> workflowIds = getRunningWorkflowIds(workflowName, version);
        return workflowIds.stream()
                .map(this::getWorkflow)
                .filter(workflow -> workflow.getWorkflowVersion() == version)
                .collect(Collectors.toList());
    }
@param workflowName name of the workflow
@param version the workflow version
@return list of workflows that are in RUNNING state
redis-persistence/src/main/java/com/netflix/conductor/redis/dao/RedisExecutionDAO.java