Java – How to generalize all key/value pairs in Hadoop

How to generalize all key/value pairs in Hadoop… here is a solution to the problem.

How to generalize all key/value pairs in Hadoop

I’m new to hadoop and I’m trying to do some map/reduce tasks in Java. I would like to know how we can do a reduction operation on all key/value pairs.

For example, let’s say we have the highest temperature of the day for each day of the month. We use date as key and temperature as value, I want to get the key/value of the highest temperature for the whole month.

I hope my question is clear!

Thanks for your help.

Solution