You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Evan Worley <ev...@gmail.com> on 2007/05/23 17:30:13 UTC
Re: install:install - variables in POM are not replaced/filtered during installation in repository
Hi Frank,
>From the information you posted, I have a few questions.
1. Is XXX:AAA the parent of XXX:BBB? If not, I don't believe XXX:BBB would
not inherit the definition of the ${buildVersion} property.
2. Where do you set ${label}, in your settings.xml? If so can you post the
relevant snippet?
-Evan
On 5/23/07, Steinhauer, Frank <f....@olympus-odl.com> wrote:
>
> Hello,
>
> during installation of the POM in the local repository the variables are
> not replaced/filtered. Is this a bug or purpose? Or did I a make a
> mistake somewhere?
> Explanation:
> In our POMs we set the version numbers according to local settings and
> given CLI parameters, and do this in our multi module projects for the
> intern dependecies (dependencies to other modules) as well. So when Jar
> AAA depends on Jar BBB that depends on Jar CCC (all version numbers are
> variables), the POM of BBB is loaded, but then the further load of Jar
> CCC fails, it tries to load XXX:CCC:jar:1.2${point}${label} or
> XXX:CCC:jar:1.2${buildVersion} (the later in the multi module build).
> Any suggestions? I'm glad for any assistence, since it cost me already
> three days figuring that out....
>
>
> Cheers,
>
> Frank
>
>
>
> Example POM for AAA:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <project xmlns="http://maven.apache.org/POM/4.0.0"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
> http://maven.apache.org/maven-v4_0_0.xsd">
> <modelVersion>4.0.0</modelVersion>
>
> <groupId>XXX</groupId>
> <artifactId>AAA</artifactId>
> <version>${buildVersion}</version> <!-- used throughout all of our
> projects/modules -->
> <packaging>jar</packaging>
> <properties>
> <versionNo>1.2</versionNo>
> <buildVersion>${versionNo}${label}</buildVersion> <!-- label is
> set differently in a local build and in the CruiseControl build -->
> </properties>
> ...
> <dependencies>
> <dependency>
> <groupId>XXX</groupId>
> <artifactId>BBB</artifactId>
> <version>${buildVersion}</version>
> <type>jar</type>
> </dependency>
> </dependencies>
> ...
> </project>
>
>
> Similiar example POM for BBB:
>
> ...
> <artifactId>BBB</artifactId>
> <version>${buildVersion}</version> <!-- used throughout all of our
> projects/modules -->
> ...
> <dependency>
> <groupId>XXX</groupId>
> <artifactId>CCC</artifactId>
> <version>${buildVersion}</version>
> <type>jar</type>
> </dependency>
> ...
> </project>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>
AW: install:install - variables in POM are not replaced/filtered during installation in repository
Posted by "Steinhauer, Frank" <f....@olympus-odl.com>.
XXX:BBB knows at build time which version it needs of XXX:CCC, the problem is, that it's POM is copied directly to the local repo, without replacing the variables (as it should to my opinion). XXX:AAA knows nothing about the XX:BBB variables, nor should it know.
- Frank
-----Ursprüngliche Nachricht-----
Von: Evan Worley [mailto:evanworley@gmail.com]
Gesendet: Mittwoch, 23. Mai 2007 18:29
An: Maven Developers List
Betreff: Re: install:install - variables in POM are not replaced/filtered during installation in repository
Maybe someone else can chime in here, but if XXX:AAA is not the parent of
XXX:BBB I don't think XXX:BBB will have the buildVersion property defined.
If that property isn't defined then XXX:BBB will not be able to resolve a
dependency to XXX:CCC because it doesn't know which version you want, since
${buildVersion} isn't defined.
Perhaps I am missing something?
-Evan
On 5/23/07, Steinhauer, Frank <f....@olympus-odl.com> wrote:
>
> Hi Evan,
>
> XXX:AAA is not the parent of XXX:BBB. I've tried two scenarios, one
> multi-module project, where 10 JARs are built, and some jars depending on
> previous built ones (here I'm using <dependencyManagement> in the top most
> POM, setting the version number for the jar/module dependencies to the same
> as used for that POM), and for testing purpose some single projects, that
> are depending on each other.
>
> Here's my setting.xml snippet:
>
> <profiles>
> <profile>
> <id>setting_label</id>
> <properties>
> <point>-</point> <!-- use "." on the CC server, "-" local
> -->
> <label>SNAPSHOT</label><!-- is set automatically by CC, use
> "SNAPSHOT" locally -->
> </properties>
> </profile>
> </profiles>
> <activeProfiles>
> <activeProfile>setting_label</activeProfile>
> </activeProfiles>
>
> -Frank
>
> -----Ursprüngliche Nachricht-----
> Von: Evan Worley [mailto:evanworley@gmail.com]
> Gesendet: Mittwoch, 23. Mai 2007 17:30
> An: Maven Developers List
> Betreff: Re: install:install - variables in POM are not replaced/filtered
> during installation in repository
>
> Hi Frank,
>
> From the information you posted, I have a few questions.
>
> 1. Is XXX:AAA the parent of XXX:BBB? If not, I don't believe XXX:BBB
> would
> not inherit the definition of the ${buildVersion} property.
> 2. Where do you set ${label}, in your settings.xml? If so can you post
> the
> relevant snippet?
>
> -Evan
>
> On 5/23/07, Steinhauer, Frank <f....@olympus-odl.com> wrote:
> >
> > Hello,
> >
> > during installation of the POM in the local repository the variables are
> > not replaced/filtered. Is this a bug or purpose? Or did I a make a
> > mistake somewhere?
> > Explanation:
> > In our POMs we set the version numbers according to local settings and
> > given CLI parameters, and do this in our multi module projects for the
> > intern dependecies (dependencies to other modules) as well. So when Jar
> > AAA depends on Jar BBB that depends on Jar CCC (all version numbers are
> > variables), the POM of BBB is loaded, but then the further load of Jar
> > CCC fails, it tries to load XXX:CCC:jar:1.2${point}${label} or
> > XXX:CCC:jar:1.2${buildVersion} (the later in the multi module build).
> > Any suggestions? I'm glad for any assistence, since it cost me already
> > three days figuring that out....
> >
> >
> > Cheers,
> >
> > Frank
> >
> >
> >
> > Example POM for AAA:
> >
> > <?xml version="1.0" encoding="UTF-8"?>
> > <project xmlns="http://maven.apache.org/POM/4.0.0"
> > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> > xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
> > http://maven.apache.org/maven-v4_0_0.xsd">
> > <modelVersion>4.0.0</modelVersion>
> >
> > <groupId>XXX</groupId>
> > <artifactId>AAA</artifactId>
> > <version>${buildVersion}</version> <!-- used throughout all of our
> > projects/modules -->
> > <packaging>jar</packaging>
> > <properties>
> > <versionNo>1.2</versionNo>
> > <buildVersion>${versionNo}${point}${label}</buildVersion>
> > <!-- point and label are set differently in a local build and in the
> > CruiseControl build -->
> > </properties>
> > ...
> > <dependencies>
> > <dependency>
> > <groupId>XXX</groupId>
> > <artifactId>BBB</artifactId>
> > <version>${buildVersion}</version>
> > <type>jar</type>
> > </dependency>
> > </dependencies>
> > ...
> > </project>
> >
> >
> > Similiar example POM for BBB:
> >
> > ...
> > <artifactId>BBB</artifactId>
> > <version>${buildVersion}</version> <!-- used throughout all of our
> > projects/modules -->
> > ...
> > <dependency>
> > <groupId>XXX</groupId>
> > <artifactId>CCC</artifactId>
> > <version>${buildVersion}</version>
> > <type>jar</type>
> > </dependency>
> > ...
> > </project>
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: install:install - variables in POM are not replaced/filtered during installation in repository
Posted by Evan Worley <ev...@gmail.com>.
Maybe someone else can chime in here, but if XXX:AAA is not the parent of
XXX:BBB I don't think XXX:BBB will have the buildVersion property defined.
If that property isn't defined then XXX:BBB will not be able to resolve a
dependency to XXX:CCC because it doesn't know which version you want, since
${buildVersion} isn't defined.
Perhaps I am missing something?
-Evan
On 5/23/07, Steinhauer, Frank <f....@olympus-odl.com> wrote:
>
> Hi Evan,
>
> XXX:AAA is not the parent of XXX:BBB. I've tried two scenarios, one
> multi-module project, where 10 JARs are built, and some jars depending on
> previous built ones (here I'm using <dependencyManagement> in the top most
> POM, setting the version number for the jar/module dependencies to the same
> as used for that POM), and for testing purpose some single projects, that
> are depending on each other.
>
> Here's my setting.xml snippet:
>
> <profiles>
> <profile>
> <id>setting_label</id>
> <properties>
> <point>-</point> <!-- use "." on the CC server, "-" local
> -->
> <label>SNAPSHOT</label><!-- is set automatically by CC, use
> "SNAPSHOT" locally -->
> </properties>
> </profile>
> </profiles>
> <activeProfiles>
> <activeProfile>setting_label</activeProfile>
> </activeProfiles>
>
> -Frank
>
> -----Ursprüngliche Nachricht-----
> Von: Evan Worley [mailto:evanworley@gmail.com]
> Gesendet: Mittwoch, 23. Mai 2007 17:30
> An: Maven Developers List
> Betreff: Re: install:install - variables in POM are not replaced/filtered
> during installation in repository
>
> Hi Frank,
>
> From the information you posted, I have a few questions.
>
> 1. Is XXX:AAA the parent of XXX:BBB? If not, I don't believe XXX:BBB
> would
> not inherit the definition of the ${buildVersion} property.
> 2. Where do you set ${label}, in your settings.xml? If so can you post
> the
> relevant snippet?
>
> -Evan
>
> On 5/23/07, Steinhauer, Frank <f....@olympus-odl.com> wrote:
> >
> > Hello,
> >
> > during installation of the POM in the local repository the variables are
> > not replaced/filtered. Is this a bug or purpose? Or did I a make a
> > mistake somewhere?
> > Explanation:
> > In our POMs we set the version numbers according to local settings and
> > given CLI parameters, and do this in our multi module projects for the
> > intern dependecies (dependencies to other modules) as well. So when Jar
> > AAA depends on Jar BBB that depends on Jar CCC (all version numbers are
> > variables), the POM of BBB is loaded, but then the further load of Jar
> > CCC fails, it tries to load XXX:CCC:jar:1.2${point}${label} or
> > XXX:CCC:jar:1.2${buildVersion} (the later in the multi module build).
> > Any suggestions? I'm glad for any assistence, since it cost me already
> > three days figuring that out....
> >
> >
> > Cheers,
> >
> > Frank
> >
> >
> >
> > Example POM for AAA:
> >
> > <?xml version="1.0" encoding="UTF-8"?>
> > <project xmlns="http://maven.apache.org/POM/4.0.0"
> > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> > xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
> > http://maven.apache.org/maven-v4_0_0.xsd">
> > <modelVersion>4.0.0</modelVersion>
> >
> > <groupId>XXX</groupId>
> > <artifactId>AAA</artifactId>
> > <version>${buildVersion}</version> <!-- used throughout all of our
> > projects/modules -->
> > <packaging>jar</packaging>
> > <properties>
> > <versionNo>1.2</versionNo>
> > <buildVersion>${versionNo}${point}${label}</buildVersion>
> > <!-- point and label are set differently in a local build and in the
> > CruiseControl build -->
> > </properties>
> > ...
> > <dependencies>
> > <dependency>
> > <groupId>XXX</groupId>
> > <artifactId>BBB</artifactId>
> > <version>${buildVersion}</version>
> > <type>jar</type>
> > </dependency>
> > </dependencies>
> > ...
> > </project>
> >
> >
> > Similiar example POM for BBB:
> >
> > ...
> > <artifactId>BBB</artifactId>
> > <version>${buildVersion}</version> <!-- used throughout all of our
> > projects/modules -->
> > ...
> > <dependency>
> > <groupId>XXX</groupId>
> > <artifactId>CCC</artifactId>
> > <version>${buildVersion}</version>
> > <type>jar</type>
> > </dependency>
> > ...
> > </project>
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>
AW: install:install - variables in POM are not replaced/filtered during installation in repository
Posted by "Steinhauer, Frank" <f....@olympus-odl.com>.
Hi Evan,
XXX:AAA is not the parent of XXX:BBB. I've tried two scenarios, one multi-module project, where 10 JARs are built, and some jars depending on previous built ones (here I'm using <dependencyManagement> in the top most POM, setting the version number for the jar/module dependencies to the same as used for that POM), and for testing purpose some single projects, that are depending on each other.
Here's my setting.xml snippet:
<profiles>
<profile>
<id>setting_label</id>
<properties>
<point>-</point> <!-- use "." on the CC server, "-" local -->
<label>SNAPSHOT</label><!-- is set automatically by CC, use "SNAPSHOT" locally -->
</properties>
</profile>
</profiles>
<activeProfiles>
<activeProfile>setting_label</activeProfile>
</activeProfiles>
-Frank
-----Ursprüngliche Nachricht-----
Von: Evan Worley [mailto:evanworley@gmail.com]
Gesendet: Mittwoch, 23. Mai 2007 17:30
An: Maven Developers List
Betreff: Re: install:install - variables in POM are not replaced/filtered during installation in repository
Hi Frank,
>From the information you posted, I have a few questions.
1. Is XXX:AAA the parent of XXX:BBB? If not, I don't believe XXX:BBB would
not inherit the definition of the ${buildVersion} property.
2. Where do you set ${label}, in your settings.xml? If so can you post the
relevant snippet?
-Evan
On 5/23/07, Steinhauer, Frank <f....@olympus-odl.com> wrote:
>
> Hello,
>
> during installation of the POM in the local repository the variables are
> not replaced/filtered. Is this a bug or purpose? Or did I a make a
> mistake somewhere?
> Explanation:
> In our POMs we set the version numbers according to local settings and
> given CLI parameters, and do this in our multi module projects for the
> intern dependecies (dependencies to other modules) as well. So when Jar
> AAA depends on Jar BBB that depends on Jar CCC (all version numbers are
> variables), the POM of BBB is loaded, but then the further load of Jar
> CCC fails, it tries to load XXX:CCC:jar:1.2${point}${label} or
> XXX:CCC:jar:1.2${buildVersion} (the later in the multi module build).
> Any suggestions? I'm glad for any assistence, since it cost me already
> three days figuring that out....
>
>
> Cheers,
>
> Frank
>
>
>
> Example POM for AAA:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <project xmlns="http://maven.apache.org/POM/4.0.0"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
> http://maven.apache.org/maven-v4_0_0.xsd">
> <modelVersion>4.0.0</modelVersion>
>
> <groupId>XXX</groupId>
> <artifactId>AAA</artifactId>
> <version>${buildVersion}</version> <!-- used throughout all of our
> projects/modules -->
> <packaging>jar</packaging>
> <properties>
> <versionNo>1.2</versionNo>
> <buildVersion>${versionNo}${point}${label}</buildVersion>
> <!-- point and label are set differently in a local build and in the
> CruiseControl build -->
> </properties>
> ...
> <dependencies>
> <dependency>
> <groupId>XXX</groupId>
> <artifactId>BBB</artifactId>
> <version>${buildVersion}</version>
> <type>jar</type>
> </dependency>
> </dependencies>
> ...
> </project>
>
>
> Similiar example POM for BBB:
>
> ...
> <artifactId>BBB</artifactId>
> <version>${buildVersion}</version> <!-- used throughout all of our
> projects/modules -->
> ...
> <dependency>
> <groupId>XXX</groupId>
> <artifactId>CCC</artifactId>
> <version>${buildVersion}</version>
> <type>jar</type>
> </dependency>
> ...
> </project>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org