You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Tomas Szabo (JIRA)" <ji...@codehaus.org> on 2009/09/24 22:15:06 UTC

[jira] Created: (MNG-4379) Properties defined in parent POM and used in systemPath element cause POM validation warnings and dependencies ignoration - compilation error

Properties defined in parent POM and used in systemPath element cause POM validation warnings and dependencies ignoration - compilation error
---------------------------------------------------------------------------------------------------------------------------------------------

                 Key: MNG-4379
                 URL: http://jira.codehaus.org/browse/MNG-4379
             Project: Maven 2
          Issue Type: Bug
          Components: POM
    Affects Versions: 2.2.1, 2.1.0
         Environment: Windows Vista 32
            Reporter: Tomas Szabo
            Priority: Critical
         Attachments: MavenTestCase.zip

In parent POM of some "common_jar" module we have property definition:

<properties>
        <WEBSPHERE_HOME>${env.WAS7_HOME}</WEBSPHERE_HOME>
</properties>

then in child module "common_jar" we use this property

<!-- WebSphere 7 libraries-->
<dependency>
       <groupId>com.ibm.ws</groupId>
       <artifactId>webservices.thinclient</artifactId>
       <version>7.0.0</version>
       <systemPath>${WEBSPHERE_HOME}/runtimes/com.ibm.ws.webservices.thinclient_7.0.0.jar</systemPath>
       <scope>system</scope>
</dependency>

Next we use this "common_jar" as dependency for our "other module":

<dependency>
    <groupId>our_company.common</groupId>
    <artifactId>common_jar</artifactId>
    <version>1.0-SNAPSHOT</version>
</dependency>

but unfortunatelly this "other module" can not be compiled because of

[WARNING] POM for 'our_company.common:common_jar:pom:1.0.102:compile' is invalid.

Its dependencies (if any) will NOT be available to the current build.

This causes that the libraries from "common_jar" are not available to "other module" and therefore "other module" can not be compiled.


If I replace the WEBSPHERE_HOME's property in "common_jar"'s parent POM with absolute path then "other module" compiles OK. So it seems that it can not read environment properties in "common_jar" from "other module". Module "common_jar" compiles OK under all circumstances (there is no problem with this property in systemPath).


Other thing is that in parent of "other module" there is also a property WEBSPHERE_HOME defined which points to the same directory as WEBSPHERE_HOME in "common_jar" parent POM (simple copy paste by project creation), but it seems that does not affect the issue. There was no problem with this configuration (setup) in Maven 2.0.10. Problem started with Maven 2.1.0 and continues with Maven 2.2.1. We can not use Maven 2.0.10 due to old version of Maven-Eclipse plugin which is generatin wrong ".settings" for EAR project.

For test case to run please modify WEBSPHERE_HOME property and WS libraries dependency in "common_jar" and its parent POM.

-- 
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] Issue Comment Edited: (MNG-4379) Properties defined in parent POM and used in systemPath element cause POM validation warnings and dependencies ignoration - compilation error

Posted by "Harald Entner (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-4379?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=194873#action_194873 ] 

Harald Entner edited comment on MNG-4379 at 10/15/09 11:28 AM:
---------------------------------------------------------------

Same thing with Windows XP -and RH Enterprise Linux  5-. Currently the only workaround seem to be to deploy these artifacts in a local repository, which is normally a good solution but in this case i would prefer to use a relative path. Especially as the server setting is needed anyway to deploy files to the server. 

      was (Author: hentner):
    Same thing with Windows XP and RH Enterprise Linux  5. Currently the only workaround seem to be to deploy these artifacts in a local repository, which is normally a good solution but in this case i would prefer to use a relative path. Especially as the server setting is needed anyway to deploy files to the server. 
  
> Properties defined in parent POM and used in systemPath element cause POM validation warnings and dependencies ignoration - compilation error
> ---------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: MNG-4379
>                 URL: http://jira.codehaus.org/browse/MNG-4379
>             Project: Maven 2
>          Issue Type: Bug
>          Components: POM
>    Affects Versions: 2.1.0, 2.2.1
>         Environment: Windows Vista 32
>            Reporter: Tomas Szabo
>            Priority: Critical
>         Attachments: MavenTestCase.zip
>
>
> In parent POM of some "common_jar" module we have property definition:
> <properties>
>         <WEBSPHERE_HOME>${env.WAS7_HOME}</WEBSPHERE_HOME>
> </properties>
> then in child module "common_jar" we use this property
> <!-- WebSphere 7 libraries-->
> <dependency>
>        <groupId>com.ibm.ws</groupId>
>        <artifactId>webservices.thinclient</artifactId>
>        <version>7.0.0</version>
>        <systemPath>${WEBSPHERE_HOME}/runtimes/com.ibm.ws.webservices.thinclient_7.0.0.jar</systemPath>
>        <scope>system</scope>
> </dependency>
> Next we use this "common_jar" as dependency for our "other module":
> <dependency>
>     <groupId>our_company.common</groupId>
>     <artifactId>common_jar</artifactId>
>     <version>1.0-SNAPSHOT</version>
> </dependency>
> but unfortunatelly this "other module" can not be compiled because of
> [WARNING] POM for 'our_company.common:common_jar:pom:1.0.102:compile' is invalid.
> Its dependencies (if any) will NOT be available to the current build.
> This causes that the libraries from "common_jar" are not available to "other module" and therefore "other module" can not be compiled.
> If I replace the WEBSPHERE_HOME's property in "common_jar"'s parent POM with absolute path then "other module" compiles OK. So it seems that it can not read environment properties in "common_jar" from "other module". Module "common_jar" compiles OK under all circumstances (there is no problem with this property in systemPath).
> Other thing is that in parent of "other module" there is also a property WEBSPHERE_HOME defined which points to the same directory as WEBSPHERE_HOME in "common_jar" parent POM (simple copy paste by project creation), but it seems that does not affect the issue. There was no problem with this configuration (setup) in Maven 2.0.10. Problem started with Maven 2.1.0 and continues with Maven 2.2.1. We can not use Maven 2.0.10 due to old version of Maven-Eclipse plugin which is generatin wrong ".settings" for EAR project.
> For test case to run please modify WEBSPHERE_HOME property and WS libraries dependency in "common_jar" and its parent POM.

-- 
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] Issue Comment Edited: (MNG-4379) Properties defined in parent POM and used in systemPath element cause POM validation warnings and dependencies ignoration - compilation error

Posted by "Harald Entner (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-4379?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=194873#action_194873 ] 

Harald Entner edited comment on MNG-4379 at 10/15/09 11:32 AM:
---------------------------------------------------------------

Same thing with Windows XP -and RH Enterprise Linux  5-. 
When running the root pom it works (also using windows).
When running under linux it works. 
When running under windows (i have deleted every internally created snapshot from local repository) it fails with the given error. 

      was (Author: hentner):
    Same thing with Windows XP -and RH Enterprise Linux  5-. Currently the only workaround seem to be to deploy these artifacts in a local repository, which is normally a good solution but in this case i would prefer to use a relative path. Especially as the server setting is needed anyway to deploy files to the server. 
  
