Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

package org.apache.hadoop.record does not exist #32

Open
ReinhardtGao opened this issue Jul 12, 2017 · 0 comments
Open

package org.apache.hadoop.record does not exist #32

ReinhardtGao opened this issue Jul 12, 2017 · 0 comments

Comments

@ReinhardtGao
Copy link

Hello,

I was packaging the codes with maven and I encountered issue for chapter 22's codes. It notice me that "package org.apache.hadoop.record" is not exist.

I googled this package and found that it has already been deprecated by Avro. Avro and other dependent packages are installed by maven. You can see from the result below that other compile task are successful.

[INFO] 53 errors
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] Hadoop: The Definitive Guide, Project .............. SUCCESS [ 0.406 s]
[INFO] Common Code ........................................ SUCCESS [ 2.231 s]
[INFO] Chapter 2: MapReduce ............................... SUCCESS [ 0.194 s]
[INFO] Chapter 3: The Hadoop Distributed Filesystem ....... SUCCESS [ 0.398 s]
[INFO] Chapter 5: Hadoop I/O .............................. SUCCESS [ 0.376 s]
[INFO] Chapter 6: Developing a MapReduce Application ...... SUCCESS [ 0.336 s]
[INFO] Chapter 8: MapReduce Types and Formats ............. SUCCESS [ 0.651 s]
[INFO] Chapter 9: MapReduce Features ...................... SUCCESS [ 0.344 s]
[INFO] Chapter 12: Avro ................................... SUCCESS [ 5.353 s]
[INFO] Chapter 13: Parquet ................................ SUCCESS [ 1.922 s]
[INFO] Chapter 15: Sqoop .................................. SUCCESS [ 0.148 s]
[INFO] Chapter 16: Pig .................................... SUCCESS [ 0.173 s]
[INFO] Chapter 17: Hive ................................... SUCCESS [ 0.426 s]
[INFO] Chapter 18: Crunch ................................. SUCCESS [ 1.371 s]
[INFO] Chapter 19: Spark .................................. SUCCESS [ 13.280 s]
[INFO] Chapter 20: HBase .................................. SUCCESS [ 0.390 s]
[INFO] Chapter 21: ZooKeeper .............................. SUCCESS [ 0.090 s]
[INFO] Chapter 22: Case Studies ........................... FAILURE [ 0.196 s]
[INFO] Hadoop Examples JAR ................................ SKIPPED
[INFO] Snippet testing .................................... SKIPPED
[INFO] Hadoop: The Definitive Guide, Example Code ......... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 28.732 s
[INFO] Finished at: 2017-07-12T10:56:53+08:00
[INFO] Final Memory: 90M/360M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project ch22-case-studies: Compilation failure: Compilation failure:
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[4,57] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[5,53] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[6,47] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[35,46] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[38,65] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[100,55] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[110,71] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[120,57] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[218,66] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[9,57] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[10,73] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[11,69] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[12,73] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[13,74] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[14,69] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[53,53] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[56,36] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[57,55] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[60,38] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[146,58] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[146,136] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[147,38] package org.apache.hadoop.record.meta does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[226,43] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[227,43] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[231,43] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[232,43] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[236,43] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[237,43] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[241,43] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[242,43] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[246,43] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[247,43] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[260,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[261,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[265,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[266,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[270,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[271,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[275,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[276,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[280,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[281,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[285,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[286,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[290,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[291,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[295,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[296,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[300,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[301,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[305,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[306,44] package org.apache.hadoop.record does not exist
[ERROR] /usr/local/hadoop/myclass/hadoop-book/ch22-case-studies/src/main/java/fm/last/hadoop/io/records/TrackStats.java:[321,29] package org.apache.hadoop.record does not exist
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] mvn -rf :ch22-case-studies

Also attach my environment variables here.
#JAVA
export JAVA_HOME=/usr/java/jdk1.8.0_131
export JRE_HOME=$JAVA_HOME/jre
export CLASSPATH=.:$CLASSPATH:$JAVA_HOME/lib:$JRE_HOME/lib
export PATH=$PATH:$JAVA_HOME/bin:$JRE_HOME/bin
#HADOOP
export HADOOP_HOME=/usr/local/hadoop
export HADOOP_INSTALL=$HADOOP_HOME
export HADOOP_MAPRED_HOME=$HADOOP_HOME
export HADOOP_COMMON_HOME=$HADOOP_HOME
export HADOOP_HDFS_HOME=$HADOOP_HOME
export YARN_HOME=$HADOOP_HOME
export HADOOP_COMMON_LIB_NATIVE_DIR=$HADOOP_HOME/lib/native
export PATH=$PATH:$HADOOP_HOME/sbin:$HADOOP_HOME/bin
export HADOOP_CLASSPATH=/usr/local/hadoop/share/hadoop/common/hadoop-common-3.0.0-alpha3.jar:/usr/local/hadoop/myclass
#HIVE
export HIVE_INSTALL=/usr/local/hive
export PATH=$PATH:$HIVE_INSTALL/bin

Could anyone help me with this issue? Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant