Deco Deco - 1 month ago 7
Apache Configuration Question

maven plugins got this error

This server is AWS

Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015- 11-10T16:41:47+00:00)
Maven home: /opt/apache-maven-3.3.9
Java version: 1.8.0_91, vendor: Oracle Corporation
Java home: /usr/lib/jvm/java-8-openjdk-amd64/jre
Default locale: en_US, platform encoding: UTF-8
OS name: "linux", version: "3.13.0-92-generic", arch: "amd64", family: "unix"





Stacktrace:

[ERROR] [ERROR] Some problems were encountered while processing the POMs:
[ERROR] Unresolveable build extension: Plugin org.apache.felix:maven-bundle-plugin:1.4.3 or one of its dependencies could not be resolved: The following artifacts could not be resolved: org.apache.maven:maven-project:jar:2.0.7, org.apache.maven:maven-profile:jar:2.0.7, org.apache.maven:maven-plugin-registry:jar:2.0.7, org.apache.maven:maven-model:jar:2.0.7, org.apache.maven:maven-plugin-api:jar:2.0.7, org.apache.maven:maven-artifact:jar:2.0.7, org.apache.maven:maven-artifact-manager:jar:2.0.7, org.apache.maven:maven-repository-metadata:jar:2.0.7, org.apache.maven:maven-settings:jar:2.0.7, org.apache.maven.wagon:wagon-provider-api:jar:1.0-beta-2, org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9-stable-1, classworlds:classworlds:jar:1.1-alpha-2: Could not transfer artifact org.apache.maven:maven-project:jar:2.0.7 from/to central (https://repo.maven.apache.org/maven2): java.lang.RuntimeException: Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty @
[ERROR] Unknown packaging: bundle @ org.apache.httpcomponents:httpclient-osgi:[unknown-version], /home/ubuntu/testgit/httpclient-osgi/pom.xml, line 42, column 14
@
[ERROR] The build could not read 1 project -> [Help 1]
[ERROR]
[ERROR] The project org.apache.httpcomponents:httpclient-osgi:4.0.4-SNAPSHOT (/home/ubuntu/testgit/httpclient-osgi/pom.xml) has 2 errors
[ERROR] Unresolveable build extension: Plugin org.apache.felix:maven-bundle-plugin:1.4.3 or one of its dependencies could not be resolved: The following artifacts could not be resolved: org.apache.maven:maven-project:jar:2.0.7, org.apache.maven:maven-profile:jar:2.0.7, org.apache.maven:maven-plugin-registry:jar:2.0.7, org.apache.maven:maven-model:jar:2.0.7, org.apache.maven:maven-plugin-api:jar:2.0.7, org.apache.maven:maven-artifact:jar:2.0.7, org.apache.maven:maven-artifact-manager:jar:2.0.7, org.apache.maven:maven-repository-metadata:jar:2.0.7, org.apache.maven:maven-settings:jar:2.0.7, org.apache.maven.wagon:wagon-provider-api:jar:1.0-beta-2, org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9-stable-1, classworlds:classworlds:jar:1.1-alpha-2: Could not transfer artifact org.apache.maven:maven-project:jar:2.0.7 from/to central (https://repo.maven.apache.org/maven2): java.lang.RuntimeException: Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty -> [Help 2]
[ERROR] Unknown packaging: bundle @ org.apache.httpcomponents:httpclient-osgi:[unknown-version], /home/ubuntu/testgit/httpclient-osgi/pom.xml, line 42, column 14
[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]
Build step 'Invoke top-level Maven targets' marked build as failure
Finished: FAILURE

Answer

"java.lang.RuntimeException: Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty"

It means that the truststore you specified was not found, or couldn't be opened due to access permissions

To fix this (in Ubuntu),

sudo /var/lib/dpkg/info/ca-certificates-java.postinst configure

read more : Error - trustAnchors parameter must be non-empty

Comments