You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Johannes Siebel (JIRA)" <ji...@apache.org> on 2017/02/15 09:05:42 UTC

[jira] [Comment Edited] (ARCHETYPE-520) Following mirror configuration from settings.xml for downloading archetype metadata

    [ https://issues.apache.org/jira/browse/ARCHETYPE-520?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15867492#comment-15867492 ] 

Johannes Siebel edited comment on ARCHETYPE-520 at 2/15/17 9:05 AM:
--------------------------------------------------------------------

We've tried using a repository with id {{artifact}} but that didn't affect the behaviour of the archetype generation. Since we're using a wildcard mirror, the mirrors should be picked up by the archetype-plugin anyway (ref. [cc7f9bc4354d7411273ceecdcb46988905c99c16|https://git1-us-west.apache.org/repos/asf?p=maven-archetype.git;a=blobdiff;f=archetype-common/src/main/java/org/apache/maven/archetype/source/RemoteCatalogArchetypeDataSource.java;h=c88dae906d56c4bc01aead24ffa957b5e1795b1f;hp=f10f4a540286773aeafbf7a1ea3fbcd0836d242f;hb=cc7f9bc4;hpb=93318023353fd1a90f9a0b554dffd90f6de0cb56]). 

As I've mentioned above the plugin successfully connects to our nexus and downloads the archetype just fine. The problem is that it _also_ tries to contact {{repo.maven.apache.org}}. 

The snippet below shows the issue at hand:

{code}
[INFO] Generating project in Interactive mode
[DEBUG] Using catalog D:\home\maven\maven-repository\archetype-catalog.xml
[WARNING] Archetype not found in any catalog. Falling back to central repository (http://repo.maven.apache.org/maven2).
[WARNING] Use -DarchetypeRepository=<your repository> if archetype's repository is elsewhere.
[DEBUG] Not found archetype com.acme.maven.archetypes.soa.properties:soa-properties-archetype:1.0.0-SNAPSHOT in cache
[DEBUG] Using connector WagonRepositoryConnector with priority 0 for http://repo.maven.apache.org/maven2
[DEBUG] Using connector WagonRepositoryConnector with priority 0 for http://repo.acme.com/repo/content/groups/public
Downloading: http://repo.maven.apache.org/maven2/com/acme/maven/archetypes/soa/properties/soa-properties-archetype/1.0.0-SNAPSHOT/maven-metadata.xml
Downloading: http://repo.acme.com/repo/content/groups/public/com/acme/maven/archetypes/soa/properties/soa-properties-archetype/1.0.0-SNAPSHOT/maven-metadata.xml
2/2 KB   
         
Downloaded: http://repo.acme.com/repo/content/groups/public/com/acme/maven/archetypes/soa/properties/soa-properties-archetype/1.0.0-SNAPSHOT/maven-metadata.xml (2 KB at 10.9 KB/sec)
{code}


was (Author: johannes.siebel@debeka.de):
We've tried using a repository with id {{artifact}} but that didn't affect the behaviour of the archetype generation. Since we're using a wildcard mirror, the mirrors should be picked up by the archetype-plugin anyway (ref. [cc7f9bc4354d7411273ceecdcb46988905c99c16|https://git1-us-west.apache.org/repos/asf?p=maven-archetype.git;a=blobdiff;f=archetype-common/src/main/java/org/apache/maven/archetype/source/RemoteCatalogArchetypeDataSource.java;h=c88dae906d56c4bc01aead24ffa957b5e1795b1f;hp=f10f4a540286773aeafbf7a1ea3fbcd0836d242f;hb=cc7f9bc4;hpb=93318023353fd1a90f9a0b554dffd90f6de0cb56]). 

As I've mentioned above the plugin successfully connects to our nexus and downloads the archetype just fine. The problem is that it _also_ tries to contact {{repo.maven.apache.org}}. 

The snippet below shows the issue at hand:

{quote}
[INFO] Generating project in Interactive mode
[DEBUG] Using catalog D:\home\maven\maven-repository\archetype-catalog.xml
[WARNING] Archetype not found in any catalog. Falling back to central repository (http://repo.maven.apache.org/maven2).
[WARNING] Use -DarchetypeRepository=<your repository> if archetype's repository is elsewhere.
[DEBUG] Not found archetype com.acme.maven.archetypes.soa.properties:soa-properties-archetype:1.0.0-SNAPSHOT in cache
[DEBUG] Using connector WagonRepositoryConnector with priority 0 for http://repo.maven.apache.org/maven2
[DEBUG] Using connector WagonRepositoryConnector with priority 0 for http://repo.acme.com/repo/content/groups/public
Downloading: http://repo.maven.apache.org/maven2/com/acme/maven/archetypes/soa/properties/soa-properties-archetype/1.0.0-SNAPSHOT/maven-metadata.xml
Downloading: http://repo.acme.com/repo/content/groups/public/com/acme/maven/archetypes/soa/properties/soa-properties-archetype/1.0.0-SNAPSHOT/maven-metadata.xml
2/2 KB   
         
Downloaded: http://repo.acme.com/repo/content/groups/public/com/acme/maven/archetypes/soa/properties/soa-properties-archetype/1.0.0-SNAPSHOT/maven-metadata.xml (2 KB at 10.9 KB/sec)
{quote}

> Following mirror configuration from settings.xml for downloading archetype metadata
> -----------------------------------------------------------------------------------
>
>                 Key: ARCHETYPE-520
>                 URL: https://issues.apache.org/jira/browse/ARCHETYPE-520
>             Project: Maven Archetype
>          Issue Type: Bug
>          Components: Plugin
>    Affects Versions: 3.0.0
>            Reporter: Johannes Siebel
>         Attachments: maven-archetype-delay.TXT, settings.xml
>
>
> Since using the maven-archetype-plugin with version 3.0.0 the plugin tries to connect to _both_ our internal nexus and to {{http://repo.maven.apache.org}} for downloading Maven artifacts used by Archetypes. Since we are using a proxy, the generation of the archetype is delayed until the download of the Maven artifacts times out.
> We'd expect the archetype to only contact our own artifact repository, without trying to connect to {{http://repo.maven.apache.org}} at all.
> I've attached a snippet with the debug output of the archetype:generate goal and the configuration of our mirror.
> We assume this problem is related to ARCHETYPE-358.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)