Skip to content

Instantly share code, notes, and snippets.

@mkanchwala
Created April 30, 2015 08:59
Show Gist options
  • Save mkanchwala/d6534e94ad5dc140b48b to your computer and use it in GitHub Desktop.
Save mkanchwala/d6534e94ad5dc140b48b to your computer and use it in GitHub Desktop.
Spark : How to create a Single RDD from Multiple Files
Best way to create Mutliple files into a single RDD
==================================
val fileRDD = sc.textFile(filename).repartition(1)
Where the filename is the location of your directory only.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment