Hadoop Map/Reduce
  1. Hadoop Map/Reduce
  2. MAPREDUCE-3772

MultipleOutputs output lost if baseOutputPath starts with ../

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Invalid
    • Affects Version/s: 0.20.2
    • Fix Version/s: None
    • Component/s: client
    • Labels:
      None
    • Target Version/s:

      Description

      Lets say you have output directory set:

      FileOutputFormat.setOutputPath(job, "/tmp/multi1/out");

      and want to place output from MultipleOutputs into /tmp/multi1/extra

      I expect following code to work:

      mos = new MultipleOutputs<Text, IntWritable>(context);
      mos.write(new Text("zrr"), value, "../extra/");

      but no Exception is throw and expected output directory /tmp/multi1/extra does not even exists. All data written to this output vanish without trace.

      To make it work fullpath must be used
      mos.write(new Text("zrr"), value, "/tmp/multi1/extra/");

      Output is listed in statistics from MultipleOutputs correctly:

      org.apache.hadoop.mapreduce.lib.output.MultipleOutputs
      ../gaja1/=13333 (* everything is lost *)
      /tmp/multi1/out/../ksd34/=13333 (* this using full path works *)
      list1=6667

        Activity

        Radim Kolar created issue -
        Priyo Mustafi made changes -
        Field Original Value New Value
        Priority Minor [ 4 ] Major [ 3 ]
        Priyo Mustafi made changes -
        Affects Version/s 0.20.203.0 [ 12316151 ]
        Harsh J made changes -
        Attachment MAPREDUCE-3772.patch [ 12555386 ]
        Harsh J made changes -
        Status Open [ 1 ] Patch Available [ 10002 ]
        Affects Version/s 0.20.2 [ 12314205 ]
        Affects Version/s 0.22.0 [ 12314184 ]
        Affects Version/s 0.20.203.0 [ 12316151 ]
        Target Version/s 3.0.0 [ 12320355 ]
        Assignee Harsh J [ qwertymaniac ]
        Harsh J made changes -
        Component/s client [ 12312982 ]
        Component/s mrv1 [ 12315344 ]
        Harsh J made changes -
        Environment FreeBSD
        Harsh J made changes -
        Status Patch Available [ 10002 ] Open [ 1 ]
        Radim Kolar made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Invalid [ 6 ]

          People

          • Assignee:
            Harsh J
            Reporter:
            Radim Kolar
          • Votes:
            1 Vote for this issue
            Watchers:
            12 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development