You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-user@hadoop.apache.org by Anand Murali <an...@yahoo.com> on 2015/04/14 11:52:26 UTC

Deprecation Error

Hi:
I am using Tom Whyte's text book on Hadoop 2.X for learning. However I have installed 2.6 and using text code to get started. I get the following error on the main class

anand_vihar@Latitude-E5540:~/hadoop-2.6.0/code$ javac -classpath $(hadoop classpath) MaxTemperature.java 
MaxTemperature.java:25: error: cannot find symbol
        job.setMapperClass(MaxTemperatureMapper.class);
                           ^
  symbol:   class MaxTemperatureMapper
  location: class MaxTemperature
MaxTemperature.java:26: error: cannot find symbol
        job.setReducerClass(MaxTemperatureReducer.class);
                            ^
  symbol:   class MaxTemperatureReducer
  location: class MaxTemperature
Note: MaxTemperature.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
2 errors
Can somebody advise me what are the equivalent API for setMapperClass/SetReducer class, and where I can find the delta differences between 2.x and 2,6.

Thanks,
Regards,


 Anand Murali  11/7, 'Anand Vihar', Kandasamy St, MylaporeChennai - 600 004, IndiaPh: (044)- 28474593/ 43526162 (voicemail)

Re: Deprecation Error

Posted by Anand Murali <an...@yahoo.com>.
Many thanks Chris
 Anand Murali  11/7, 'Anand Vihar', Kandasamy St, MylaporeChennai - 600 004, IndiaPh: (044)- 28474593/ 43526162 (voicemail) 


     On Thursday, April 16, 2015 11:27 PM, Chris Nauroth <cn...@hortonworks.com> wrote:
   

 Hello Anand,
MapReduce provides 2 similar but slightly different public APIs for writing jobs.  The original API is in the org.apache.hadoop.mapred package, and a revised version is in the org.apache.hadoop.mapreduce package.  The JavaDocs provide examples of both:
http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapred/JobConf.html
http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapreduce/Job.html
A common problem is attempting to mix classes from one package with classes from the other package.  For example, you might be trying to call org.apache.hadoop.mapreduce.Job#setMapperClass with a class that implements org.apache.hadoop.mapred.Mapper instead of subclassing org.apache.hadoop.mapreduce.Mapper.
I hope this helps.
Chris NaurothHortonworkshttp://hortonworks.com/

From: Anand Murali <an...@yahoo.com>
Reply-To: "user@hadoop.apache.org" <us...@hadoop.apache.org>, Anand Murali <an...@yahoo.com>
Date: Tuesday, April 14, 2015 at 2:52 AM
To: "user@hadoop.apache.org" <us...@hadoop.apache.org>
Subject: Deprecation Error

Hi:
I am using Tom Whyte's text book on Hadoop 2.X for learning. However I have installed 2.6 and using text code to get started. I get the following error on the main class

anand_vihar@Latitude-E5540:~/hadoop-2.6.0/code$ javac -classpath $(hadoop classpath) MaxTemperature.java
MaxTemperature.java:25: error: cannot find symbol
        job.setMapperClass(MaxTemperatureMapper.class);
                           ^
  symbol:   class MaxTemperatureMapper
  location: class MaxTemperature
MaxTemperature.java:26: error: cannot find symbol
        job.setReducerClass(MaxTemperatureReducer.class);
                            ^
  symbol:   class MaxTemperatureReducer
  location: class MaxTemperature
Note: MaxTemperature.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
2 errors
Can somebody advise me what are the equivalent API for setMapperClass/SetReducer class, and where I can find the delta differences between 2.x and 2,6.

Thanks,
Regards,


 Anand Murali  11/7, 'Anand Vihar', Kandasamy St, MylaporeChennai - 600 004, IndiaPh: (044)- 28474593/ 43526162 (voicemail)

  

Re: Deprecation Error

Posted by Anand Murali <an...@yahoo.com>.
Many thanks Chris
 Anand Murali  11/7, 'Anand Vihar', Kandasamy St, MylaporeChennai - 600 004, IndiaPh: (044)- 28474593/ 43526162 (voicemail) 


     On Thursday, April 16, 2015 11:27 PM, Chris Nauroth <cn...@hortonworks.com> wrote:
   

 Hello Anand,
