Uploaded image for project: 'Beam'
  1. Beam
  2. BEAM-8535

TextIO.read doesn't work with single wildcard with relative path

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P1
    • Resolution: Duplicate
    • Affects Version/s: 2.16.0
    • Fix Version/s: 2.17.0
    • Component/s: beam-model, io-java-files
    • Labels:
      None
    • Environment:
      Mac High Sierra 10.13.6. DirectRunner local.

      Description

      It looks like the TextIO.read transform is not matching files when using a glob wildcard when the glob starts with a * and the path is relative.  IE /full/path/* and ./path/f* work but ./path/* does not.

      Reproduction steps using the word count example from the Beam Quick start for current version 2.16 (https://beam.apache.org/get-started/quickstart-java/) - 

      $ mkdir test-folder && cp pom.xml ./test-folder
      $ mvn compile exec:java -Dexec.mainClass=org.apache.beam.examples.WordCount \
      >      -Dexec.args="--inputFile=./test-folder/* --output=counts" -Pdirect-runner
      
      
      

       The above fails when it is expected to find the pom.xml file. I tested the same way with 2.15 and it works as expected.  

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                chamikara Chamikara Madhusanka Jayalath
                Reporter:
                tim_f Tim
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: