When compiling the source code of hadoop2.2.0,
mvn install -DskipTests
Error:
[ERROR] compilation error: [INFO] --------------------------------------------------------- [ERROR]/home/test/work/env/hadoop/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/ hadoop/security/authentication/client/AuthenticatorTestCase. java: [86,13] cannot access org. mortbay. component. abstractLifeCycle does not find org. mortbay. component. abstractLifeCycle class file server = new Server (0 ); [ERROR]/home/test/work/env/hadoop/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/hadoop/security/ authentication/client/AuthenticatorTestCase. java: [] cannot access org. mortbay. component. org. Not found in LifeCycle. mortbay. component. lifeCycle file server. getConnectors () [0]. setHost (host ); [ERROR]/home/test/work/env/hadoop/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/hadoop/security/ authentication/client/AuthenticatorTestCase. java: [98,10] cannot find the symbol: Method start () Location: Class org. mortbay. jetty. server [ERROR]/home/test/work/env/hadoop/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/hadoop/security /authentication/client/AuthenticatorTestCase. java: [] cannot find the symbol: Method stop () Location: Class org. mortbay. jetty. server [INFO] 4 errors [INFO] ------------------------------------------------------------- [INFO] Quit
This is a small bug in hadoop2.2.0 source code: https://issues.apache.org/jira/browse/HADOOP-10110
If you do not want to read English, modify hadoop-common-project/hadoop-auth/pom. xml and add a dependency:
<dependency><groupId>org.mortbay.jetty</groupId><artifactId>jetty-util</artifactId><scope>test</scope></dependency>
A package is missing.