Hi, Saliya,

If you said the part files, I think you are talking about the results of the
reduce function that stored inside the HDFS, right?
If so, I think this example in "Hadoop The Definitive Guide" can help you.
-------------
Example 3-1. Displaying files from a Hadoop filesystem on standard output
using a
URLStreamHandler
public class URLCat {
  static {
    URL.setURLStreamHandlerFactory(new FsUrlStreamHandlerFactory());
  }

  public static void main(String[] args) throws Exception {
    InputStream in = null;
    try {
      in = new URL(args[0]).openStream();
      IOUtils.copyBytes(in, System.out, 4096, false);
    } finally {
      IOUtils.closeStream(in);
    }
  }
}

Take a try, good luck!


Best Regards
Jiamin Lu

Reply via email to