You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Su...@VerizonWireless.com on 2009/04/25 01:45:16 UTC

pom-transformed.xml issue

Hi,

While doing builds the generated pom-transformed.xml is placed in
/var/tmp/target in a solaris server. When another user does a build for
the same project, it failes as the file genereated by the earlier user
is still there. Is there any workaround to avoid this issue.
Specifically can we determin the location of this xml.

Thanks

Surendra

bash-2.05$ mvn -e deploy:deploy-file -DfilePath=../lib-jars
-DartifactId=servicesmanager -Dpackaging.type=jar
+ Error stacktraces are turned on.
[INFO] Scanning for projects...
[INFO]
------------------------------------------------------------------------
[INFO] Building mybiz-accessmanagerservices
[INFO]    task-segment: [deploy:deploy-file] (aggregator-style)
[INFO]
------------------------------------------------------------------------
[INFO] [deploy:deploy-file]
[INFO]
------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO]
------------------------------------------------------------------------
[INFO] Failed to interpolate POM versions.

/var/tmp/target/pom-transformed.xml (Permission denied)
[INFO]
------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to
interpolate POM versions.
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Default
LifecycleExecutor.java:703)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoa
l(DefaultLifecycleExecutor.java:553)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultL
ifecycleExecutor.java:523)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandle
Failures(DefaultLifecycleExecutor.java:371)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(
DefaultLifecycleExecutor.java:268)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifec
ycleExecutor.java:181)
        at
org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:356)
        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:137)
        at org.apache.maven.cli.MavenCli.main(MavenCli.java:356)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav
a:39)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor
Impl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:324)
        at
org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
        at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
        at
org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
        at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.plugin.MojoExecutionException: Failed to
interpolate POM versions.
        at
org.apache.maven.plugin.deploy.DeployFileMojo.execute(DeployFileMojo.jav
a:244)
        at
org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginMa
nager.java:483)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Default
LifecycleExecutor.java:678)
        ... 16 more
Caused by:
org.apache.maven.artifact.deployer.ArtifactDeploymentException: Failed
to interpolate POM versions.
        at
org.apache.maven.project.artifact.VersionExpressionTransformation.transf
ormForDeployment(VersionExpressionTransformation.java:113)
        at
org.apache.maven.artifact.transform.DefaultArtifactTransformationManager
.transformForDeployment(DefaultArtifactTransformationManager.java:78)
        at
org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(Defaul
tArtifactDeployer.java:86)
        at
org.apache.maven.plugin.deploy.DeployFileMojo.execute(DeployFileMojo.jav
a:240)
        ... 18 more
Caused by:
org.apache.maven.project.interpolation.ModelInterpolationException:
Failed to write transformed POM: /var/tmp/target/pom-transformed.xml
        at
org.apache.maven.project.artifact.VersionExpressionTransformation.interp
olateVersions(VersionExpressionTransformation.java:386)
        at
org.apache.maven.project.artifact.VersionExpressionTransformation.transf
ormVersions(VersionExpressionTransformation.java:214)
        at
org.apache.maven.project.artifact.VersionExpressionTransformation.transf
ormForDeployment(VersionExpressionTransformation.java:94)
        ... 21 more
Caused by: java.io.FileNotFoundException:
/var/tmp/target/pom-transformed.xml (Permission denied)
        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>(XmlStreamWrit
er.java:62)
        at
hidden.org.codehaus.plexus.util.WriterFactory.newXmlWriter(WriterFactory
.java:112)
        at
org.apache.maven.project.artifact.VersionExpressionTransformation.interp
olateVersions(VersionExpressionTransformation.java:380)
        ... 23 more
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 3 seconds
[INFO] Finished at: Fri Apr 24 15:55:16 PDT 2009
[INFO] Final Memory: 4M/9M
[INFO]
------------------------------------------------------------------------
bash-2.05$

Surendra Naidu
Sr. Systems Analyst
West Area IT - Business Internet Services
Verizon Wireless
Desk:     925-279-6941
Mobile: 925-324-5282
snaidu@vtext.com



The information contained in this message and any attachment may be
proprietary, confidential, and privileged or subject to the work
product doctrine and thus protected from disclosure.  If the reader
of this message is not the intended recipient, or an employee or
agent responsible for delivering this message to the intended
recipient, you are hereby notified that any dissemination,
distribution or copying of this communication is strictly prohibited.
If you have received this communication in error, please notify me
immediately by replying to this message and deleting it and all
copies and backups thereof.  Thank you.


