You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Olov Andersson (JIRA)" <ji...@codehaus.org> on 2008/01/04 10:49:58 UTC

[jira] Created: (MANTTASKS-103) Can't deploy to a file: repository

Can't deploy to a file: repository
----------------------------------

                 Key: MANTTASKS-103
                 URL: http://jira.codehaus.org/browse/MANTTASKS-103
             Project: Maven 2.x Ant Tasks
          Issue Type: Bug
    Affects Versions: 2.0.8
         Environment: ant 1.7.0+maven-ant-tasks-2.0.8
OS: Windows XP
            Reporter: Olov Andersson
         Attachments: maven-ant-tasks-jiratestcase.zip

The artifact:deploy target doesn't work, at least not when deploying to repositories with a file:-based url.

Seem to be some issue with updating the metadata file, the path to the remote repository becomes corrupt during the metadata update.

Provided a simple testcase pointing to a repository at C:\.

The deployment fails with the following message:

[artifact:deploy] Deploying to file:C:\
[artifact:deploy] Uploading: org/dummy/dummy/1.0/dummy-1.0.jar to file:C:\
[artifact:deploy] [INFO] Retrieving previous metadata from file:C:\
[artifact:deploy] [INFO] Uploading project information for dummy 1.0
[artifact:deploy] [INFO] Retrieving previous metadata from file:C:\
[artifact:deploy] An error has occurred while processing the Maven artifact task
s.
[artifact:deploy]  Diagnosis:
[artifact:deploy]
[artifact:deploy] Error deploying artifact 'org.dummy:dummy:jar': Error installi
ng artifact's metadata: Error installing metadata: Error updating group reposito
ry metadata
[artifact:deploy] C:\Documents and Settings\oland\.m2\repository\org\dummy\dummy
\maven-metadata-file:C:\.xml (The filename, directory name, or volume label synt
ax is incorrect)
[artifact:deploy]


-- 
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

        

[jira] Closed: (MANTTASKS-103) Can't deploy to a file: repository

Posted by "Herve Boutemy (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MANTTASKS-103?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Herve Boutemy closed MANTTASKS-103.
-----------------------------------

         Assignee: Herve Boutemy
       Resolution: Fixed
    Fix Version/s: 2.0.9

fixed in r613696

> Can't deploy to a file: repository
> ----------------------------------
>
>                 Key: MANTTASKS-103
>                 URL: http://jira.codehaus.org/browse/MANTTASKS-103
>             Project: Maven 2.x Ant Tasks
>          Issue Type: Bug
>    Affects Versions: 2.0.8
>         Environment: ant 1.7.0+maven-ant-tasks-2.0.8
> OS: Windows XP
>            Reporter: Olov Andersson
>            Assignee: Herve Boutemy
>             Fix For: 2.0.9
>
>         Attachments: maven-ant-tasks-jiratestcase.zip
>
>
> The artifact:deploy target doesn't work, at least not when deploying to repositories with a file:-based url.
> Seem to be some issue with updating the metadata file, the path to the remote repository becomes corrupt during the metadata update.
> Provided a simple testcase pointing to a repository at C:\.
> The deployment fails with the following message:
> [artifact:deploy] Deploying to file:C:\
> [artifact:deploy] Uploading: org/dummy/dummy/1.0/dummy-1.0.jar to file:C:\
> [artifact:deploy] [INFO] Retrieving previous metadata from file:C:\
> [artifact:deploy] [INFO] Uploading project information for dummy 1.0
> [artifact:deploy] [INFO] Retrieving previous metadata from file:C:\
> [artifact:deploy] An error has occurred while processing the Maven artifact task
> s.
> [artifact:deploy]  Diagnosis:
> [artifact:deploy]
> [artifact:deploy] Error deploying artifact 'org.dummy:dummy:jar': Error installi
> ng artifact's metadata: Error installing metadata: Error updating group reposito
> ry metadata
> [artifact:deploy] C:\Documents and Settings\oland\.m2\repository\org\dummy\dummy
> \maven-metadata-file:C:\.xml (The filename, directory name, or volume label synt
> ax is incorrect)
> [artifact:deploy]

-- 
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

        

[jira] Commented: (MANTTASKS-103) Can't deploy to a file: repository

