Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class JoinMapper extends Mapper<LongWritable, Text, Text, Text> {
- private Text keyEmit = new Text();
- private Text valEmit = new Text();
- public void map(LongWritable k, Text value, Context context) throws IOException, InterruptedException
- {
- String line=value.toString();
- String[] words=line.split(",");
- keyEmit.set(words[0]);
- valEmit.set(words[1]);
- context.write(keyEmit, valEmit);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement