java.lang.ClassCastException: org.apache.hadoop.io.LongWritable cannot be cast to org.apache.hadoop.io.Text
here is why,
for the jobconf, the default inputformat is TextInputFormat,
you will get Key/value type of longwritable/text in your Map function.
if you put something like Text as the key, you will get the classcast exception
public void map(Text key, Text value,