Updated Maven dependencies and still getting warnings - maven

I have an old POM file that is referencing dependencies from the now defunct codehaus repository. I have done:
$ mvn dependency:resolve AND mvn clean install -U
Both return:
[INFO] Scanning for projects...
Downloading from codehaus.org:
http://repository.codehaus.org/org/codehaus/groovy/groovy-eclipse-batch/maven-metadata.xml
Downloading from codehaus-snapshots: http://nexus.codehaus.org/snapshots/org/codehaus/groovy/groovy-eclipse-batch/maven-metadata.xml
[WARNING] Could not transfer metadata org.codehaus.groovy:groovy-eclipse-batch/maven-metadata.xml from/to codehaus.org (http://repository.codehaus.org): repository.codehaus.org: unknown error
[WARNING] Could not transfer metadata org.codehaus.groovy:groovy-eclipse-batch/maven-metadata.xml from/to codehaus-snapshots (http://nexus.codehaus.org/snapshots/): nexus.codehaus.org: unknown error
If I go to my ~/.ms/repository/org/groovy I see that the repositories have been updated and the jars are there for groovy-eclipse-batch and groovy-all.
Is there anything else I need to do? The POM file I am trying to update is located here:
https://github.com/apache/usergrid/blob/master/deployment/aws/pom.xml
Any help would be appreciated.

Related

GCLOUD Artifact Registry: Permissions error downloading maven dependency uploaded manually with Cloud Build

I have uploaded manually an maven dependency to my artifact repository
From my local PC, "mvn install" download correctly every maven dependency from the artifact repository, included my manually uploaded dependency.
mvn -U clean install -DskipTests=true
[INFO] Scanning for projects...
[INFO]
[INFO] -----------------< com.healthcentrix.prevvy:frontend >------------------
[INFO] Building frontend 2.1-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
Downloading from cloud-artifacts: artifactregistry://us-central1-maven.pkg.dev/prevvy1/artifacts/org/moxieapps/gwt/highcharts/1.7.2/highcharts-1.7.2.pom
Downloaded from cloud-artifacts: artifactregistry://us-central1-maven.pkg.dev/prevvy1/artifacts/org/moxieapps/gwt/highcharts/1.7.2/highcharts-1.7.2.pom (401 B at 90 B/s)
Downloading from cloud-artifacts: artifactregistry://us-central1-maven.pkg.dev/prevvy1/artifacts/org/moxieapps/gwt/highcharts/1.7.2/highcharts-1.7.2.jar
Downloaded from cloud-artifacts: artifactregistry://us-central1-maven.pkg.dev/prevvy1/artifacts/org/moxieapps/gwt/highcharts/1.7.2/highcharts-1.7.2.jar (521 kB at 376 kB/s)
From Cloud Build or cloud-build-local, we got an permission error
[ERROR] Failed to execute goal on project frontend: Could not resolve dependencies for project com.healthcentrix.prevvy:frontend:jar:2.1-SNAPSHOT:
Failed to collect dependencies at org.moxieapps.gwt:highcharts:jar:1.7.2:
Failed to read artifact descriptor for org.moxieapps.gwt:highcharts:jar:1.7.2:
Could not transfer artifact org.moxieapps.gwt:highcharts:pom:1.7.2 from/to cloud-artifacts (artifactregistry://us-central1-maven.pkg.dev/prevvy1/artifacts):
Permission denied on remote repository (or it may not exist).
The request had no credentials because none were available from the environment.
Ensure that either 1) You are logged into gcloud or 2) Application default credentials are setup (see https://developers.google.com/accounts/docs/application-default-credentials for more information). 403 Forbidden
Step #0: [builder] [ERROR] {"error":"Permission "artifactregistry.repositories.downloadArtifacts" denied on resource "projects/prevvy1/locations/us-central1/repositories/artifacts" (or it may not exist)"}
Our Cloud build Project service account has every Artifact Registry permission, and is downloading the rest of depedencies excluding this specific artifact, which was uploaded manually
is necessary to give some specific permissions to this specific artifact? how?
Thanks in advance for any guidance
Regards

How to consume a published OLP schema dependency?

This question is a minimum reproducible example based on the tutorial Build a Batch Pipeline with Maven Archetypes (Scala), though we are unable to consume a schema artifact in a pipeline we are building for a customer.
We have a separate repository we want to publish (mvn deploy) the schema from. We ran setup equivalent to (replace djv with your own unique string):
$ mvn archetype:generate -DarchetypeGroupId=org.codehaus.mojo.archetypes \
-DarchetypeArtifactId=pom-root \
-DarchetypeVersion=1.1 \
-DgroupId=com.example.djv \
-DartifactId=nodecardinality \
-Dversion=1.0.0 \
-Dpackage=com.example.djv.nodecardinality
...
$ cd nodecardinality
$ mvn archetype:generate -DarchetypeGroupId=com.here.platform.schema \
-DarchetypeArtifactId=project_archetype \
-DarchetypeVersion=1.0.13 \
-DgroupId=com.example.djv.nodecardinality \
-DartifactId=schema \
-Dversion=1.0.0 \
-Dpackage=com.example.djv.nodecardinality.schema \
-DmajorVersion=1
...
$ cat << EOF > schema/proto/src/main/proto/com/example/djv/nodecardinality/schema/v1/schema.proto
syntax = "proto3";
>
> package com.example.djv.nodecardinality.schema.v1;
>
> message NodeCardinalityPartition {
> repeated NodeCardinality node_cardinality = 1;
> }
>
> message NodeCardinality {
> string id = 1;
> uint32 cardinality = 2;
> }
> EOF
$ # <edit schema/ds/pom.xml per the tutorial>
$ cd schema
$ mvn deploy
Primary symptom
In the OLP Portal, I can see my new schema in the list of Schemas. It explains that I can add a dependency on it like so:
<dependency>
<groupId>com.example.djv.nodecardinality</groupId>
<artifactId>schema_v1_scala_2.11</artifactId>
<version>1.0.0</version>
<type>jar</type>
</dependency>
However, I cannot download the artifact in the processor project:
$ cd processor
$ mvn install
...
[INFO] Building processor Direct1toN Batch Processor in Scala 1.0.0
[INFO] --------------------------------[ jar ]---------------------------------
Downloading from HERE_PLATFORM_REPO: https://repo.platform.here.com/artifactory/open-location-platform/com/example/djv/nodecardinality/1.0.0/nodecardinality-1.0.0.pom
Downloading from OLP Public repo: https://artifactory.in.here.com/artifactory/here-olp-sit/com/example/djv/nodecardinality/1.0.0/nodecardinality-1.0.0.pom
Downloading from central: https://repo.maven.apache.org/maven2/com/example/djv/nodecardinality/1.0.0/nodecardinality-1.0.0.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
...
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project processor: Could not resolve dependencies for project com.example.nodecardinality:processor:jar:1.0.0: Failed to collect dependencies at com.example.djv.nodecardinality:schema_v1_scala_2.11:jar:1.0.0: Failed to read artifact descriptor for com.example.djv.nodecardinality:schema_v1_scala_2.11:jar:1.0.0: Could not transfer artifact com.example.djv:nodecardinality:pom:1.0.0 from/to HERE_PLATFORM_ARTIFACT (here+artifact-service://artifact-service): Cannot access here+artifact-service://artifact-service with type here using the available connector factories: BasicRepositoryConnectorFactory: Cannot access here+artifact-service://artifact-service with type here using the available layout factories: Maven2RepositoryLayoutFactory: Unsupported repository layout here -> [Help 1]
...
We see this failure only because we are running the processor project build on the same machine that we ran mvn deploy for the schema project so some files exists in the ~/.m2 cache. Without these files the download just fails:
[INFO] --------------------------------[ jar ]---------------------------------
Downloading from HERE_PLATFORM_REPO: https://repo.platform.here.com/artifactory/open-location-platform/com/example/djv/nodecardinality/schema_v1_scala_2.11/1.0.0/schema_v1_scala_2.11-1.0.0.pom
Downloading from OLP Public repo: https://artifactory.in.here.com/artifactory/here-olp-sit/com/example/djv/nodecardinality/schema_v1_scala_2.11/1.0.0/schema_v1_scala_2.11-1.0.0.pom
Downloading from central: https://repo.maven.apache.org/maven2/com/example/djv/nodecardinality/schema_v1_scala_2.11/1.0.0/schema_v1_scala_2.11-1.0.0.pom
[WARNING] The POM for com.example.djv.nodecardinality:schema_v1_scala_2.11:jar:1.0.0 is missing, no dependency information available
Downloading from HERE_PLATFORM_REPO: https://repo.platform.here.com/artifactory/open-location-platform/com/example/djv/nodecardinality/schema_v1_scala_2.11/1.0.0/schema_v1_scala_2.11-1.0.0.jar
Downloading from OLP Public repo: https://artifactory.in.here.com/artifactory/here-olp-sit/com/example/djv/nodecardinality/schema_v1_scala_2.11/1.0.0/schema_v1_scala_2.11-1.0.0.jar
Downloading from central: https://repo.maven.apache.org/maven2/com/example/djv/nodecardinality/schema_v1_scala_2.11/1.0.0/schema_v1_scala_2.11-1.0.0.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
...
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project processor: Could not resolve dependencies for project com.example.nodecardinality:processor:jar:1.0.0: Could not find artifact com.example.djv.nodecardinality:schema_v1_scala_2.11:jar:1.0.0 in HERE_PLATFORM_REPO (https://repo.platform.here.com/artifactory/open-location-platform/) -> [Help 1]
Secondary symptom
As we saw above, running mvn deploy from a local schema directory doesn't put everything required to build in the local ~/.m2 repository (that is, to build the processor sub-project). To put the required files in the local ~/.m2 repository we need to run mvn install from the parent directory (nodecardinality) of the schema repository.
This allows us to at least develop locally (temporarily).
Partial resolution
Follow the instructions in the section Artifact Service on the page Dependency Management ยท OLP SDK. Although the build gets farther, it still isn't able to pull the dependency:
[INFO] --------------------------------[ jar ]---------------------------------
Downloading from HERE_PLATFORM_REPO: https://repo.platform.here.com/artifactory/open-location-platform/com/example/djv/nodecardinality/schema_v1_scala_2.11/1.0.0/schema_v1_scala_2.11-1.0.0.pom
Downloading from OLP Public repo: https://artifactory.in.here.com/artifactory/here-olp-sit/com/example/djv/nodecardinality/schema_v1_scala_2.11/1.0.0/schema_v1_scala_2.11-1.0.0.pom
Downloading from HERE_PLATFORM_ARTIFACT: here+artifact-service://artifact-service/com.example.djv.nodecardinality/schema_v1_scala_2.11/1.0.0/schema_v1_scala_2.11-1.0.0.pom
Downloaded from HERE_PLATFORM_ARTIFACT: here+artifact-service://artifact-service/com.example.djv.nodecardinality/schema_v1_scala_2.11/1.0.0/schema_v1_scala_2.11-1.0.0.pom (3.4 kB at 1.6 kB/s)
Downloading from HERE_PLATFORM_REPO: https://repo.platform.here.com/artifactory/open-location-platform/com/example/djv/nodecardinality/schema_v1/1.0.0/schema_v1-1.0.0.pom
Downloading from OLP Public repo: https://artifactory.in.here.com/artifactory/here-olp-sit/com/example/djv/nodecardinality/schema_v1/1.0.0/schema_v1-1.0.0.pom
Downloading from HERE_PLATFORM_ARTIFACT: here+artifact-service://artifact-service/com.example.djv.nodecardinality/schema_v1/1.0.0/schema_v1-1.0.0.pom
Downloaded from HERE_PLATFORM_ARTIFACT: here+artifact-service://artifact-service/com.example.djv.nodecardinality/schema_v1/1.0.0/schema_v1-1.0.0.pom (8.0 kB at 6.3 kB/s)
Downloading from HERE_PLATFORM_REPO: https://repo.platform.here.com/artifactory/open-location-platform/com/example/djv/nodecardinality/1.0.0/nodecardinality-1.0.0.pom
Downloading from OLP Public repo: https://artifactory.in.here.com/artifactory/here-olp-sit/com/example/djv/nodecardinality/1.0.0/nodecardinality-1.0.0.pom
Downloading from HERE_PLATFORM_ARTIFACT: here+artifact-service://artifact-service/com.example.djv/nodecardinality/1.0.0/nodecardinality-1.0.0.pom
Downloading from central: https://repo.maven.apache.org/maven2/com/example/djv/nodecardinality/1.0.0/nodecardinality-1.0.0.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
...
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project processor: Could not resolve dependencies for project com.example.nodecardinality:processor:jar:1.0.0: Failed to collect dependencies at com.example.djv.nodecardinality:schema_v1_scala_2.11:jar:1.0.0: Failed to read artifact descriptor for com.example.djv.nodecardinality:schema_v1_scala_2.11:jar:1.0.0: Could not find artifact com.example.djv:nodecardinality:pom:1.0.0 in HERE_PLATFORM_REPO (https://repo.platform.here.com/artifactory/open-location-platform/) -> [Help 1]
OLP Schemas are deployed to HERE Artifact Service. The service requires special authorization. In order to download a schema or java/scala binding you should include Maven Wagon in your project. Please refer to "Artifact Service" section in https://developer.here.com/olp/documentation/sdk-developer-guide/dev_guide/topics/dependency-management.html
In short:
Add version of the wagon as a property:
<artifact.wagon.version>1.6.1</artifact.wagon.version>
Add a placeholder repository to the list of repositories:
<repositories>
<repository>
<id>HERE_PLATFORM_ARTIFACT</id>
<layout>default</layout>
<url>here+artifact-service://artifact-service</url>
</repository>
</repositories>
Put the plugin reference in build section:
<extensions>
<extension>
<groupId>com.here.platform.artifact</groupId>
<artifactId>artifact-wagon</artifactId>
<version>${artifact.wagon.version}</version>
</extension>
</extensions>
Note that your need valid 'credentials.properties' file saved in ~/.here directory. How to get it please read https://developer.here.com/olp/documentation/sdk-developer-guide/dev_guide/topics/get-credentials.html
Best regards,
Dima
The issue is deployment with a parent Maven project. See the last sentence of the last error in the question:
Could not find artifact com.example.djv:nodecardinality:pom:1.0.0 in HERE_PLATFORM_REPO
The com.example.djv:nodecardinality:pom:1.0.0 POM was never uploaded when we ran mvn deploy from the schema directory. You cannot run mvn deploy from the top-level nodecardinality directory.
The simple solution is to remove the parent project pointer from the pom.xml in the schema directory before you run mvn deploy:
<!-- <parent>
<artifactId>nodecardinality</artifactId>
<groupId>com.example.djv</groupId>
<version>1.0.0</version>
</parent> -->

Attempting to build Netbeans project using Maven

I'm currently working on deploying a Vaadin web application project to a GlassFish 4 server using Netbeans. On my local computer (running Windows 10), I can successfully deploy the file by simply using asadmin deploy (inside glassfish/bin) on the war file associated with the project. I can also just run the project inside NetBeans.
I then proceeded to scp over the project files to an Ubuntu (v. 16.04.4) environment, and also the GlassFish files. However, when I attempted the same technique this time, and then accessed the address of the Ubuntu environment via a browser in my local computer (since my project is scheduled to run on localhost, so in this case, the local host there would be a remote domain on my local computer), there was an HTTP error (resource not found).
My first hunch (and only one due to certain following circumstances) was that I needed to rebuild the war file inside the Ubuntu environment; naturally, since I had originally build the war file by building the NetBeans project, I thought I would do the same again. I then followed the instructions here:
https://platform.netbeans.org/tutorials/nbm-maven-commandline.html
Unfortunately during Step 5 of the very first section (Creating the NetBeans Platform Application), I ran into the following error log:
[INFO] Scanning for projects...
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-clean-plugin:2.5: Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-clean-plugin:jar:2.5
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.5.2/maven-install-plugin-2.5.2.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-install-plugin:2.5.2: Plugin org.apache.maven.plugins:maven-install-plugin:2.5.2 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-install-plugin:jar:2.5.2
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-deploy-plugin/2.7/maven-deploy-plugin-2.7.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-deploy-plugin:2.7: Plugin org.apache.maven.plugins:maven-deploy-plugin:2.7 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-deploy-plugin:jar:2.7
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-site-plugin/3.3/maven-site-plugin-3.3.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-site-plugin:3.3: Plugin org.apache.maven.plugins:maven-site-plugin:3.3 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-site-plugin:jar:3.3
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-antrun-plugin/1.7/maven-antrun-plugin-1.7.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-antrun-plugin:1.7: Plugin org.apache.maven.plugins:maven-antrun-plugin:1.7 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-antrun-plugin:jar:1.7
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-assembly-plugin/2.4.1/maven-assembly-plugin-2.4.1.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-assembly-plugin:2.4.1: Plugin org.apache.maven.plugins:maven-assembly-plugin:2.4.1 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-assembly-plugin:jar:2.4.1
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-dependency-plugin/2.8/maven-dependency-plugin-2.8.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-dependency-plugin:2.8: Plugin org.apache.maven.plugins:maven-dependency-plugin:2.8 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-dependency-plugin:jar:2.8
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-release-plugin/2.3.2/maven-release-plugin-2.3.2.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-release-plugin:2.3.2: Plugin org.apache.maven.plugins:maven-release-plugin:2.3.2 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-release-plugin:jar:2.3.2
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-metadata.xml
Downloading: https://repo.maven.apache.org/maven2/org/codehaus/mojo/maven-metadata.xml
[WARNING] Could not transfer metadata org.apache.maven.plugins/maven-metadata.xml from/to central (https://repo.maven.apache.org/maven2): Connect to repo.maven.apache.org:443 [repo.maven.apache.org/151.101.40.215] failed: Connection timed out (Connection timed out)
[WARNING] Could not transfer metadata org.codehaus.mojo/maven-metadata.xml from/to central (https://repo.maven.apache.org/maven2): Connect to repo.maven.apache.org:443 [repo.maven.apache.org/151.101.40.215] failed: Connection timed out (Connection timed out)
[WARNING] Failure to transfer org.apache.maven.plugins/maven-metadata.xml from https://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced. Original error: Could not transfer metadata org.apache.maven.plugins/maven-metadata.xml from/to central (https://repo.maven.apache.org/maven2): Connect to repo.maven.apache.org:443 [repo.maven.apache.org/151.101.40.215] failed: Connection timed out (Connection timed out)
[WARNING] Failure to transfer org.codehaus.mojo/maven-metadata.xml from https://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced. Original error: Could not transfer metadata org.codehaus.mojo/maven-metadata.xml from/to central (https://repo.maven.apache.org/maven2): Connect to repo.maven.apache.org:443 [repo.maven.apache.org/151.101.40.215] failed: Connection timed out (Connection timed out)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 19:05 min
[INFO] Finished at: 2018-07-06T08:25:02-07:00
[INFO] Final Memory: 12M/609M
[INFO] ------------------------------------------------------------------------
[ERROR] No plugin found for prefix 'archetype' in the current project and in the plugin groups [org.apache.maven.plugins, org.codehaus.mojo] available from the repositories [local (/home/lab/.m2/repository), central (https://repo.maven.apache.org/maven2)] -> [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/NoPluginFoundForPrefixException
So, I searched online for this issue, and I found someone with a similar issue:
Maven: Failed to retrieve plugin descriptor error
I followed the responder's solution and added in a proxy to the settings.xml file. One discrepancy, however, is that my settings.xml file was inside usr/share/maven/conf instead of .m2 (which from what I've gathered from some online searching, doesn't exist in Ubuntu); to cover my bases, I thus created a .m2 folder in the Ubuntu environment and scp'ed over all the files in my (local) .m2 folder, and then copied the settings.xml file present in usr/share/maven/conf to .m2. Here's a screenshot of the edited part in the settings.xml file:
After changing that (it was originally commented, so I just had to uncomment and fill in a few things), I tried running the netbeans setup again. However, the output was almost identical, except sometimes there were a few extra references to the proxy I used at the end of the warning messages:
[INFO] Scanning for projects...
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-clean-plugin:2.5: Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-clean-plugin:jar:2.5
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.5.2/maven-install-plugin-2.5.2.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-install-plugin:2.5.2: Plugin org.apache.maven.plugins:maven-install-plugin:2.5.2 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-install-plugin:jar:2.5.2
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-deploy-plugin/2.7/maven-deploy-plugin-2.7.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-deploy-plugin:2.7: Plugin org.apache.maven.plugins:maven-deploy-plugin:2.7 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-deploy-plugin:jar:2.7
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-site-plugin/3.3/maven-site-plugin-3.3.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-site-plugin:3.3: Plugin org.apache.maven.plugins:maven-site-plugin:3.3 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-site-plugin:jar:3.3
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-antrun-plugin/1.7/maven-antrun-plugin-1.7.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-antrun-plugin:1.7: Plugin org.apache.maven.plugins:maven-antrun-plugin:1.7 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-antrun-plugin:jar:1.7
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-assembly-plugin/2.4.1/maven-assembly-plugin-2.4.1.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-assembly-plugin:2.4.1: Plugin org.apache.maven.plugins:maven-assembly-plugin:2.4.1 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-assembly-plugin:jar:2.4.1
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-dependency-plugin/2.8/maven-dependency-plugin-2.8.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-dependency-plugin:2.8: Plugin org.apache.maven.plugins:maven-dependency-plugin:2.8 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-dependency-plugin:jar:2.8
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-release-plugin/2.3.2/maven-release-plugin-2.3.2.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-release-plugin:2.3.2: Plugin org.apache.maven.plugins:maven-release-plugin:2.3.2 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-release-plugin:jar:2.3.2
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-metadata.xml
Downloading: https://repo.maven.apache.org/maven2/org/codehaus/mojo/maven-metadata.xml
[WARNING] Could not transfer metadata org.apache.maven.plugins/maven-metadata.xml from/to central (https://repo.maven.apache.org/maven2): http://proxy.esl.cisco.com/
[WARNING] Could not transfer metadata org.codehaus.mojo/maven-metadata.xml from/to central (https://repo.maven.apache.org/maven2): http://proxy.esl.cisco.com/
[WARNING] Failure to transfer org.apache.maven.plugins/maven-metadata.xml from https://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced. Original error: Could not transfer metadata org.apache.maven.plugins/maven-metadata.xml from/to central (https://repo.maven.apache.org/maven2): http://proxy.esl.cisco.com/
[WARNING] Failure to transfer org.codehaus.mojo/maven-metadata.xml from https://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced. Original error: Could not transfer metadata org.codehaus.mojo/maven-metadata.xml from/to central (https://repo.maven.apache.org/maven2): http://proxy.esl.cisco.com/
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.358 s
[INFO] Finished at: 2018-07-06T09:41:15-07:00
[INFO] Final Memory: 12M/609M
[INFO] ------------------------------------------------------------------------
[ERROR] No plugin found for prefix 'archetype' in the current project and in the plugin groups [org.apache.maven.plugins, org.codehaus.mojo] available from the repositories [local (/home/lab/.m2/repository), central (https://repo.maven.apache.org/maven2)] -> [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/NoPluginFoundForPrefixException
The second website I found where someone had a similar issue was this:
https://communities.bmc.com/thread/160101
However, in the responder's solution, I don't even know what SDK he's referring to, and a search of the entire file system in the Ubuntu environment revealed exactly 0 occurrences of archetype-catalog.xml (via find . -name "archetype-catalog")
So, any suggestions?
EDIT:
To clarify what my questions exactly are, they are the following:
1) Is my assumption correct that I can build a war locally and deploy it locally and have it work correctly, yet attempting to deploy the same war in a different address might result in erroneous behavior? More to the point, should I even worry about building the war in the Ubuntu environment? Because if not, I should probably start looking for other possible errors.
2) Why is maven not setting up Netbeans correctly EVEN AFTER adding the proxy to settings.xml?
3) Is there an Ubuntu-ized version of the solution that the person in the second website I visited (https://communities.bmc.com/thread/160101)? I.e., is there something similar to archetype-catalog that I can manipulate to solve the not-being-able-to-setup-Netbeans issue?
UPDATE:
So, I think I have the answer to the first question, though I'd still like the 2nd and 3rd questions answered so I'll still leave this post as unanswered. As for the first question, I think the answer is yes. I managed to get a workaround for all my woes of using netbeans to recompile the WAR via CLI inputs; instead, I set up a VNC connection for the Ubuntu environment and was then able to access it as a GUI. From there, I simply installed Netbeans, and rebuilt the project using the GUI version of Netbeans. This was not without struggles, but after I eventually got there, I tried accessing my project from my local (Windows environment), and it worked as expected.
OK I've found the answer to my problems; looking down at other solutions on the Stack Overflow responses, I found that one person stated that the http proxy must be before the https proxy; I originally didn't even have the https proxy there (just the http), but I thought why not give it a shot anyways, and after adding the https proxy, the "failed to retrieve plugin descriptor warnings disappeared.

MAVEN dependency failed

Please see below I am not able to run maven project on eclipse
1) downloaded eclipse
2) downloaded MAVEN repository
3) set env variable M2_HOME, MAVEN_HOME, JAVA_HOME
4) SET path to maven bin folder
and mvn -version is working fine
in below case its failed to update maven while running from cmd please help
C:\Users\sridhar.m> mvn eclipse:eclipse
[INFO] Scanning for projects...
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven
-clean-plugin/2.5/maven-clean-plugin-2.5.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:mave
n-clean-plugin:2.5: Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or on
e of its dependencies could not be resolved: Failed to read artifact descriptor
for org.apache.maven.plugins:maven-clean-plugin:jar:2.5
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven
-install-plugin/2.4/maven-install-plugin-2.4.pom
[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:mave
n-install-plugin:2.4: Plugin org.apache.maven.plugins:maven-install-plugin:2.4 o
r one of its dependencies could not be resolved: Failed to read artifact descrip
tor for org.apache.maven.plugins:maven-install-plugin:jar:2.4
Have you copied your settings.xml to your .m2 folder (your M2_HOME)?
Also have you set your proxy correctly (in the settings.xml) so your maven can get out to the internet?
Hope this helps.
May be you didn't configure the installation of your Maven in Eclipse
You have to go in Eclispe -> Window -> Preferences -> Maven and choose the Installations and add the path of your repository Maven and NOT let the EMBEDDED folder .
If it's not working you maybe have a problem of proxy so you have to configure it in the file setting.xml Under Path to Maven\conf\setting.xml
GL.

Nexus refusing to download artifacts?

I'm trying to integrate the Atlassian Clover plugin to work with my existing Maven 3 project. I'm also using Nexus 2.6.3. e.g.
mvn clover2:setup test clover2:aggregate clover2:clover
produces the error:
[ERROR] Failed to execute goal com.atlassian.maven.plugins:maven-clover2-plugin:3.2.0:instrumentInternal (default-cli) on project hpcmom: Execution default-cli of goal com.atlassian.maven.plugins:maven-clover2-plugin:3.2.0:instrumentInternal failed: Plugin com.atlassian.maven.plugins:maven-clover2-plugin:3.2.0 or one of its dependencies could not be resolved: The following artifacts could not be resolved: org.apache.ant:ant:jar:1.8.4, com.cenqua.clover:clover:jar:3.2.0: Could not find artifact org.apache.ant:ant:jar:1.8.4 in nexus (http://olympus:8081/nexus/content/groups/public) -> [Help 1]
And this is not true, I can see and download manually the supposedly missing artifacts org.apache.ant:ant:jar:1.8.4 correctly in Central and even from the Remote repository tab view I can also find the needed artifacts.
My build also results in the following errors:
Downloading: http://olympus:8081/nexus/content/groups/public/org/codehaus/plexus/plexus-compiler-api/2.2/plexus-compiler-api-2.2.pom
[WARNING] The POM for org.codehaus.plexus:plexus-compiler-api:jar:2.2 is missing, no dependency information available
Downloading: http://olympus:8081/nexus/content/groups/public/org/apache/ant/ant/1.8.4/ant-1.8.4.pom
[WARNING] The POM for org.apache.ant:ant:jar:1.8.4 is missing, no dependency information available
Downloading: http://olympus:8081/nexus/content/groups/public/org/apache/ant/ant-launcher/1.8.4/ant-launcher-1.8.4.pom
[WARNING] The POM for org.apache.ant:ant-launcher:jar:1.8.4 is missing, no dependency information available
Downloading: http://olympus:8081/nexus/content/groups/public/org/apache/maven/reporting/maven-reporting-impl/2.0.5/maven-reporting-impl-2.0.5.pom
[WARNING] The POM for org.apache.maven.reporting:maven-reporting-impl:jar:2.0.5 is missing, no dependency information available
Downloading: http://olympus:8081/nexus/content/groups/public/com/cenqua/clover/clover/3.2.0/clover-3.2.0.pom
[WARNING] The POM for com.cenqua.clover:clover:jar:3.2.0 is missing, no dependency information available
Downloading: http://olympus:8081/nexus/content/groups/public/com/intellij/annotations/9.0.4/annotations-9.0.4.pom
[WARNING] The POM for com.intellij:annotations:jar:9.0.4 is missing, no dependency information available
Downloading: http://olympus:8081/nexus/content/groups/public/org/apache/ant/ant/1.8.4/ant-1.8.4.jar
Downloading: http://olympus:8081/nexus/content/groups/public/com/cenqua/clover/clover/3.2.0/clover-3.2.0.jar
Make sure the Central repository is part of your public group. Check out the configuration and potentially check by browsing the remote repo from within Nexus to make sure no network issue prevents Nexus from connecting to the Central repo to download these jars.
Once you have confirmed force an update since Maven might have cached the fact that components were not found in your local repo. Use
mvn -U clover2:setup test clover2:aggregate clover2:clover

Resources