question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Problems getting started - Failed to execute goal add-license-notice

See original GitHub issue

Describe the issue

I am trying to build and test the source on a new machine as follows:

$ sudo yum install java-1.8.0-openjdk
$ sudo yum install maven
$ git clone https://github.com/OliverGavin/aws-sdk-java-v2.git
cd aws-sdk-java-v2
mvn package

System info:

$ mvn -v
Apache Maven 3.0.5 (Red Hat 3.0.5-17)
Maven home: /usr/share/maven
Java version: 1.8.0_312, vendor: Red Hat, Inc.
Java home: /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.312.b07-1.amzn2.0.2.x86_64/jre
Default locale: en_US, platform encoding: UTF-8
OS name: "linux", version: "5.4.196-119.356.amzn2int.x86_64", arch: "amd64", family: "unix"

With mvn compile (also install and package) I am getting this error:

[INFO] ------------------------------------------------------------------------
[INFO] Building AWS Java SDK :: Parent 2.17.232-SNAPSHOT                
[INFO] ------------------------------------------------------------------------
[INFO]                                                            
[INFO] --- maven-checkstyle-plugin:3.1.2:check (checkstyle) @ aws-sdk-java-pom ---
[INFO] Starting audit...                                          
Audit done.                                                       
[INFO] You have 0 Checkstyle violations.                          
[INFO]                                                             
[INFO] --- jacoco-maven-plugin:0.8.7:prepare-agent (default-prepare-agent) @ aws-sdk-java-pom ---
[INFO] argLine set to -javaagent:/home/oligavin/.m2/repository/org/jacoco/org.jacoco.agent/0.8.7/org.jacoco.agent-0.8.7-runtime.jar=destfile=/workplace/oligavin/external/aws-sdk-java-v2/target/jacoco.exec,excludes=software/amazon/awssdk/modulepath/tests/**/*.class:software/amazon/awssdk/nativeimage
test/**/*.class:software/amazon/awssdk/testutils/service/**/*.class:**/*Benchmark.class
[INFO]                                                                 
[INFO] --- build-helper-maven-plugin:3.3.0:add-test-source (add-integ-sources) @ aws-sdk-java-pom ---
[INFO] Test Source directory: /workplace/oligavin/external/aws-sdk-java-v2/src/it/java added.
[INFO]                                                                
[INFO] --- build-helper-maven-plugin:3.3.0:add-test-resource (add-integ-resources) @ aws-sdk-java-pom ---                                                                                                                                                                                                 
[INFO]                                                                
[INFO] --- build-helper-maven-plugin:3.3.0:add-source (add-generated-sources) @ aws-sdk-java-pom ---
[INFO] Source directory: /workplace/oligavin/external/aws-sdk-java-v2/target/generated-sources/sdk added.
[INFO]                                                                
[INFO] --- build-helper-maven-plugin:3.3.0:add-resource (add-license-notice) @ aws-sdk-java-pom ---
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:                                           
[INFO]                                                            
[INFO] AWS Java SDK :: Build Tools ....................... SUCCESS [0.366s]
[INFO] AWS Java SDK :: Parent ............................ FAILURE [0.920s]                                                                                                                                                                                                                               
[INFO] AWS Java SDK :: Core .............................. SKIPPED
[INFO] AWS Java SDK :: Annotations ....................... SKIPPED
[INFO] AWS Java SDK :: Utilities ......................... SKIPPED
...
...
...
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.652s
[INFO] Finished at: Wed Jul 13 19:51:05 UTC 2022
[INFO] Final Memory: 87M/1233M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:build-helper-maven-plugin:3.3.0:add-resource (add-license-notice) on project aws-sdk-java-pom: Execution add-license-notice of goal org.codehaus.mojo:build-helper-maven-plugin:3.3.0:add-resource failed. NullPointerException -> [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/PluginExecutionException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <goals> -rf :aws-sdk-java-pom

I am following these steps: https://github.com/aws/aws-sdk-java-v2/blob/master/docs/GettingStarted.md

What am I doing wrong here?

Links

https://github.com/aws/aws-sdk-java-v2/blob/master/docs/GettingStarted.md

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
debora-itocommented, Jul 15, 2022

Thank you for the help @maciejwalkowiak. We should update our instructions to use ./mvnw.

@OliverGavin let us know if you have any further questions.

0reactions
github-actions[bot]commented, Jul 20, 2022

It looks like this issue has not been active for more than five days. In the absence of more information, we will be closing this issue soon. If you find that this is still a problem, please add a comment to prevent automatic closure, or if the issue is already closed please feel free to reopen it.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Failed to execute goal org.codehaus.mojo:exec-maven-plugin ...
I had a similar problem. As it turned out, I ran mvn clean package install. Correct way is mvn clean install.
Read more >
Starting an Open Source Project - Linux Foundation
This guide was created to help enterprises already well versed in open source learn what they need to know to start their own...
Read more >
ChangeLog.txt - ECLiPSe-CLP
fixed a problem where search/5 aborts with a ground var list, and there is no valid space. This is because search did not...
Read more >
History - Apache Calcite
This release fixes CVE-2022-39135, an XML External Entity (XEE) vulnerability that allows a SQL query to read the contents of files via the...
Read more >
What's new on DevDocs | Magento 2 开发文档中国镜像
Description Versions Type Date Updated the REST schema for 2.3.3 and 2.2.10. 2.2.10, 2.3.3 Major update October 8 Regenerated the Module Reference Guide. 2.3.3 New...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found