下载flume-ng-1.6.0-cdh5.7.0-src.tar.gz
下载地址:http://archive.cloudera.com/cdh5/cdh/5/flume-ng-1.6.0-cdh5.7.0-src.tar.gz
win安装好maven-3.3.9
解压flume-ng-1.6.0-cdh5.7.0-src.tar.gz并进入解压路径
编译:mvn clean compile
报错
1 | [ERROR] Failed to execute goal org.apache.maven.plugins:maven-enforcer-plugin:1.0:enforce (clean) on project flume-parent: Some Enforcer rules have failed. Look above for specific messages explaining |
换成以下编译命令,跳过enforcer
mvn clean compile validate -Denforcer.skip=true
报错
1 | [ERROR] Failed to execute goal on project flume-ng-morphline-solr-sink: Could not resolve dependencies for project org.apache.flume.flume-ng-sinks:flume-ng-morphline-solr-sink:jar:1.6.0-cdh5.7.0: Fail |
flume-ng-morphline-solr-sink
我们用不到,可以直接注释掉,在flume-ng-sinks
下的pom中找到并注释
1 | <modules> |
然后重新编译mvn clean compile validate -Denforcer.skip=true
,成功
导入IDEA
然后等到导入完毕!
导入后没有任何报错,这时我们就可以对源码进行修改了!