tags:

views:

7

answers:

1

Hello everyone, when i am processing a given key-{set of values} pair in reducer function, how can I get the partition number to which this key-{set of values} belong to? How is it possible to get this partition number without adding extra information about the partition number with each key-value pair during partitioning? Cheers

A: 

This has worked for me: jobconf.getInt( "mapred.task.partition", 0); in the reducer.