Uploaded image for project: 'Maven Archetype'
  1. Maven Archetype
  2. ARCHETYPE-161

RemoteCatalogArchetypeDataSource don't allow to download arbitrary urls

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.0-alpha-3
    • 2.0-alpha-4
    • None
    • None

    Description

      org.apache.maven.archetype.Archetype class has the following JavaDoc:

          /**
           * Gives the catalog of archetypes located at the given url.
           * if the url doesn't define a catalog, then 'archetype-catalog.xml' is appended to it for search.
           * @param url the catalog url or base url containing the catalog file.
           * @return the catalog.
           */
          ArchetypeCatalog getRemoteCatalog( String url );
      

      However implementation of the org.apache.maven.archetype.source.RemoteCatalogArchetypeDataSource.getArchetypeCatalog(..) method does not respect above contract and always assume that url is pointing to some folder that contains archetype-catalog.xml file.

      This is very confusing and also prevent to publish multiple archetype catalogs in the same folder.

      Attachments

        Activity

          People

            Unassigned Unassigned
            eu Eugene Kuleshov
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: