I have an Rdd[String] and I want to shuffle all of the rows of this Rdd. How do I achieve this?
For example:
RDD object named rdd and you can run: rdd.collect.foreach(t => println(t)) has output:
1
2
3
4
I want to shuffe the rows of rdd so that running rdd.collect.foreach(t => println(t)) after the shuffle is like:
3
4
1
2