下面记录的编译问题,是依次碰到并解决的,主要还是源的问题。如果编译过程遇到问题,可以直接尝试用第三种解决方法,配置mvn的settings.xml。
1.编译Apache Atlas JanusGraph DB Impl失败?
错误提示
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-remote-resources-plugin:1.5:process (default) on project atlas-graphdb-janus: Error resolving project artifact: Could not transfer artifact com.sleepycat:je:pom:7.4.5 from/to central (http://repo1.maven.org/maven2): Failed to transfer file: http://repo1.maven.org/maven2/com/sleepycat/je/7.4.5/je-7.4.5.pom. Return code is: 501, ReasonPhrase: HTTPS Required. for project com.sleepycat:je:jar:7.4.5 -> [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/MojoExecutionException
[ERROR]?
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] ? mvn <goals> -rf :atlas-graphdb-janus
解决方法
pom.xml添加repository配置
<repository> <id>oracleReleases</id> <name>Oracle Released Java Packages</name> <url>http://download.oracle.com/maven</url> <layout>default</layout> </repository>?
2.编译Apache Atlas Web Application 失败
错误提示
[ERROR] Failed to execute goal on project atlas-webapp: Could not resolve dependencies for project org.apache.atlas:atlas-webapp:war:2.0.0: Could not transfer artifact com.amazonaws:aws-java-sdk-bundle:jar:1.11.271 from/to central (http://repo1.maven.org/maven2): Failed to transfer file: http://repo1.maven.org/maven2/com/amazonaws/aws-java-sdk-bundle/1.11.271/aws-java-sdk-bundle-1.11.271.jar. Return code is: 501, ReasonPhrase: HTTPS Required. -> [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/DependencyResolutionException
[ERROR]?
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] ? mvn <goals> -rf :atlas-webapp?
解决方法
pom.xml添加repository配置
<repository> <id>alimaven</id> <name>aliyun maven</name> <url>http://maven.aliyun.com/nexus/content/groups/public/</url> </repository>
?
?3.编译Apache Atlas Documentation失败
错误提示
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-site-plugin:3.7:site (default) on project atlas-docs: SiteToolException: The site descriptor cannot be resolved from the repository: ArtifactResolutionException: Unable to locate site descriptor: Could not transfer artifact org.apache:apache:xml:site_en:17 from/to central (http://repo1.maven.org/maven2): Failed to transfer file: http://repo1.maven.org/maven2/org/apache/apache/17/apache-17-site_en.xml. Return code is: 501 , ReasonPhrase:HTTPS Required.
[ERROR] ? org.apache:apache:xml:17
[ERROR]?
[ERROR] from the specified remote repositories:
[ERROR] ? central (http://repo1.maven.org/maven2, releases=true, snapshots=false),
[ERROR] ? hortonworks.repo (http://repo.hortonworks.com/content/repositories/releases, releases=true, snapshots=false),
[ERROR] ? apache.snapshots.repo (https://repository.apache.org/content/groups/snapshots, releases=true, snapshots=true),
[ERROR] ? apache-staging (https://repository.apache.org/content/groups/staging/, releases=true, snapshots=true),
[ERROR] ? default (https://repository.apache.org/content/groups/public/, releases=true, snapshots=true),
[ERROR] ? java.net-Public (https://maven.java.net/content/groups/public/, releases=true, snapshots=true),
[ERROR] ? repository.jboss.org-public (https://repository.jboss.org/nexus/content/groups/public, releases=true, snapshots=true),
[ERROR] ? typesafe (http://repo.typesafe.com/typesafe/releases/, releases=true, snapshots=true),
[ERROR] ? alimaven (http://maven.aliyun.com/nexus/content/groups/public/, releases=true, snapshots=true),
[ERROR] ? oracleReleases (http://download.oracle.com/maven, releases=true, snapshots=true),
[ERROR] ? apache.snapshots (http://repository.apache.org/snapshots, releases=false, snapshots=true)
[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/MojoExecutionException
[ERROR]?
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] ? mvn <goals> -rf :atlas-docs
?
解决方法
配置mvn镜像
vim ~/.m2/settings.xml
?<mirror>?
? ? ? <id>alimaven</id>?
? ? ? <name>aliyun maven</name>?
? ? ? <url>http://maven.aliyun.com/nexus/content/repositories/central/</url>?
? ? ? <mirrorOf>central</mirrorOf>?
? ? </mirror>?
?
?
4.npm和node安装问题
Unable to save binary /Users/macliems/.nvm/versions/node/v8.1.2/lib/node_modules/@angular/cli/node_modules/node-sass/vendor/darwin-x64-57 : { Error: EACCES: permission denied, mkdir '/Users/macliems/.nvm/versions/node/v8.1.2/lib/node_modules/@angular/cli/node_modules/node-sass/vendor'
? ? at Object.fs.mkdirSync (fs.js:890:18)
? ? at sync (/Users/macliems/.nvm/versions/node/v8.1.2/lib/node_modules/@angular/cli/node_modules/mkdirp/index.js:71:13)
? ? at Function.sync (/Users/macliems/.nvm/versions/node/v8.1.2/lib/node_modules/@angular/cli/node_modules/mkdirp/index.js:77:24)
? ? at checkAndDownloadBinary (/Users/macliems/.nvm/versions/node/v8.1.2/lib/node_modules/@angular/cli/node_modules/node-sass/scripts/install.js:111:11)
? ? at Object.<anonymous> (/Users/macliems/.nvm/versions/node/v8.1.2/lib/node_modules/@angular/cli/node_modules/node-sass/scripts/install.js:154:1)
? ? at Module._compile (module.js:569:30)
? ? at Object.Module._extensions..js (module.js:580:10)
? ? at Module.load (module.js:503:32)
? ? at tryModuleLoad (module.js:466:12)
? ? at Function.Module._load (module.js:458:3)
? errno: -13,
? code: 'EACCES',
? syscall: 'mkdir',
? path: '/Users/macliems/.nvm/versions/node/v8.1.2/lib/node_modules/@angular/cli/node_modules/node-sass/vendor' }?
原因:npm和node是在root账户下安装的,卸载,并重新在user_00账户下安装。
npm和node的安装可参考:https://blog.csdn.net/weixin_43629719/article/details/94573697?