You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by "Konstantin Ignatyev (JIRA)" <ji...@codehaus.org> on 2005/11/08 21:13:06 UTC
[jira] Created: (MNG-1466) Ant dependencies task does not work with multiple repositories
Ant dependencies task does not work with multiple repositories
--------------------------------------------------------------
Key: MNG-1466
URL: http://jira.codehaus.org/browse/MNG-1466
Project: Maven 2
Type: Bug
Components: maven-artifact-ant
Versions: 2.0.1, 2.0
Environment: Maven 2.0, Maven 2.0 CVS
Reporter: Konstantin Ignatyev
The maven-dependencies task for Ant cannot work properly with multiple repositories because it incorrectly hardcode artifact repository ID that causes all the repositories cache informatioon in the same file
AbstractArtifactTask#
....
artifactRepository = repositoryFactory.createArtifactRepository( "remote", repository.getUrl(),
repositoryLayout, snapshots, releases );
creates all the repositories with the same ID="remote" and that causes all the meta-information for all the repositories collide in one file because the file name pattern is:${gtoupId}/${artifactId}/maven-metadata-${repositoryId}.xml
This causes whole thing work incorrectly.
When Maven itself constructs ArtifactRepository, it properly assigns ID to the repository and the schema works.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
[jira] Updated: (MNG-1466) Ant dependencies task does not work with multiple repositories
Posted by "John Casey (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-1466?page=all ]
John Casey updated MNG-1466:
----------------------------
Fix Version: 2.0.1
> Ant dependencies task does not work with multiple repositories
> --------------------------------------------------------------
>
> Key: MNG-1466
> URL: http://jira.codehaus.org/browse/MNG-1466
> Project: Maven 2
> Type: Bug
> Components: maven-artifact-ant
> Versions: 2.0.1, 2.0
> Environment: Maven 2.0, Maven 2.0 CVS
> Reporter: Konstantin Ignatyev
> Assignee: John Casey
> Fix For: 2.0.1
> Attachments: id.diff, id2.diff
>
>
> The maven-dependencies task for Ant cannot work properly with multiple repositories because it incorrectly hardcode artifact repository ID that causes all the repositories cache informatioon in the same file
> AbstractArtifactTask#
> ....
> artifactRepository = repositoryFactory.createArtifactRepository( "remote", repository.getUrl(),
> repositoryLayout, snapshots, releases );
> creates all the repositories with the same ID="remote" and that causes all the meta-information for all the repositories collide in one file because the file name pattern is:${gtoupId}/${artifactId}/maven-metadata-${repositoryId}.xml
> This causes whole thing work incorrectly.
> When Maven itself constructs ArtifactRepository, it properly assigns ID to the repository and the schema works.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
[jira] Updated: (MNG-1466) Ant dependencies task does not work with multiple repositories
Posted by "Konstantin Ignatyev (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-1466?page=all ]
Konstantin Ignatyev updated MNG-1466:
-------------------------------------
Attachment: id.diff
This is a dirty fix for the problem that introduces ID property on Repository and tries to play nicely with Ant, which does not work quite right.
This works just fine:
<dependencies pathId="provided.classpath" filesetId="provided.fileset">
<remoteRepository id="slabs" url="http://xxxxxxx/testrepo/" />
<remoteRepository id="ibiblio" url="http://www.ibiblio.com/maven2/" />
<remoteRepository id="internal" url="http://yyyyyyyy/localrepo/" />
<dependency groupId="j2ee" artifactId="j2ee" version="1.3.1" />
</dependencies>
==============================
This does not work:
<remoteRepository id="slabs" url="http://xxxxxxx/testrepo/" />
<remoteRepository id="ibiblio" url="http://www.ibiblio.com/maven2/" />
<remoteRepository id="internal" url="http://yyyyyyyy/localrepo/" />
<dependencies pathId="provided.classpath" filesetId="provided.fileset">
<remoteRepository refid="internal" />
<remoteRepository refid="slabs" />
<remoteRepository refid="ibiblio" />
<dependency groupId="j2ee" artifactId="j2ee" version="1.3.1" />
</dependencies>
==============================
This does work, not the artificial a,b,c identities on references, by some reasons reference get Null id:
<remoteRepository id="slabs" url="http://xxxxxxx/testrepo/" />
<remoteRepository id="ibiblio" url="http://www.ibiblio.com/maven2/" />
<remoteRepository id="internal" url="http://yyyyyyyy/localrepo/" />
<dependencies pathId="provided.classpath" filesetId="provided.fileset">
<remoteRepository id="a" refid="internal" />
<remoteRepository id="b" refid="slabs" />
<remoteRepository id="c" refid="ibiblio" />
<dependency groupId="j2ee" artifactId="j2ee" version="1.3.1" />
</dependencies>
============================
Hope that helps
> Ant dependencies task does not work with multiple repositories
> --------------------------------------------------------------
>
> Key: MNG-1466
> URL: http://jira.codehaus.org/browse/MNG-1466
> Project: Maven 2
> Type: Bug
> Components: maven-artifact-ant
> Versions: 2.0.1, 2.0
> Environment: Maven 2.0, Maven 2.0 CVS
> Reporter: Konstantin Ignatyev
> Attachments: id.diff
>
>
> The maven-dependencies task for Ant cannot work properly with multiple repositories because it incorrectly hardcode artifact repository ID that causes all the repositories cache informatioon in the same file
> AbstractArtifactTask#
> ....
> artifactRepository = repositoryFactory.createArtifactRepository( "remote", repository.getUrl(),
> repositoryLayout, snapshots, releases );
> creates all the repositories with the same ID="remote" and that causes all the meta-information for all the repositories collide in one file because the file name pattern is:${gtoupId}/${artifactId}/maven-metadata-${repositoryId}.xml
> This causes whole thing work incorrectly.
> When Maven itself constructs ArtifactRepository, it properly assigns ID to the repository and the schema works.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
[jira] Updated: (MNG-1466) Ant dependencies task does not work with multiple repositories
Posted by "Garrett Conaty (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-1466?page=all ]
Garrett Conaty updated MNG-1466:
--------------------------------
Attachment: id2.diff
This patch is based on an IRC conversation w/ jdcasey and replaces the previous patch (id.diff). This patch requires all repositories to have an ID which is consistent with the POM model.
Note: Probably another issue, but the ant task defines 2 default repositories w/o a way for the user to turn them off.
> Ant dependencies task does not work with multiple repositories
> --------------------------------------------------------------
>
> Key: MNG-1466
> URL: http://jira.codehaus.org/browse/MNG-1466
> Project: Maven 2
> Type: Bug
> Components: maven-artifact-ant
> Versions: 2.0.1, 2.0
> Environment: Maven 2.0, Maven 2.0 CVS
> Reporter: Konstantin Ignatyev
> Attachments: id.diff, id2.diff
>
>
> The maven-dependencies task for Ant cannot work properly with multiple repositories because it incorrectly hardcode artifact repository ID that causes all the repositories cache informatioon in the same file
> AbstractArtifactTask#
> ....
> artifactRepository = repositoryFactory.createArtifactRepository( "remote", repository.getUrl(),
> repositoryLayout, snapshots, releases );
> creates all the repositories with the same ID="remote" and that causes all the meta-information for all the repositories collide in one file because the file name pattern is:${gtoupId}/${artifactId}/maven-metadata-${repositoryId}.xml
> This causes whole thing work incorrectly.
> When Maven itself constructs ArtifactRepository, it properly assigns ID to the repository and the schema works.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
[jira] Closed: (MNG-1466) Ant dependencies task does not work with multiple repositories
Posted by "John Casey (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-1466?page=all ]
John Casey closed MNG-1466:
---------------------------
Resolution: Fixed
Applied second patch, with minor revision. Specifically, I changed:
"default-local" -> "local"
"default-remote" -> "central"
in repository id's, since this makes it more consistent with Maven proper, which could have an effect on authentication configuration from settings.xml eventually...
> Ant dependencies task does not work with multiple repositories
> --------------------------------------------------------------
>
> Key: MNG-1466
> URL: http://jira.codehaus.org/browse/MNG-1466
> Project: Maven 2
> Type: Bug
> Components: maven-artifact-ant
> Versions: 2.0.1, 2.0
> Environment: Maven 2.0, Maven 2.0 CVS
> Reporter: Konstantin Ignatyev
> Assignee: John Casey
> Fix For: 2.0.1
> Attachments: id.diff, id2.diff
>
>
> The maven-dependencies task for Ant cannot work properly with multiple repositories because it incorrectly hardcode artifact repository ID that causes all the repositories cache informatioon in the same file
> AbstractArtifactTask#
> ....
> artifactRepository = repositoryFactory.createArtifactRepository( "remote", repository.getUrl(),
> repositoryLayout, snapshots, releases );
> creates all the repositories with the same ID="remote" and that causes all the meta-information for all the repositories collide in one file because the file name pattern is:${gtoupId}/${artifactId}/maven-metadata-${repositoryId}.xml
> This causes whole thing work incorrectly.
> When Maven itself constructs ArtifactRepository, it properly assigns ID to the repository and the schema works.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org