tencentyun/hadoop-cos

hadoop-cos build with hadoop-3.3.4 fail

lifehacking opened this issue · 1 comments

when i build hadoop-cos(v8.2.1) with apache hadoop-3.3.4 version for jar pkg, mvn package return error

mvn package:

[INFO] Changes detected - recompiling the module!
[INFO] Compiling 68 source files to /opt/soft/hadoop-cos/target/classes
[INFO] -------------------------------------------------------------
[WARNING] COMPILATION WARNING :
[INFO] -------------------------------------------------------------
[WARNING] /opt/soft/hadoop-cos/src/main/java/org/apache/hadoop/fs/cosn/buffer/CosNMappedBuffer.java:[5,18] sun.nio.ch.FileChannelImpl is inter nal proprietary API and may be removed in a future release
[WARNING] /opt/soft/hadoop-cos/src/main/java/org/apache/hadoop/fs/cosn/buffer/CosNRandomAccessMappedBuffer.java:[6,18] sun.nio.ch.FileChannelI mpl is internal proprietary API and may be removed in a future release
[WARNING] /opt/soft/hadoop-cos/src/main/java/org/apache/hadoop/fs/cosn/buffer/CosNMappedBuffer.java:[48,29] sun.nio.ch.FileChannelImpl is inte rnal proprietary API and may be removed in a future release
[WARNING] /opt/soft/hadoop-cos/src/main/java/org/apache/hadoop/fs/cosn/buffer/CosNMappedBuffer.java:[50,27] sun.nio.ch.FileChannelImpl is inte rnal proprietary API and may be removed in a future release
[WARNING] /opt/soft/hadoop-cos/src/main/java/org/apache/hadoop/fs/cosn/buffer/CosNRandomAccessMappedBuffer.java:[73,23] sun.nio.ch.FileChannel Impl is internal proprietary API and may be removed in a future release
[WARNING] /opt/soft/hadoop-cos/src/main/java/org/apache/hadoop/fs/cosn/buffer/CosNRandomAccessMappedBuffer.java:[75,21] sun.nio.ch.FileChannel Impl is internal proprietary API and may be removed in a future release
[WARNING] /opt/soft/hadoop-cos/src/main/java/org/apache/hadoop/fs/CosNFSDataOutputStream.java: Some input files use or override a deprecated A PI.
[WARNING] /opt/soft/hadoop-cos/src/main/java/org/apache/hadoop/fs/CosNFSDataOutputStream.java: Recompile with -Xlint:deprecation for details.
[INFO] 8 warnings
[INFO] -------------------------------------------------------------
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] /opt/soft/hadoop-cos/src/main/java/org/apache/hadoop/fs/CosNSeekableFSDataOutputStream.java:[52,15] abort() in org.apache.hadoop.fs.Co sNSeekableFSDataOutputStream cannot implement abort() in org.apache.hadoop.fs.Abortable
return type void is not compatible with org.apache.hadoop.fs.Abortable.AbortableResult
[INFO] 1 error
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:25 min
[INFO] Finished at: 2023-01-12T11:11:48Z
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project hadoop-cos: Compilation failure
[ERROR] /opt/soft/hadoop-cos/src/main/java/org/apache/hadoop/fs/CosNSeekableFSDataOutputStream.java:[52,15] abort() in org.apache.hadoop.fs.Co sNSeekableFSDataOutputStream cannot implement abort() in org.apache.hadoop.fs.Abortable
[ERROR] return type void is not compatible with org.apache.hadoop.fs.Abortable.AbortableResult
[ERROR]
[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

你好,感谢反馈这个问题,刚刚测试了一下,确实存在这个兼容性问题,因为新版本的hadoop-common当中增加了abort接口跟 hadoop-cos 当中的 abort 接口出现冲突。