hadoop-hdfs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bill Yu <yubiaoe...@gmail.com>
Subject Re: How to define the path of HDFS?
Date Fri, 11 Sep 2009 00:53:19 GMT
Thanks for Jingkei's suggestion . But how can I serialize the input scream
to create a tree by FileSystem.open() ?
Anyone 's suggestion is appreciative!

2009/9/10 Jingkei Ly <jly.list@googlemail.com>

> You should use FileSystem.open() to obtain an input stream to read from
> HDFS (
> http://hadoop.apache.org/common/docs/current/api/org/apache/hadoop/fs/FileSystem.html#open%28org.apache.hadoop.fs.Path%29
> ).
>
> 2009/9/9 Bill Yu <yubiaoever@gmail.com>
>
> Hi everyone,
>>
>>      when I run the following code:
>>
>>      ObjectInputStream in = new ObjectInputStream(new
>> FileInputStream("hdfs://localhost:9000/myDir/trajectory/test.obj"));
>>
>>      it throws an error that the directory is not exist, how can I define
>> the its path ?
>>      Any suggestion is appreciate !
>>
>> Thanks,
>> Austin
>
>
>

Mime
View raw message