> Properties defined in parent POM and used in systemPath element cause POM validation warnings and dependencies ignoration - compilation error
> ---------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: MNG-4379
>                 URL: http://jira.codehaus.org/browse/MNG-4379
>             Project: Maven 2
>          Issue Type: Bug
>          Components: POM
>    Affects Versions: 2.1.0, 2.2.1
>         Environment: Windows Vista 32
>            Reporter: Tomas Szabo
>            Priority: Critical
>         Attachments: MavenTestCase.zip
>
>
> In parent POM of some "common_jar" module we have property definition:
> <properties>
>         <WEBSPHERE_HOME>${env.WAS7_HOME}</WEBSPHERE_HOME>
> </properties>
> then in child module "common_jar" we use this property
> <!-- WebSphere 7 libraries-->
> <dependency>
>        <groupId>com.ibm.ws</groupId>
>        <artifactId>webservices.thinclient</artifactId>
>        <version>7.0.0</version>
>        <systemPath>${WEBSPHERE_HOME}/runtimes/com.ibm.ws.webservices.thinclient_7.0.0.jar</systemPath>
>        <scope>system</scope>
> </dependency>
> Next we use this "common_jar" as dependency for our "other module":
> <dependency>
>     <groupId>our_company.common</groupId>
>     <artifactId>common_jar</artifactId>
>     <version>1.0-SNAPSHOT</version>
> </dependency>
> but unfortunatelly this "other module" can not be compiled because of
> [WARNING] POM for 'our_company.common:common_jar:pom:1.0.102:compile' is invalid.
> Its dependencies (if any) will NOT be available to the current build.
> This causes that the libraries from "common_jar" are not available to "other module" and therefore "other module" can not be compiled.
> If I replace the WEBSPHERE_HOME's property in "common_jar"'s parent POM with absolute path then "other module" compiles OK. So it seems that it can not read environment properties in "common_jar" from "other module". Module "common_jar" compiles OK under all circumstances (there is no problem with this property in systemPath).
> Other thing is that in parent of "other module" there is also a property WEBSPHERE_HOME defined which points to the same directory as WEBSPHERE_HOME in "common_jar" parent POM (simple copy paste by project creation), but it seems that does not affect the issue. There was no problem with this configuration (setup) in Maven 2.0.10. Problem started with Maven 2.1.0 and continues with Maven 2.2.1. We can not use Maven 2.0.10 due to old version of Maven-Eclipse plugin which is generatin wrong ".settings" for EAR project.
> For test case to run please modify WEBSPHERE_HOME property and WS libraries dependency in "common_jar" and its parent POM.

-- 
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: (MNG-4379) Properties defined in parent POM and used in systemPath element cause POM validation warnings and dependencies ignoration - compilation error

Posted by "Benjamin Bentmann (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-4379?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Benjamin Bentmann closed MNG-4379.
----------------------------------

       Resolution: Fixed
    Fix Version/s: 3.0-alpha-6
         Assignee: Benjamin Bentmann

Fixed in [r895245|http://svn.apache.org/viewvc?view=revision&revision=895245].

The problem is that environment variables are not available during dependency resolution. You could work around this by setting an equally named JVM system property via {{MAVEN_OPTS=-Denv.WAS7_HOME=%WAS7_HOME%}}.

> Properties defined in parent POM and used in systemPath element cause POM validation warnings and dependencies ignoration - compilation error
> ---------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: MNG-4379
>                 URL: http://jira.codehaus.org/browse/MNG-4379
>             Project: Maven 2 & 3
>          Issue Type: Bug
>          Components: POM
>    Affects Versions: 2.1.0, 2.2.1
>         Environment: Windows Vista 32
>            Reporter: Tomas Szabo
>            Assignee: Benjamin Bentmann
>            Priority: Critical
>             Fix For: 3.0-alpha-6
>
>         Attachments: MavenTestCase.zip
>
>
> In parent POM of some "common_jar" module we have property definition:
> <properties>
>         <WEBSPHERE_HOME>${env.WAS7_HOME}</WEBSPHERE_HOME>
> </properties>
> then in child module "common_jar" we use this property
> <!-- WebSphere 7 libraries-->
> <dependency>
>        <groupId>com.ibm.ws</groupId>
>        <artifactId>webservices.thinclient</artifactId>
>        <version>7.0.0</version>
>        <systemPath>${WEBSPHERE_HOME}/runtimes/com.ibm.ws.webservices.thinclient_7.0.0.jar</systemPath>
>        <scope>system</scope>
> </dependency>
> Next we use this "common_jar" as dependency for our "other module":
> <dependency>
>     <groupId>our_company.common</groupId>
>     <artifactId>common_jar</artifactId>
>     <version>1.0-SNAPSHOT</version>
> </dependency>
> but unfortunatelly this "other module" can not be compiled because of
> [WARNING] POM for 'our_company.common:common_jar:pom:1.0.102:compile' is invalid.
> Its dependencies (if any) will NOT be available to the current build.
> This causes that the libraries from "common_jar" are not available to "other module" and therefore "other module" can not be compiled.
> If I replace the WEBSPHERE_HOME's property in "common_jar"'s parent POM with absolute path then "other module" compiles OK. So it seems that it can not read environment properties in "common_jar" from "other module". Module "common_jar" compiles OK under all circumstances (there is no problem with this property in systemPath).
> Other thing is that in parent of "other module" there is also a property WEBSPHERE_HOME defined which points to the same directory as WEBSPHERE_HOME in "common_jar" parent POM (simple copy paste by project creation), but it seems that does not affect the issue. There was no problem with this configuration (setup) in Maven 2.0.10. Problem started with Maven 2.1.0 and continues with Maven 2.2.1. We can not use Maven 2.0.10 due to old version of Maven-Eclipse plugin which is generatin wrong ".settings" for EAR project.
> For test case to run please modify WEBSPHERE_HOME property and WS libraries dependency in "common_jar" and its parent POM.

-- 
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] Issue Comment Edited: (MNG-4379) Properties defined in parent POM and used in systemPath element cause POM validation warnings and dependencies ignoration - compilation error

Posted by "Harald Entner (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-4379?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=194873#action_194873 ] 

Harald Entner edited comment on MNG-4379 at 10/15/09 11:42 AM:
---------------------------------------------------------------

Same thing with Windows XP and RH Enterprise Linux  5. 

It works fine when running the parent pom, but fails when running one of the childs. 

{code}
[WARNING] POM for 'de.xxx:xxxCommon:pom:1.0-SNAPSHOT:compile' is invalid.
Its dependencies (if any) will NOT be available to the current build.
{code}

      was (Author: hentner):
    Same thing with Windows XP -and RH Enterprise Linux  5-. 
When running the root pom it works (also using windows).
When running under linux it works. 
When running under windows (i have deleted every internally created snapshot from local repository) it fails with the given error. 
  
> Properties defined in parent POM and used in systemPath element cause POM validation warnings and dependencies ignoration - compilation error
> ---------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: MNG-4379
>                 URL: http://jira.codehaus.org/browse/MNG-4379
>             Project: Maven 2
>          Issue Type: Bug
>          Components: POM
>    Affects Versions: 2.1.0, 2.2.1
>         Environment: Windows Vista 32
>            Reporter: Tomas Szabo
>            Priority: Critical
>         Attachments: MavenTestCase.zip
>
>
> In parent POM of some "common_jar" module we have property definition:
> <properties>
>         <WEBSPHERE_HOME>${env.WAS7_HOME}</WEBSPHERE_HOME>
> </properties>
> then in child module "common_jar" we use this property
> <!-- WebSphere 7 libraries-->
> <dependency>
>        <groupId>com.ibm.ws</groupId>
>        <artifactId>webservices.thinclient</artifactId>
>        <version>7.0.0</version>
>        <systemPath>${WEBSPHERE_HOME}/runtimes/com.ibm.ws.webservices.thinclient_7.0.0.jar</systemPath>
>        <scope>system</scope>
> </dependency>
> Next we use this "common_jar" as dependency for our "other module":
> <dependency>
>     <groupId>our_company.common</groupId>
>     <artifactId>common_jar</artifactId>
>     <version>1.0-SNAPSHOT</version>
> </dependency>
> but unfortunatelly this "other module" can not be compiled because of
> [WARNING] POM for 'our_company.common:common_jar:pom:1.0.102:compile' is invalid.
> Its dependencies (if any) will NOT be available to the current build.
> This causes that the libraries from "common_jar" are not available to "other module" and therefore "other module" can not be compiled.
> If I replace the WEBSPHERE_HOME's property in "common_jar"'s parent POM with absolute path then "other module" compiles OK. So it seems that it can not read environment properties in "common_jar" from "other module". Module "common_jar" compiles OK under all circumstances (there is no problem with this property in systemPath).
> Other thing is that in parent of "other module" there is also a property WEBSPHERE_HOME defined which points to the same directory as WEBSPHERE_HOME in "common_jar" parent POM (simple copy paste by project creation), but it seems that does not affect the issue. There was no problem with this configuration (setup) in Maven 2.0.10. Problem started with Maven 2.1.0 and continues with Maven 2.2.1. We can not use Maven 2.0.10 due to old version of Maven-Eclipse plugin which is generatin wrong ".settings" for EAR project.
> For test case to run please modify WEBSPHERE_HOME property and WS libraries dependency in "common_jar" and its parent POM.

