Which algorithm is used for sorting in MapReduce Hadoop
-
-
Which sorting algorithm is used in MapReduce in Hadoop?
-
Sorting in MapReduce is on Both Mapper Side as well as Reducer side.
Mapper side(Quick Sort)
The Mapper process the input key value pair from Record Reader and generates output as per custom Business logic, before writing the data the output is partitioned and sorted by key.
Reducer side(Merge Sort):
In Reducer phase the data from the Mapper is again sorted as per the key and sent to Reducer for processing data as per custom business logic.The shuffling and sorting in Reducer phase happens simultaneously.
- You must be logged in to reply to this topic.