Posted by "Herve Boutemy (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MANTTASKS-103?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_120398 ] 

Herve Boutemy commented on MANTTASKS-103:
-----------------------------------------

ok, I think found the cause of the problem.

A workaround is to define an id attribute for remoteRepository, for example: {code:xml}<remoteRepository id="localDisk" url="file:C:\"/>{code}

Now, I'll have to change the default id when it is not defined, to avoid this kind of problem: in 2.0.8, it is the url, which cause the problem you've found.

Thanks for your report

> Can't deploy to a file: repository
> ----------------------------------
>
>                 Key: MANTTASKS-103
>                 URL: http://jira.codehaus.org/browse/MANTTASKS-103
>             Project: Maven 2.x Ant Tasks
>          Issue Type: Bug
>    Affects Versions: 2.0.8
>         Environment: ant 1.7.0+maven-ant-tasks-2.0.8
> OS: Windows XP
>            Reporter: Olov Andersson
>         Attachments: maven-ant-tasks-jiratestcase.zip
>
>
> The artifact:deploy target doesn't work, at least not when deploying to repositories with a file:-based url.
> Seem to be some issue with updating the metadata file, the path to the remote repository becomes corrupt during the metadata update.
> Provided a simple testcase pointing to a repository at C:\.
> The deployment fails with the following message:
> [artifact:deploy] Deploying to file:C:\
> [artifact:deploy] Uploading: org/dummy/dummy/1.0/dummy-1.0.jar to file:C:\
> [artifact:deploy] [INFO] Retrieving previous metadata from file:C:\
> [artifact:deploy] [INFO] Uploading project information for dummy 1.0
> [artifact:deploy] [INFO] Retrieving previous metadata from file:C:\
> [artifact:deploy] An error has occurred while processing the Maven artifact task
> s.
> [artifact:deploy]  Diagnosis:
> [artifact:deploy]
> [artifact:deploy] Error deploying artifact 'org.dummy:dummy:jar': Error installi
> ng artifact's metadata: Error installing metadata: Error updating group reposito
> ry metadata
> [artifact:deploy] C:\Documents and Settings\oland\.m2\repository\org\dummy\dummy
> \maven-metadata-file:C:\.xml (The filename, directory name, or volume label synt
> ax is incorrect)
> [artifact:deploy]

-- 
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

        

[jira] Commented: (MANTTASKS-103) Can't deploy to a file: repository

Posted by "Herve Boutemy (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MANTTASKS-103?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_118835 ] 

Herve Boutemy commented on MANTTASKS-103:
-----------------------------------------