-- 
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: (MNG-4379) Properties defined in parent POM and used in systemPath element cause POM validation warnings and dependencies ignoration - compilation error

Posted by "Harald Entner (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-4379?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=194873#action_194873 ] 

Harald Entner commented on MNG-4379:
------------------------------------

Same thing with Windows XP and RH Enterprise Linux  5. Currently the only workaround seem to be to deploy these artifacts in a local repository, which is normally a good solution but in this case i would prefer to use a relative path. Especially as the server setting is needed anyway to deploy files to the server. 

> Properties defined in parent POM and used in systemPath element cause POM validation warnings and dependencies ignoration - compilation error
> ---------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: MNG-4379
>                 URL: http://jira.codehaus.org/browse/MNG-4379
>             Project: Maven 2
>          Issue Type: Bug
>          Components: POM
>    Affects Versions: 2.1.0, 2.2.1
>         Environment: Windows Vista 32
>            Reporter: Tomas Szabo
>            Priority: Critical
>         Attachments: MavenTestCase.zip
>
>
> In parent POM of some "common_jar" module we have property definition:
> <properties>
>         <WEBSPHERE_HOME>${env.WAS7_HOME}</WEBSPHERE_HOME>
> </properties>
> then in child module "common_jar" we use this property
> <!-- WebSphere 7 libraries-->
> <dependency>
>        <groupId>com.ibm.ws</groupId>
>        <artifactId>webservices.thinclient</artifactId>
>        <version>7.0.0</version>
>        <systemPath>${WEBSPHERE_HOME}/runtimes/com.ibm.ws.webservices.thinclient_7.0.0.jar</systemPath>
>        <scope>system</scope>
> </dependency>
> Next we use this "common_jar" as dependency for our "other module":
> <dependency>
>     <groupId>our_company.common</groupId>
>     <artifactId>common_jar</artifactId>
>     <version>1.0-SNAPSHOT</version>
> </dependency>
> but unfortunatelly this "other module" can not be compiled because of
> [WARNING] POM for 'our_company.common:common_jar:pom:1.0.102:compile' is invalid.
> Its dependencies (if any) will NOT be available to the current build.
> This causes that the libraries from "common_jar" are not available to "other module" and therefore "other module" can not be compiled.
> If I replace the WEBSPHERE_HOME's property in "common_jar"'s parent POM with absolute path then "other module" compiles OK. So it seems that it can not read environment properties in "common_jar" from "other module". Module "common_jar" compiles OK under all circumstances (there is no problem with this property in systemPath).
> Other thing is that in parent of "other module" there is also a property WEBSPHERE_HOME defined which points to the same directory as WEBSPHERE_HOME in "common_jar" parent POM (simple copy paste by project creation), but it seems that does not affect the issue. There was no problem with this configuration (setup) in Maven 2.0.10. Problem started with Maven 2.1.0 and continues with Maven 2.2.1. We can not use Maven 2.0.10 due to old version of Maven-Eclipse plugin which is generatin wrong ".settings" for EAR project.
> For test case to run please modify WEBSPHERE_HOME property and WS libraries dependency in "common_jar" and its parent POM.

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