MapReduce provides 2 similar but slightly different public APIs for writing jobs.  The original API is in the org.apache.hadoop.mapred package, and a revised version is in the org.apache.hadoop.mapreduce package.  The JavaDocs provide examples of both:
http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapred/JobConf.html
http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapreduce/Job.html
A common problem is attempting to mix classes from one package with classes from the other package.  For example, you might be trying to call org.apache.hadoop.mapreduce.Job#setMapperClass with a class that implements org.apache.hadoop.mapred.Mapper instead of subclassing org.apache.hadoop.mapreduce.Mapper.
I hope this helps.
Chris NaurothHortonworkshttp://hortonworks.com/

From: Anand Murali <an...@yahoo.com>
Reply-To: "user@hadoop.apache.org" <us...@hadoop.apache.org>, Anand Murali <an...@yahoo.com>
Date: Tuesday, April 14, 2015 at 2:52 AM
To: "user@hadoop.apache.org" <us...@hadoop.apache.org>
Subject: Deprecation Error

Hi:
I am using Tom Whyte's text book on Hadoop 2.X for learning. However I have installed 2.6 and using text code to get started. I get the following error on the main class

anand_vihar@Latitude-E5540:~/hadoop-2.6.0/code$ javac -classpath $(hadoop classpath) MaxTemperature.java
MaxTemperature.java:25: error: cannot find symbol
        job.setMapperClass(MaxTemperatureMapper.class);
                           ^
  symbol:   class MaxTemperatureMapper
  location: class MaxTemperature
MaxTemperature.java:26: error: cannot find symbol
        job.setReducerClass(MaxTemperatureReducer.class);
                            ^
  symbol:   class MaxTemperatureReducer
  location: class MaxTemperature
Note: MaxTemperature.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
2 errors
Can somebody advise me what are the equivalent API for setMapperClass/SetReducer class, and where I can find the delta differences between 2.x and 2,6.

Thanks,
Regards,


 Anand Murali  11/7, 'Anand Vihar', Kandasamy St, MylaporeChennai - 600 004, IndiaPh: (044)- 28474593/ 43526162 (voicemail)

  

Re: Deprecation Error

Posted by Anand Murali <an...@yahoo.com>.
Many thanks Chris
 Anand Murali  11/7, 'Anand Vihar', Kandasamy St, MylaporeChennai - 600 004, IndiaPh: (044)- 28474593/ 43526162 (voicemail) 


     On Thursday, April 16, 2015 11:27 PM, Chris Nauroth <cn...@hortonworks.com> wrote:
   

 Hello Anand,
MapReduce provides 2 similar but slightly different public APIs for writing jobs.  The original API is in the org.apache.hadoop.mapred package, and a revised version is in the org.apache.hadoop.mapreduce package.  The JavaDocs provide examples of both:
http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapred/JobConf.html
http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapreduce/Job.html
A common problem is attempting to mix classes from one package with classes from the other package.  For example, you might be trying to call org.apache.hadoop.mapreduce.Job#setMapperClass with a class that implements org.apache.hadoop.mapred.Mapper instead of subclassing org.apache.hadoop.mapreduce.Mapper.
I hope this helps.
Chris NaurothHortonworkshttp://hortonworks.com/

From: Anand Murali <an...@yahoo.com>
Reply-To: "user@hadoop.apache.org" <us...@hadoop.apache.org>, Anand Murali <an...@yahoo.com>
Date: Tuesday, April 14, 2015 at 2:52 AM
To: "user@hadoop.apache.org" <us...@hadoop.apache.org>
Subject: Deprecation Error

Hi:
I am using Tom Whyte's text book on Hadoop 2.X for learning. However I have installed 2.6 and using text code to get started. I get the following error on the main class

anand_vihar@Latitude-E5540:~/hadoop-2.6.0/code$ javac -classpath $(hadoop classpath) MaxTemperature.java
MaxTemperature.java:25: error: cannot find symbol
        job.setMapperClass(MaxTemperatureMapper.class);
                           ^
  symbol:   class MaxTemperatureMapper
  location: class MaxTemperature
MaxTemperature.java:26: error: cannot find symbol
        job.setReducerClass(MaxTemperatureReducer.class);
                            ^
  symbol:   class MaxTemperatureReducer
  location: class MaxTemperature
Note: MaxTemperature.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
2 errors
Can somebody advise me what are the equivalent API for setMapperClass/SetReducer class, and where I can find the delta differences between 2.x and 2,6.

Thanks,
Regards,


 Anand Murali  11/7, 'Anand Vihar', Kandasamy St, MylaporeChennai - 600 004, IndiaPh: (044)- 28474593/ 43526162 (voicemail)

  

Re: Deprecation Error

Posted by Anand Murali <an...@yahoo.com>.
Many thanks Chris
 Anand Murali  11/7, 'Anand Vihar', Kandasamy St, MylaporeChennai - 600 004, IndiaPh: (044)- 28474593/ 43526162 (voicemail) 


     On Thursday, April 16, 2015 11:27 PM, Chris Nauroth <cn...@hortonworks.com> wrote:
   

 Hello Anand,
MapReduce provides 2 similar but slightly different public APIs for writing jobs.  The original API is in the org.apache.hadoop.mapred package, and a revised version is in the org.apache.hadoop.mapreduce package.  The JavaDocs provide examples of both:
http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapred/JobConf.html
http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapreduce/Job.html
A common problem is attempting to mix classes from one package with classes from the other package.  For example, you might be trying to call org.apache.hadoop.mapreduce.Job#setMapperClass with a class that implements org.apache.hadoop.mapred.Mapper instead of subclassing org.apache.hadoop.mapreduce.Mapper.
I hope this helps.
Chris NaurothHortonworkshttp://hortonworks.com/

From: Anand Murali <an...@yahoo.com>
Reply-To: "user@hadoop.apache.org" <us...@hadoop.apache.org>, Anand Murali <an...@yahoo.com>
Date: Tuesday, April 14, 2015 at 2:52 AM
To: "user@hadoop.apache.org" <us...@hadoop.apache.org>
Subject: Deprecation Error

Hi:
I am using Tom Whyte's text book on Hadoop 2.X for learning. However I have installed 2.6 and using text code to get started. I get the following error on the main class

anand_vihar@Latitude-E5540:~/hadoop-2.6.0/code$ javac -classpath $(hadoop classpath) MaxTemperature.java
MaxTemperature.java:25: error: cannot find symbol
        job.setMapperClass(MaxTemperatureMapper.class);
                           ^
  symbol:   class MaxTemperatureMapper
  location: class MaxTemperature
MaxTemperature.java:26: error: cannot find symbol
        job.setReducerClass(MaxTemperatureReducer.class);
                            ^
  symbol:   class MaxTemperatureReducer
  location: class MaxTemperature
Note: MaxTemperature.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
2 errors
Can somebody advise me what are the equivalent API for setMapperClass/SetReducer class, and where I can find the delta differences between 2.x and 2,6.

Thanks,
Regards,


 Anand Murali  11/7, 'Anand Vihar', Kandasamy St, MylaporeChennai - 600 004, IndiaPh: (044)- 28474593/ 43526162 (voicemail)

  

Re: Deprecation Error

Posted by Chris Nauroth <cn...@hortonworks.com>.
Hello Anand,

MapReduce provides 2 similar but slightly different public APIs for writing jobs.  The original API is in the org.apache.hadoop.mapred package, and a revised version is in the org.apache.hadoop.mapreduce package.  The JavaDocs provide examples of both:

http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapred/JobConf.html

http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapreduce/Job.html

A common problem is attempting to mix classes from one package with classes from the other package.  For example, you might be trying to call org.apache.hadoop.mapreduce.Job#setMapperClass with a class that implements org.apache.hadoop.mapred.Mapper instead of subclassing org.apache.hadoop.mapreduce.Mapper.

I hope this helps.

Chris Nauroth
Hortonworks
http://hortonworks.com/


From: Anand Murali <an...@yahoo.com>>
Reply-To: "user@hadoop.apache.org<ma...@hadoop.apache.org>" <us...@hadoop.apache.org>>, Anand Murali <an...@yahoo.com>>
Date: Tuesday, April 14, 2015 at 2:52 AM
To: "user@hadoop.apache.org<ma...@hadoop.apache.org>" <us...@hadoop.apache.org>>
Subject: Deprecation Error

