I am new to Spark. I am trying to implement spark program in java. I just want to read multiple files from a folder and combine altogether by pairing its words@filname as key and value(count).
I don't know how to combine all data together.. and I want the output to be like pairs (word@filname,1)
ex: (happy@file1,2) (newyear@file1,1) (newyear@file2,1)