@@ -0,0 +1,1828 @@
+package com.marklogic.hub.collector.impl;%0A%0Aimport com.marklogic.hub.HubConfig;%0Aimport com.marklogic.hub.collector.DiskQueue;%0Aimport org.apache.commons.io.FilenameUtils;%0A%0Aimport java.io.File;%0Aimport java.io.IOException;%0Aimport java.nio.file.Files;%0Aimport java.nio.file.Path;%0Aimport java.nio.file.Paths;%0A%0Apublic class FileCollector %7B%0A    private String filePath;%0A    private String inputFormat;%0A    private HubConfig hubConfig;%0A%0A    public FileCollector(String filePath, String inputFormat) %7B%0A        this.filePath = filePath;%0A        this.inputFormat = inputFormat;%0A    %7D%0A%0A%0A    public void setHubConfig(HubConfig config) %7B this.hubConfig = config; %7D%0A%0A    public HubConfig getHubConfig() %7B%0A        return hubConfig;%0A    %7D%0A%0A    public DiskQueue%3CString%3E run() %7B%0A        DiskQueue%3CString%3E results;%0A        try %7B%0A            results = new DiskQueue%3C%3E(10000);%0A            Path dirPath = Paths.get(filePath);%0A            if(! dirPath.isAbsolute()) %7B%0A                File file = new File(hubConfig.getProjectDir(), dirPath.toString());%0A                dirPath = file.toPath().toAbsolutePath();%0A            %7D%0A%0A            if(! Files.exists(dirPath) && Files.isDirectory(dirPath)) %7B%0A                throw new RuntimeException(%22The path doesn't exist or is not a directory%22);%0A            %7D%0A            Files.find(dirPath,%0A                Integer.MAX_VALUE,%0A                (filePath, fileAttr) -%3E fileAttr.isRegularFile())%0A                .forEach(path -%3E %7B%0A                    File file = path.toFile();%0A                    if (FilenameUtils.getExtension(file.getName()).equalsIgnoreCase(inputFormat)) %7B%0A                            results.add(path.toFile().getAbsolutePath());%0A                    %7D%0A                %7D);%0A        %7D catch (IOException e) %7B%0A            throw new RuntimeException(e);%0A        %7D%0A        return results;%0A    %7D%0A%7D%0A

Add a FileCollector that uses DiskQueue to get the file paths