Hi:

I am using Tom Whyte's text book on Hadoop 2.X for learning. However I have installed 2.6 and using text code to get started. I get the following error on the main class


anand_vihar@Latitude-E5540:~/hadoop-2.6.0/code$ javac -classpath $(hadoop classpath) MaxTemperature.java
MaxTemperature.java:25: error: cannot find symbol
        job.setMapperClass(MaxTemperatureMapper.class);
                           ^
  symbol:   class MaxTemperatureMapper
  location: class MaxTemperature
MaxTemperature.java:26: error: cannot find symbol
        job.setReducerClass(MaxTemperatureReducer.class);
                            ^
  symbol:   class MaxTemperatureReducer
  location: class MaxTemperature
Note: MaxTemperature.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
2 errors

Can somebody advise me what are the equivalent API for setMapperClass/SetReducer class, and where I can find the delta differences between 2.x and 2,6.


Thanks,

Regards,



Anand Murali
11/7, 'Anand Vihar', Kandasamy St, Mylapore
Chennai - 600 004, India
Ph: (044)- 28474593/ 43526162 (voicemail)

Re: Deprecation Error

Posted by Chris Nauroth <cn...@hortonworks.com>.
Hello Anand,

MapReduce provides 2 similar but slightly different public APIs for writing jobs.  The original API is in the org.apache.hadoop.mapred package, and a revised version is in the org.apache.hadoop.mapreduce package.  The JavaDocs provide examples of both:

http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapred/JobConf.html

http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapreduce/Job.html

A common problem is attempting to mix classes from one package with classes from the other package.  For example, you might be trying to call org.apache.hadoop.mapreduce.Job#setMapperClass with a class that implements org.apache.hadoop.mapred.Mapper instead of subclassing org.apache.hadoop.mapreduce.Mapper.

I hope this helps.

Chris Nauroth
Hortonworks
http://hortonworks.com/


From: Anand Murali <an...@yahoo.com>>
Reply-To: "user@hadoop.apache.org<ma...@hadoop.apache.org>" <us...@hadoop.apache.org>>, Anand Murali <an...@yahoo.com>>
Date: Tuesday, April 14, 2015 at 2:52 AM
To: "user@hadoop.apache.org<ma...@hadoop.apache.org>" <us...@hadoop.apache.org>>
Subject: Deprecation Error

Hi:

I am using Tom Whyte's text book on Hadoop 2.X for learning. However I have installed 2.6 and using text code to get started. I get the following error on the main class


anand_vihar@Latitude-E5540:~/hadoop-2.6.0/code$ javac -classpath $(hadoop classpath) MaxTemperature.java
MaxTemperature.java:25: error: cannot find symbol
        job.setMapperClass(MaxTemperatureMapper.class);
                           ^
  symbol:   class MaxTemperatureMapper
  location: class MaxTemperature
MaxTemperature.java:26: error: cannot find symbol
        job.setReducerClass(MaxTemperatureReducer.class);
                            ^
  symbol:   class MaxTemperatureReducer
  location: class MaxTemperature
Note: MaxTemperature.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
2 errors

Can somebody advise me what are the equivalent API for setMapperClass/SetReducer class, and where I can find the delta differences between 2.x and 2,6.


Thanks,

Regards,



Anand Murali
11/7, 'Anand Vihar', Kandasamy St, Mylapore
Chennai - 600 004, India
Ph: (044)- 28474593/ 43526162 (voicemail)

Re: Deprecation Error

Posted by Chris Nauroth <cn...@hortonworks.com>.
Hello Anand,

MapReduce provides 2 similar but slightly different public APIs for writing jobs.  The original API is in the org.apache.hadoop.mapred package, and a revised version is in the org.apache.hadoop.mapreduce package.  The JavaDocs provide examples of both:

http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapred/JobConf.html

http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapreduce/Job.html

A common problem is attempting to mix classes from one package with classes from the other package.  For example, you might be trying to call org.apache.hadoop.mapreduce.Job#setMapperClass with a class that implements org.apache.hadoop.mapred.Mapper instead of subclassing org.apache.hadoop.mapreduce.Mapper.

