Instead of a file path, use a HDFS URI.
For example: (In Python)


data = sc.textFile("hdfs://localhost/user/someuser/data")

​

On Wed, Nov 12, 2014 at 10:12 AM, rapelly kartheek <kartheek.m...@gmail.com>
wrote:

> Hi
>
> I am trying to access a file in HDFS from spark "source code". Basically,
> I am tweaking the spark source code. I need to access a file in HDFS from
> the source code of the spark. I am really not understanding how to go about
> doing this.
>
> Can someone please help me out in this regard.
> Thank you!!
> Karthik
>

Reply via email to