[DOCS-60] Developing Apps guidereferences archetypeCatalog, that is not supported anymore Created: 07/Feb/18  Updated: 25/Apr/18  Resolved: 25/Apr/18

Status: Resolved
Project: docs
Component/s: Developer Guide
Affects Version/s: Nitrogen, Oxygen, Fluorine
Fix Version/s: Fluorine

Type: Bug Priority: Medium
Reporter: Luke Hinds Assignee: Michael Vorburger
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Blocks
is blocked by CONTROLLER-1800 Archetype fully working and self-tested Resolved
Duplicate
is duplicated by DOCS-56 maven-archetype-plugin does not make ... Closed

 Description   

ur; http://docs.opendaylight.org/en/stable-nitrogen/developer-guide/developing-apps-on-the-opendaylight-controller.html

 

When following the above, the command:

mvn archetype:generate -DarchetypeGroupId=org.opendaylight.controller -DarchetypeArtifactId=opendaylight-startup-archetype \
-DarchetypeRepository=https://nexus.opendaylight.org/content/repositories/public/ \
-DarchetypeCatalog=https://nexus.opendaylight.org/content/repositories/public/archetype-catalog.xml

Fails with:

 

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-archetype-plugin:3.0.1:generate (default-cli) on project standalone-pom: archetypeCatalog 'https://nexus.opendaylight.org/content/repositories/public/archetype-catalog.xml' is not supported anymore. Please read the plugin documentation for details. -> [Help 1] [ERROR]

Build details:

 

$ mvn --version

Picked up _JAVA_OPTIONS: -Dawt.useSystemAAFontSettings=gasp -Dawt.useSystemAAFontSettings=gasp Apache Maven 3.5.2 (NON-CANONICAL_2017-10-25T13:09:52+03:00_root; 2017-10-25T11:09:52+01:00) Maven home: /opt/maven Java version: 1.8.0_152, vendor: Oracle Corporation Java home: /usr/lib/jvm/java-8-openjdk/jre Default locale: en_GB, platform encoding: UTF-8 OS name: "linux", version: "4.14.15-1-arch", arch: "amd64", family: "unix"


$ ls ~/.m2
repository settings.xml

 



 Comments   
Comment by Michael Vorburger [ 17/Apr/18 ]

That documentation is outdated and wrong. I can fix the doc, but we are in process of (see CONTROLLER-1800 and linked RELENG) changing the Maven coordinates (the "GAV") the archetype, so it will look different for the latest master (Fluorine) and previous stable/* (Oxygen, Neutron, ...) releases.

Comment by Michael Vorburger [ 17/Apr/18 ]

The correct command for the latest release from stable/oxygen available today is:

mvn archetype:generate -DarchetypeGroupId=org.opendaylight.controller -DarchetypeArtifactId=opendaylight-startup-archetype -DarchetypeVersion=1.5.0

but this leads to a project that does not quite build (it has some Checkstyle violations, and may be other problems); we should only add this to the doc for Oxygen SP x (1.5.x) if someone still wants to fix up the archetype on a maintenance branch.

It is important to document that one has to run this command with a Maven settings.xml which already uses nexus.opendaylight.org, as the current documentation linked to above states as a pre-requisite - that's why that URL shown (twice) in the original command currently documented and shown above is no longer needed with the latest archetype:generate.

For the latest master (Fluorine), once the linked issues are fully done (notably RELENG-893 to actually deploy to Nexus), it probably will be the same as above, to be tested, but with -DarchetypeGroupId=org.opendaylight.archetypes (instead of controller) and -DarchetypeVersion=1.0.0-SNAPSHOT.

Comment by Michael Vorburger [ 17/Apr/18 ]

FTR: The old controller archetype is also broken (Checkstyle) for Oxygen SP 1 with -DarchetypeVersion=1.5.1-SNAPSHOT.

Once we have finished the set up of the new archetype project (linked issues), I'll therefore contribute a change to the documentation project on master (Fluorine) to fix up the command, but ignore past releases.

Comment by Michael Vorburger [ 17/Apr/18 ]

https://lists.opendaylight.org/pipermail/controller-dev/2018-April/014351.html

Comment by Michael Vorburger [ 18/Apr/18 ]

https://git.opendaylight.org/gerrit/#/c/71077/

Generated at Wed Feb 07 19:58:33 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.