Free Online Certification Courses – Learn Today. Lead Tomorrow. › Forums › Apache Hadoop › What is Identity Mapper?
- This topic has 2 replies, 1 voice, and was last updated 5 years, 7 months ago by DataFlair Team.
-
AuthorPosts
-
-
September 20, 2018 at 3:36 pm #5546DataFlair TeamSpectator
Explain Identity Mapper in Hadoop?
-
September 20, 2018 at 3:36 pm #5548DataFlair TeamSpectator
Identity Mapper is the default Mapper class provided by Hadoop 1.x . This class will be picked automatically when no mapper is specified in MapReduce driver class.
Identity Mapper class implements identity function, which directly writes all its input key-value pair into output. You can check the implementation of IdentityMapper class in grepcode.com website
IdentityMapper class is defined in old mapreduce API (MR1) in org.apache.hadoop.mapred.lib package
From Hadoop 2.x (MR2 or YARN) onwards, it uses Mapper class which is defined in org.apache.hadoop.mapreduce package if you don’t specify any Mapper class in MapReduce drive program
-
September 20, 2018 at 3:36 pm #5550DataFlair TeamSpectator
Identity Mapper does not transform the input and return it as it is in Output form. as we are doing in mathematics where Identity function maps every element to itself. It’s just like what 0 does in case of addition and 1 does in case of multiplication.
It takes the Input key and Value and Splits it out the same Output Key and Value.
Identity Mapper class implements identity function, which directly writes all its input key-value pair into an output. You can check the implementation of IdentityMapper class in grepcode.com website
IdentityMapper class is defined in old MapReduce API (MR1) in org.apache.hadoop.mapred.lib package
To learn more about IdentityMapper visit :Identity Mapper
-
-
AuthorPosts
- You must be logged in to reply to this topic.