30

In Eclipse with m2eclipse installed, when I choose

File > New > Project... > Maven > Maven Project

with

Use default Workspace location

and

Catalog: Nexus Indexer

selected, the following error message is showing up:

No archetypes currently available. The archetype list will refresh when the indexes finish updating.

Why does this error occur?

Jens Piegsa
  • 7,399
  • 5
  • 58
  • 106
user1169587
  • 1,104
  • 2
  • 17
  • 34

3 Answers3

42

I had same problem and it was solved by adding a remote catalog: http://repo1.maven.org/maven2/archetype-catalog.xml

This solution i found at : http://jira.talendforge.org/secure/attachment/36787/DeveloperGuide-Feedback.pdf

Cris
  • 4,947
  • 6
  • 44
  • 73
  • 4
    Does Maven works well under a proxy? I tried to add this remote catalog and it says: "Remote Catalog is empty". Copying the url in Chrome shows the xml... (I have already configured the proxy settings in Eclipse) – guilhermecgs Aug 08 '14 at 15:48
  • 1
    Its https now in stead of http in the link: https://repo1.maven.org/maven2/archetype-catalog.xml – Prasoon Gupta Jan 18 '20 at 05:04
  • In my case I use px (https://github.com/genotrance/px) as local proxy with debug enabled, and I can see Eclipse using the proxy to access the network. The point is that for this archetypes it does not use the proxy at all. Even if I go in the archetype remote definition and press the "Verify" button. – user1708042 Feb 12 '20 at 09:42
8

in this case you can use another solution, you need to configure a local ctalogue using eclipse :

1- suppose that you need to use mave catalogue : https://repo1.maven.org/maven2/archetype-catalog.xml

2- download from your web broser the file https://repo1.maven.org/maven2/archetype-catalog.xml and save it in ~/.m2/archetype-catalog.xml

3 now go to eclipse "Window-->Preferences-->maven-->Archetypes" then click the "Add Local catalogue" and set the ctalogue file to the ~/.m2/archetype-catalog.xml, save and exit

4- now go back to eclipse and try to create project using your new local catatlogue archetypes, it should work

yu yang Jian
  • 6,680
  • 7
  • 55
  • 80
sofiene zaghdoudi
  • 3,108
  • 2
  • 17
  • 11
  • Thank I would say this looks mora like a workaround, not a solution, doing so you have to update it manually if the provider updates the definitions or it publishes new archetypes – user1708042 Feb 12 '20 at 09:44
1

Updated remote catalog link: https://repo1.maven.org/maven2/archetype-catalog.xml

Either copy the link and add a remote archetype or download the XML file and go for a local archetype option and follow @sofiene-zaghdoudi 's solution.

Sahil Tah
  • 300
  • 1
  • 3
  • 9