CC: Use RDD

I must point out that due to the spark context initialization, the tests
cannot run in the same time. But taking apart they are all running. I must
implement the spark way to deal with this issue.
Merge remote-tracking branch 'origin/master'