I hope this helps.

Chris Nauroth
Hortonworks
http://hortonworks.com/


From: Anand Murali <an...@yahoo.com>>
Reply-To: "user@hadoop.apache.org<ma...@hadoop.apache.org>" <us...@hadoop.apache.org>>, Anand Murali <an...@yahoo.com>>
Date: Tuesday, April 14, 2015 at 2:52 AM
To: "user@hadoop.apache.org<ma...@hadoop.apache.org>" <us...@hadoop.apache.org>>
Subject: Deprecation Error

Hi:

I am using Tom Whyte's text book on Hadoop 2.X for learning. However I have installed 2.6 and using text code to get started. I get the following error on the main class


anand_vihar@Latitude-E5540:~/hadoop-2.6.0/code$ javac -classpath $(hadoop classpath) MaxTemperature.java
MaxTemperature.java:25: error: cannot find symbol
        job.setMapperClass(MaxTemperatureMapper.class);
                           ^
  symbol:   class MaxTemperatureMapper
  location: class MaxTemperature
MaxTemperature.java:26: error: cannot find symbol
        job.setReducerClass(MaxTemperatureReducer.class);
                            ^
  symbol:   class MaxTemperatureReducer
  location: class MaxTemperature
Note: MaxTemperature.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
2 errors

Can somebody advise me what are the equivalent API for setMapperClass/SetReducer class, and where I can find the delta differences between 2.x and 2,6.


Thanks,

Regards,



Anand Murali
11/7, 'Anand Vihar', Kandasamy St, Mylapore
Chennai - 600 004, India
Ph: (044)- 28474593/ 43526162 (voicemail)

Re: Deprecation Error

Posted by Chris Nauroth <cn...@hortonworks.com>.
Hello Anand,

MapReduce provides 2 similar but slightly different public APIs for writing jobs.  The original API is in the org.apache.hadoop.mapred package, and a revised version is in the org.apache.hadoop.mapreduce package.  The JavaDocs provide examples of both:

http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapred/JobConf.html

http://hadoop.apache.org/docs/r2.6.0/api/org/apache/hadoop/mapreduce/Job.html

A common problem is attempting to mix classes from one package with classes from the other package.  For example, you might be trying to call org.apache.hadoop.mapreduce.Job#setMapperClass with a class that implements org.apache.hadoop.mapred.Mapper instead of subclassing org.apache.hadoop.mapreduce.Mapper.

I hope this helps.

Chris Nauroth
Hortonworks
http://hortonworks.com/


From: Anand Murali <an...@yahoo.com>>
Reply-To: "user@hadoop.apache.org<ma...@hadoop.apache.org>" <us...@hadoop.apache.org>>, Anand Murali <an...@yahoo.com>>
Date: Tuesday, April 14, 2015 at 2:52 AM
To: "user@hadoop.apache.org<ma...@hadoop.apache.org>" <us...@hadoop.apache.org>>
Subject: Deprecation Error

Hi:

I am using Tom Whyte's text book on Hadoop 2.X for learning. However I have installed 2.6 and using text code to get started. I get the following error on the main class


anand_vihar@Latitude-E5540:~/hadoop-2.6.0/code$ javac -classpath $(hadoop classpath) MaxTemperature.java
MaxTemperature.java:25: error: cannot find symbol
        job.setMapperClass(MaxTemperatureMapper.class);
                           ^
  symbol:   class MaxTemperatureMapper
  location: class MaxTemperature
MaxTemperature.java:26: error: cannot find symbol
        job.setReducerClass(MaxTemperatureReducer.class);
                            ^
  symbol:   class MaxTemperatureReducer
  location: class MaxTemperature
Note: MaxTemperature.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
2 errors

Can somebody advise me what are the equivalent API for setMapperClass/SetReducer class, and where I can find the delta differences between 2.x and 2,6.


Thanks,

Regards,



Anand Murali
11/7, 'Anand Vihar', Kandasamy St, Mylapore
Chennai - 600 004, India
Ph: (044)- 28474593/ 43526162 (voicemail)