Re: pom-transformed.xml issue

Posted by Joerg Hohwiller <jo...@j-hohwiller.de>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,

> Hi,
> Perso, what I do is changing java.io.tmpdir in my .profile.
> All dev who works on the same solaris server have something like that
> in ~/.profile :
> MAVEN_OPTS="-Xmx512m -Xms512m
> -Djava.io.tmpdir=/home/${LOGNAME}/tmp/tmp-dir" export MAVEN_OPTS

Helpful workaround.
Still NOT working if the same user starts two different
maven builds...

However I wonder why maven first writes it to tmpdir
rather than directly writing to target/pom-transformed.xml

Might be some hack cause it writes the transformed POM while reading
the original POM and therefore not knowing what ${project.build.directory}
might be set to...

IMHO I think this is a bad behaviour of maven 2.1 and should be fixed.

> 
> HTH,
> --
> Olivier


Regards
  Jörg
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkoe2+oACgkQmPuec2Dcv/9UeQCeNnBzD1pTPixgME+rNPpADePG
X2YAoIwr/JWkDLSiy7+2tCslATHmsgc7
=+T9o
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: pom-transformed.xml issue

Posted by Olivier Lamy <ol...@apache.org>.
Hi,
Perso, what I do is changing java.io.tmpdir in my .profile.
All dev who works on the same solaris server have something like that
in ~/.profile :
MAVEN_OPTS="-Xmx512m -Xms512m
-Djava.io.tmpdir=/home/${LOGNAME}/tmp/tmp-dir" export MAVEN_OPTS

HTH,
--
Olivier

2009/4/25  <Su...@verizonwireless.com>:
> Hi,
>
> While doing builds the generated pom-transformed.xml is placed in
> /var/tmp/target in a solaris server. When another user does a build for
> the same project, it failes as the file genereated by the earlier user
> is still there. Is there any workaround to avoid this issue.
> Specifically can we determin the location of this xml.
>
> Thanks
>
> Surendra
>
> bash-2.05$ mvn -e deploy:deploy-file -DfilePath=../lib-jars
> -DartifactId=servicesmanager -Dpackaging.type=jar
> + Error stacktraces are turned on.
> [INFO] Scanning for projects...
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Building mybiz-accessmanagerservices
> [INFO]    task-segment: [deploy:deploy-file] (aggregator-style)
> [INFO]
> ------------------------------------------------------------------------
> [INFO] [deploy:deploy-file]
> [INFO]
> ------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Failed to interpolate POM versions.
>
> /var/tmp/target/pom-transformed.xml (Permission denied)
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Trace
> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to
> interpolate POM versions.
>        at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Default
> LifecycleExecutor.java:703)
>        at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoa
> l(DefaultLifecycleExecutor.java:553)
>        at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultL
> ifecycleExecutor.java:523)
>        at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandle
> Failures(DefaultLifecycleExecutor.java:371)
>        at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(
> DefaultLifecycleExecutor.java:268)
>        at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifec
> ycleExecutor.java:181)
>        at
> org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:356)
>        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:137)
>        at org.apache.maven.cli.MavenCli.main(MavenCli.java:356)
>        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>        at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav
> a:39)
>        at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor
> Impl.java:25)
>        at java.lang.reflect.Method.invoke(Method.java:324)
>        at
> org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
>        at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
>        at
> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
>        at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> Caused by: org.apache.maven.plugin.MojoExecutionException: Failed to
> interpolate POM versions.
>        at
> org.apache.maven.plugin.deploy.DeployFileMojo.execute(DeployFileMojo.jav
> a:244)
>        at
> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginMa
> nager.java:483)
>        at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Default
> LifecycleExecutor.java:678)
>        ... 16 more
> Caused by:
> org.apache.maven.artifact.deployer.ArtifactDeploymentException: Failed
> to interpolate POM versions.
>        at
> org.apache.maven.project.artifact.VersionExpressionTransformation.transf
> ormForDeployment(VersionExpressionTransformation.java:113)
>        at
> org.apache.maven.artifact.transform.DefaultArtifactTransformationManager
> .transformForDeployment(DefaultArtifactTransformationManager.java:78)
>        at
> org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(Defaul
> tArtifactDeployer.java:86)
>        at
> org.apache.maven.plugin.deploy.DeployFileMojo.execute(DeployFileMojo.jav
> a:240)
>        ... 18 more
> Caused by:
> org.apache.maven.project.interpolation.ModelInterpolationException:
> Failed to write transformed POM: /var/tmp/target/pom-transformed.xml
>        at
> org.apache.maven.project.artifact.VersionExpressionTransformation.interp
> olateVersions(VersionExpressionTransformation.java:386)
>        at
> org.apache.maven.project.artifact.VersionExpressionTransformation.transf
> ormVersions(VersionExpressionTransformation.java:214)
>        at
> org.apache.maven.project.artifact.VersionExpressionTransformation.transf
> ormForDeployment(VersionExpressionTransformation.java:94)
>        ... 21 more
> Caused by: java.io.FileNotFoundException:
> /var/tmp/target/pom-transformed.xml (Permission denied)
>        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>(XmlStreamWrit
> er.java:62)
>        at
> hidden.org.codehaus.plexus.util.WriterFactory.newXmlWriter(WriterFactory
> .java:112)
>        at
> org.apache.maven.project.artifact.VersionExpressionTransformation.interp
> olateVersions(VersionExpressionTransformation.java:380)
>        ... 23 more
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Total time: 3 seconds
> [INFO] Finished at: Fri Apr 24 15:55:16 PDT 2009
> [INFO] Final Memory: 4M/9M
> [INFO]
> ------------------------------------------------------------------------
> bash-2.05$
>
> Surendra Naidu
> Sr. Systems Analyst
> West Area IT - Business Internet Services
> Verizon Wireless
> Desk:     925-279-6941
> Mobile: 925-324-5282
> snaidu@vtext.com
>
>
>
> The information contained in this message and any attachment may be
> proprietary, confidential, and privileged or subject to the work
> product doctrine and thus protected from disclosure.  If the reader
> of this message is not the intended recipient, or an employee or
> agent responsible for delivering this message to the intended
> recipient, you are hereby notified that any dissemination,
> distribution or copying of this communication is strictly prohibited.
> If you have received this communication in error, please notify me
> immediately by replying to this message and deleting it and all
> copies and backups thereof.  Thank you.
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