I don't have a windows computer to test it : I'll need your help.
Can you :
1. run your test with "ant -v", to have a full stacktrace of the problem ?
2. test with Maven Core : add a distributionManagement section in the test pom (see http://maven.apache.org/ref/current/maven-model/maven.html#class_distributionManagement), and run "mvn deploy" ?


> Can't deploy to a file: repository
> ----------------------------------
>
>                 Key: MANTTASKS-103
>                 URL: http://jira.codehaus.org/browse/MANTTASKS-103
>             Project: Maven 2.x Ant Tasks
>          Issue Type: Bug
>    Affects Versions: 2.0.8
>         Environment: ant 1.7.0+maven-ant-tasks-2.0.8
> OS: Windows XP
>            Reporter: Olov Andersson
>         Attachments: maven-ant-tasks-jiratestcase.zip
>
>
> The artifact:deploy target doesn't work, at least not when deploying to repositories with a file:-based url.
> Seem to be some issue with updating the metadata file, the path to the remote repository becomes corrupt during the metadata update.
> Provided a simple testcase pointing to a repository at C:\.
> The deployment fails with the following message:
> [artifact:deploy] Deploying to file:C:\
> [artifact:deploy] Uploading: org/dummy/dummy/1.0/dummy-1.0.jar to file:C:\
> [artifact:deploy] [INFO] Retrieving previous metadata from file:C:\
> [artifact:deploy] [INFO] Uploading project information for dummy 1.0
> [artifact:deploy] [INFO] Retrieving previous metadata from file:C:\
> [artifact:deploy] An error has occurred while processing the Maven artifact task
> s.
> [artifact:deploy]  Diagnosis:
> [artifact:deploy]
> [artifact:deploy] Error deploying artifact 'org.dummy:dummy:jar': Error installi
> ng artifact's metadata: Error installing metadata: Error updating group reposito
> ry metadata
> [artifact:deploy] C:\Documents and Settings\oland\.m2\repository\org\dummy\dummy
> \maven-metadata-file:C:\.xml (The filename, directory name, or volume label synt
> ax is incorrect)
> [artifact:deploy]

-- 
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

        

[jira] Commented: (MANTTASKS-103) Can't deploy to a file: repository

Posted by "Olov Andersson (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MANTTASKS-103?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_118982 ] 

Olov Andersson commented on MANTTASKS-103:
------------------------------------------

Running 'mvn deploy' with a distributionManagement section works, although that's not really the same scenario since I only had an existing jar to deploy. I've tested 'mvn deploy:deploy-file' also which is more similar. That works as well. It's only when running the ant task I run into this problem.

Here's the stack trace:

C:\Temp\maven-ant-tasks-jiratestcase\build.xml:5: Error deploying artifact 'org.dummy:dummy:jar': Error installing artifact's metadata: Error installing metadata: Error updating group repository metadata
	at org.apache.maven.artifact.ant.DeployTask.doExecute(DeployTask.java:132)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.execute(AbstractArtifactTask.java:658)
	at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:105)
	at org.apache.tools.ant.Task.perform(Task.java:348)
	at org.apache.tools.ant.Target.execute(Target.java:357)
	at org.apache.tools.ant.Target.performTasks(Target.java:385)
	at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1329)
	at org.apache.tools.ant.Project.executeTarget(Project.java:1298)
	at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
	at org.apache.tools.ant.Project.executeTargets(Project.java:1181)
	at org.apache.tools.ant.Main.runBuild(Main.java:698)
	at org.apache.tools.ant.Main.startAnt(Main.java:199)
	at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
	at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)
Caused by: org.apache.maven.artifact.deployer.ArtifactDeploymentException: Error installing artifact's metadata: Error installing metadata: Error updating group repository metadata
	at org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(DefaultArtifactDeployer.java:102)
	at org.apache.maven.artifact.ant.DeployTask.doExecute(DeployTask.java:111)
	... 18 more
Caused by: org.apache.maven.artifact.repository.metadata.RepositoryMetadataDeploymentException: Error installing metadata: Error updating group repository metadata
	at org.apache.maven.artifact.repository.metadata.DefaultRepositoryMetadataManager.deploy(DefaultRepositoryMetadataManager.java:432)
	at org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(DefaultArtifactDeployer.java:86)
	... 19 more
Caused by: org.apache.maven.artifact.repository.metadata.RepositoryMetadataStoreException: Error updating group repository metadata
	at org.apache.maven.artifact.repository.metadata.AbstractRepositoryMetadata.storeInLocalRepository(AbstractRepositoryMetadata.java:72)
	at org.apache.maven.artifact.repository.metadata.DefaultRepositoryMetadataManager.deploy(DefaultRepositoryMetadataManager.java:428)
	... 20 more
Caused by: java.io.FileNotFoundException: C:\Documents and Settings\oland\.m2\repository\org\dummy\dummy\maven-metadata-file:C:\.xml (The filename, directory name, or volume label syntax is incorrect)
	at java.io.FileOutputStream.open(Native Method)
	at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
	at java.io.FileOutputStream.<init>(FileOutputStream.java:131)
	at hidden.org.codehaus.plexus.util.xml.XmlStreamWriter.<init>(XmlStreamWriter.java:61)
	at hidden.org.codehaus.plexus.util.WriterFactory.newXmlWriter(WriterFactory.java:112)
	at org.apache.maven.artifact.repository.metadata.AbstractRepositoryMetadata.updateRepositoryMetadata(AbstractRepositoryMetadata.java:134)
	at org.apache.maven.artifact.repository.metadata.AbstractRepositoryMetadata.storeInLocalRepository(AbstractRepositoryMetadata.java:68)
	... 21 more
