|
|
$ mvn archetype:generate -DarchetypeArtifactId=jersey-quickstart-grizzly2 \ -DarchetypeGroupId=org.glassfish.jersey.archetypes -DinteractiveMode=false \ -DgroupId=com.example -DartifactId=simple-service -Dpackage=com.example \ -DarchetypeVersion=2.23.2
I get the following error:
... [INFO] Generating project in Batch mode [INFO] Archetype repository not defined. Using the one from [org.glassfish.jersey.archetypes:jersey-quickstart-grizzly2:2.23.2] found in catalog remote [INFO] ------------------------------------------------------------------------ [INFO] ------------------------------------------------------------------------ [INFO] Total time: 45.122 s [INFO] Finished at: 2016-09-03T09:29:36-04:00 [INFO] Final Memory: 14M/81M [INFO] ------------------------------------------------------------------------ [ERROR] Failed to execute goal org.apache.maven.plugins:maven-archetype-plugin:2.4:generate (default-cli) on project standalone-pom: The desired archetype does not exist (org.glassfish.jersey.archetypes:jersey-quickstart-grizzly2:2.23.2) -> [Help 1] [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] For more information about the errors and possible solutions, please read the following articles:
I am using Apache Maven 3.3.9 with Java 1.8.0_101.
-- "Hell hath no limits, nor is circumscrib'd In one self-place; but where we are is hell, And where hell is, there must we ever be" --Christopher Marlowe, Doctor Faustus (v. 121-24)
|
|
Hi Thad,
I just did this:
mvn archetype:generate
-DarchetypeArtifactId=jersey-quickstart-grizzly2
-DarchetypeGroupId=org.glassfish.jersey.archetypes
-DinteractiveMode=false -DgroupId=com.example
-DartifactId=simple-service -Dpackage=com.example
-Dmaven.repo.local=./repo
(last param is just to ensure that I'm not using my local repo,
which has jersey in there for sure) and result:
...
[INFO]
----------------------------------------------------------------------------
[INFO] Using following parameters for creating project
from Old (1.x) Archetype: jersey-quickstart-grizzly2:2.23.2
[INFO]
----------------------------------------------------------------------------
[INFO] Parameter: basedir, Value:
/Users/pavel/jersey/jersey/tmo
[INFO] Parameter: package, Value: com.example
[INFO] Parameter: groupId, Value: com.example
[INFO] Parameter: artifactId, Value: simple-service
[INFO] Parameter: packageName, Value: com.example
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[INFO] project created from Old (1.x) Archetype in dir:
/Users/pavel/jersey/jersey/tmo/simple-service
[INFO]
------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 19.128 s
[INFO] Finished at: 2016-09-03T20:14:21+02:00
[INFO] Final Memory: 15M/150M
[INFO]
------------------------------------------------------------------------
Please check your ~/.m2/settings.xml file, https://maven-central.storage.googleapis.com
(from your execution) is very suspicious - maybe you have some
proxies or mirrors defined, which are not mirroring maven central
correctly.
Regards,
Pavel
On 03/09/16 15:43, Thad Humphries wrote:
$ mvn archetype:generate
-DarchetypeArtifactId=jersey-quickstart-grizzly2 \
-DarchetypeGroupId=org.glassfish.jersey.archetypes
-DinteractiveMode=false \
-DgroupId=com.example -DartifactId=simple-service
-Dpackage=com.example \
-DarchetypeVersion=2.23.2
I get the following error:
...
[INFO] Generating project in Batch mode
[INFO] Archetype repository not defined. Using the one
from
[org.glassfish.jersey.archetypes:jersey-quickstart-grizzly2:2.23.2]
found in catalog remote
[INFO]
------------------------------------------------------------------------
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 45.122 s
[INFO] Finished at: 2016-09-03T09:29:36-04:00
[INFO] Final Memory: 14M/81M
[INFO]
------------------------------------------------------------------------
[ERROR] Failed to execute goal
org.apache.maven.plugins:maven-archetype-plugin:2.4:generate
(default-cli) on project standalone-pom: The desired
archetype does not exist
(org.glassfish.jersey.archetypes:jersey-quickstart-grizzly2:2.23.2)
-> [Help 1]
[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] For more information about the errors and
possible solutions, please read the following articles:
I am using Apache Maven 3.3.9 with Java 1.8.0_101.
--
"Hell hath no limits, nor is circumscrib'd In
one self-place; but where we are is hell, And where hell
is, there must we ever be" --Christopher Marlowe, Doctor
Faustus (v. 121-24)
|
|
To my ~/.m2/settings.xml I added:
<name>Java.net Snapshot Repository for Maven</name> <activeProfile>javanet</activeProfile>
and ran your Maven command with -Djavanet. It still failed:
[INFO] ------------------------------------------------------------------------ [INFO] ------------------------------------------------------------------------ [INFO] Total time: 01:31 min [INFO] Finished at: 2016-09-03T18:00:18-04:00 [INFO] Final Memory: 16M/123M [INFO] ------------------------------------------------------------------------ [WARNING] The requested profile "javanet" could not be activated because it does not exist. [ERROR] Failed to execute goal org.apache.maven.plugins:maven-archetype-plugin:2.4:generate (default-cli) on project standalone-pom: The desired archetype does not exist (org.glassfish.jersey.archetypes:jersey-quickstart-grizzly2:2.23.2) -> [Help 1] [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] For more information about the errors and possible solutions, please read the following articles:
|
|
remove it completely (keep the http
proxy if you need it) and try again.
On 04/09/16 00:04, Thad Humphries wrote:
To my ~/.m2/settings.xml I added:
<name>Java.net Snapshot Repository for
Maven</name>
<activeProfile>javanet</activeProfile>
and ran your Maven command with -Djavanet. It still failed:
[INFO] ------------------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:31 min
[INFO] Finished at: 2016-09-03T18:00:18-04:00
[INFO] Final Memory: 16M/123M
[INFO] ------------------------------------------------------------------------
[WARNING] The requested profile "javanet" could not be
activated because it does not exist.
[ERROR] Failed to execute goal
org.apache.maven.plugins:maven-archetype-plugin:2.4:generate
(default-cli) on project standalone-pom: The desired
archetype does not exist (org.glassfish.jersey.archetypes:jersey-quickstart-grizzly2:2.23.2)
-> [Help 1]
[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] For more information about the errors and
possible solutions, please read the following articles:
|
|
Remove the profile? I've tried with and without the profile, both times from an empty directory.
|
|
no, remove your settings.xml.
There is something on you system, which is trying to convince
maven that maven central is https://maven-central.storage.googleapis.com,
which is not correct.
On 04/09/16 00:44, Thad Humphries wrote:
Remove the profile? I've tried with and without the
profile, both times from an empty directory.
|
|
Ah! That did it. Thank you.
I dunno why I put it there. Doubtless some Google library.
Things like this drove me to Gradle a few years back.
|
|
I saw that article as well when
researching why your build is not working, but.. seems like its
not 100% mirror. Not sure what is the motivations behind creating
that.
Anyway, good that it finally works for you.
And BTW, gradle doesn't do anything in terms of library
distribution, it uses maven central as well. So you'd have exactly
the same issue with gradle.
On 04/09/16 01:17, Thad Humphries wrote:
Ah! That did it. Thank you.
I dunno why I put it there. Doubtless some Google library.
Things like this drove me to Gradle a few years back.
|
|