RE: pom-transformed.xml issue

Posted by Su...@VerizonWireless.com.
Thanks Oliver. Greatly appreciate your help. 

-----Original Message-----
From: oliver.lamy@gmail.com [mailto:oliver.lamy@gmail.com] On Behalf Of Olivier Lamy
Sent: Saturday, April 25, 2009 5:01 AM
To: Maven Users List
Subject: Re: pom-transformed.xml issue

Hi,
Perso, what I do is changing java.io.tmpdir in my .profile.
All dev who works on the same solaris server have something like that in ~/.profile :
MAVEN_OPTS="-Xmx512m -Xms512m
-Djava.io.tmpdir=/home/${LOGNAME}/tmp/tmp-dir" export MAVEN_OPTS

HTH,
--
Olivier

2009/4/25  <Su...@verizonwireless.com>:
> Hi,
>
> While doing builds the generated pom-transformed.xml is placed in 
> /var/tmp/target in a solaris server. When another user does a build 
> for the same project, it failes as the file genereated by the earlier 
> user is still there. Is there any workaround to avoid this issue.
> Specifically can we determin the location of this xml.
>
> Thanks
>
> Surendra
>
> bash-2.05$ mvn -e deploy:deploy-file -DfilePath=../lib-jars 
> -DartifactId=servicesmanager -Dpackaging.type=jar
> + Error stacktraces are turned on.
> [INFO] Scanning for projects...
> [INFO]
> ----------------------------------------------------------------------
> -- [INFO] Building mybiz-accessmanagerservices [INFO]    task-segment: 
> [deploy:deploy-file] (aggregator-style) [INFO]
> ----------------------------------------------------------------------
> --
> [INFO] [deploy:deploy-file]
> [INFO]
> ----------------------------------------------------------------------
> --
> [ERROR] BUILD ERROR
> [INFO]
> ----------------------------------------------------------------------
> -- [INFO] Failed to interpolate POM versions.
>
> /var/tmp/target/pom-transformed.xml (Permission denied) [INFO]
> ----------------------------------------------------------------------
> --
> [INFO] Trace
> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to 
> interpolate POM versions.
>        at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defau
> lt
> LifecycleExecutor.java:703)
>        at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneG
> oa
> l(DefaultLifecycleExecutor.java:553)
>        at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(Defaul
> tL
> ifecycleExecutor.java:523)
>        at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHand
> le
> Failures(DefaultLifecycleExecutor.java:371)
>        at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegment
> s(
> DefaultLifecycleExecutor.java:268)
>        at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLif
> ec
> ycleExecutor.java:181)
>        at
> org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:356)
>        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:137)
>        at org.apache.maven.cli.MavenCli.main(MavenCli.java:356)
>        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>        at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.j
> av
> a:39)
>        at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccess
> or
> Impl.java:25)
>        at java.lang.reflect.Method.invoke(Method.java:324)
>        at
> org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
>        at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
>        at
> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
>        at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> Caused by: org.apache.maven.plugin.MojoExecutionException: Failed to 
> interpolate POM versions.
>        at
> org.apache.maven.plugin.deploy.DeployFileMojo.execute(DeployFileMojo.j
> av
> a:244)
>        at
> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPlugin
> Ma
> nager.java:483)
>        at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defau
> lt
> LifecycleExecutor.java:678)
>        ... 16 more
> Caused by:
> org.apache.maven.artifact.deployer.ArtifactDeploymentException: Failed 
> to interpolate POM versions.
>        at
> org.apache.maven.project.artifact.VersionExpressionTransformation.tran
> sf
> ormForDeployment(VersionExpressionTransformation.java:113)
>        at
> org.apache.maven.artifact.transform.DefaultArtifactTransformationManag
> er
> .transformForDeployment(DefaultArtifactTransformationManager.java:78)
>        at
> org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(Defa
> ul
> tArtifactDeployer.java:86)
>        at
> org.apache.maven.plugin.deploy.DeployFileMojo.execute(DeployFileMojo.j
> av
> a:240)
>        ... 18 more
> Caused by:
> org.apache.maven.project.interpolation.ModelInterpolationException:
> Failed to write transformed POM: /var/tmp/target/pom-transformed.xml
>        at
> org.apache.maven.project.artifact.VersionExpressionTransformation.inte
> rp
> olateVersions(VersionExpressionTransformation.java:386)
>        at
> org.apache.maven.project.artifact.VersionExpressionTransformation.tran
> sf
> ormVersions(VersionExpressionTransformation.java:214)
>        at
> org.apache.maven.project.artifact.VersionExpressionTransformation.tran
> sf
> ormForDeployment(VersionExpressionTransformation.java:94)
>        ... 21 more
> Caused by: java.io.FileNotFoundException:
> /var/tmp/target/pom-transformed.xml (Permission denied)
>        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>(XmlStreamWr
> it
> er.java:62)
>        at
> hidden.org.codehaus.plexus.util.WriterFactory.newXmlWriter(WriterFacto
> ry
> .java:112)
>        at
> org.apache.maven.project.artifact.VersionExpressionTransformation.inte
> rp
> olateVersions(VersionExpressionTransformation.java:380)
>        ... 23 more
> [INFO]
> ----------------------------------------------------------------------
> --
> [INFO] Total time: 3 seconds
> [INFO] Finished at: Fri Apr 24 15:55:16 PDT 2009 [INFO] Final Memory: 
> 4M/9M [INFO]
> ----------------------------------------------------------------------
> --
> bash-2.05$
>
> Surendra Naidu
> Sr. Systems Analyst
> West Area IT - Business Internet Services Verizon Wireless
> Desk:     925-279-6941
> Mobile: 925-324-5282
> snaidu@vtext.com
>
>
>
> The information contained in this message and any attachment may be
> proprietary, confidential, and privileged or subject to the work
> product doctrine and thus protected from disclosure.  If the reader
> of this message is not the intended recipient, or an employee or
> agent responsible for delivering this message to the intended
> recipient, you are hereby notified that any dissemination,
> distribution or copying of this communication is strictly prohibited.
> If you have received this communication in error, please notify me
> immediately by replying to this message and deleting it and all
> copies and backups thereof.  Thank you.
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org