--- Nested Exception ---
org.apache.maven.artifact.deployer.ArtifactDeploymentException: Error installing artifact's metadata: Error installing metadata: Error updating group repository metadata
	at org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(DefaultArtifactDeployer.java:102)
	at org.apache.maven.artifact.ant.DeployTask.doExecute(DeployTask.java:111)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.execute(AbstractArtifactTask.java:658)
	at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:105)
	at org.apache.tools.ant.Task.perform(Task.java:348)
	at org.apache.tools.ant.Target.execute(Target.java:357)
	at org.apache.tools.ant.Target.performTasks(Target.java:385)
	at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1329)
	at org.apache.tools.ant.Project.executeTarget(Project.java:1298)
	at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
	at org.apache.tools.ant.Project.executeTargets(Project.java:1181)
	at org.apache.tools.ant.Main.runBuild(Main.java:698)
	at org.apache.tools.ant.Main.startAnt(Main.java:199)
	at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
	at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)
Caused by: org.apache.maven.artifact.repository.metadata.RepositoryMetadataDeploymentException: Error installing metadata: Error updating group repository metadata
	at org.apache.maven.artifact.repository.metadata.DefaultRepositoryMetadataManager.deploy(DefaultRepositoryMetadataManager.java:432)
	at org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(DefaultArtifactDeployer.java:86)
	... 19 more
Caused by: org.apache.maven.artifact.repository.metadata.RepositoryMetadataStoreException: Error updating group repository metadata
	at org.apache.maven.artifact.repository.metadata.AbstractRepositoryMetadata.storeInLocalRepository(AbstractRepositoryMetadata.java:72)
	at org.apache.maven.artifact.repository.metadata.DefaultRepositoryMetadataManager.deploy(DefaultRepositoryMetadataManager.java:428)
	... 20 more
Caused by: java.io.FileNotFoundException: C:\Documents and Settings\oland\.m2\repository\org\dummy\dummy\maven-metadata-file:C:\.xml (The filename, directory name, or volume label syntax is incorrect)
	at java.io.FileOutputStream.open(Native Method)
	at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
	at java.io.FileOutputStream.<init>(FileOutputStream.java:131)
	at hidden.org.codehaus.plexus.util.xml.XmlStreamWriter.<init>(XmlStreamWriter.java:61)
	at hidden.org.codehaus.plexus.util.WriterFactory.newXmlWriter(WriterFactory.java:112)
	at org.apache.maven.artifact.repository.metadata.AbstractRepositoryMetadata.updateRepositoryMetadata(AbstractRepositoryMetadata.java:134)
	at org.apache.maven.artifact.repository.metadata.AbstractRepositoryMetadata.storeInLocalRepository(AbstractRepositoryMetadata.java:68)
	... 21 more


> Can't deploy to a file: repository
> ----------------------------------
>
>                 Key: MANTTASKS-103
>                 URL: http://jira.codehaus.org/browse/MANTTASKS-103
>             Project: Maven 2.x Ant Tasks
>          Issue Type: Bug
>    Affects Versions: 2.0.8
>         Environment: ant 1.7.0+maven-ant-tasks-2.0.8
> OS: Windows XP
>            Reporter: Olov Andersson
>         Attachments: maven-ant-tasks-jiratestcase.zip
>
>
> The artifact:deploy target doesn't work, at least not when deploying to repositories with a file:-based url.
> Seem to be some issue with updating the metadata file, the path to the remote repository becomes corrupt during the metadata update.
> Provided a simple testcase pointing to a repository at C:\.
> The deployment fails with the following message:
> [artifact:deploy] Deploying to file:C:\
> [artifact:deploy] Uploading: org/dummy/dummy/1.0/dummy-1.0.jar to file:C:\
> [artifact:deploy] [INFO] Retrieving previous metadata from file:C:\
> [artifact:deploy] [INFO] Uploading project information for dummy 1.0
> [artifact:deploy] [INFO] Retrieving previous metadata from file:C:\
> [artifact:deploy] An error has occurred while processing the Maven artifact task
> s.
> [artifact:deploy]  Diagnosis:
> [artifact:deploy]
> [artifact:deploy] Error deploying artifact 'org.dummy:dummy:jar': Error installi
> ng artifact's metadata: Error installing metadata: Error updating group reposito
> ry metadata
> [artifact:deploy] C:\Documents and Settings\oland\.m2\repository\org\dummy\dummy
> \maven-metadata-file:C:\.xml (The filename, directory name, or volume label synt
> ax is incorrect)
> [artifact:deploy]

-- 
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