[ 
http://jira.codehaus.org/browse/MNG-3725?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Benjamin Bentmann updated MNG-3725:
-----------------------------------

    Description: 
When an attempt is made to override the version of torque-templates used by the 
maven-torque-plugin as below, maven still tries to use the original version of 
the torque-templates jar. The overridden jar is ignored.

According to http://jira.codehaus.org/browse/MNG-2972, this behaviour used to 
be broken in maven v2.0.8 and earlier, and was apparently fixed. This doesn't 
seem to be the case though.

The configuration looks like this:
{code:xml}
<plugin>
  <groupId>org.apache.torque</groupId>
  <artifactId>torque-maven-plugin</artifactId>
  <version>3.3</version>
  <dependencies>
    <dependency>
      <groupId>org.apache.derby</groupId>
      <artifactId>derby</artifactId>
      <version>10.4.1.3</version>
    </dependency>
    <dependency>
      <groupId>org.apache.torque</groupId>
      <artifactId>torque-templates</artifactId>
      <version>3.3.1</version>
    </dependency>
  </dependencies>
</plugin>
{code}
The original torque-templates jar is v3.3. The overridden torque-templates jar 
is v3.3.1.

As the plugin gives no clues as to which version is being used, I deleted the 
original torque-templates v3.3 release from the local repository. What I 
expected to see was maven ignoring the v3.3 jar and using the v3.3.1 jar 
instead, but maven tries to re-download the v3.3 release and use it instead.

maven-torque-plugin depends on torque-gen, which in turn depends on 
torque-templates. It may be that direct plugin dependencies can be overridden, 
but transitive plugin dependencies cannot be overridden.


  was:
When an attempt is made to override the version of torque-templates used by the 
maven-torque-plugin as below, maven still tries to use the original version of 
the torque-templates jar. The overridden jar is ignored.

According to http://jira.codehaus.org/browse/MNG-2972, this behaviour used to 
be broken in maven v2.0.8 and earlier, and was apparently fixed. This doesn't 
seem to be the case though.

The configuration looks like this:

     <plugin>
      <groupId>org.apache.torque</groupId>
      <artifactId>torque-maven-plugin</artifactId>
      <version>3.3</version>
      <dependencies>
        <dependency>
          <groupId>org.apache.derby</groupId>
          <artifactId>derby</artifactId>
          <version>10.4.1.3</version>
        </dependency>
        <dependency>
          <groupId>org.apache.torque</groupId>
          <artifactId>torque-templates</artifactId>
          <version>3.3.1</version>
        </dependency>
      </dependencies>
    </plugin>

The original torque-templates jar is v3.3. The overridden torque-templates jar 
is v3.3.1.

As the plugin gives no clues as to which version is being used, I deleted the 
original torque-templates v3.3 release from the local repository. What I 
expected to see was maven ignoring the v3.3 jar and using the v3.3.1 jar 
instead, but maven tries to re-download the v3.3 release and use it instead.

maven-torque-plugin depends on torque-gen, which in turn depends on 
torque-templates. It may be that direct plugin dependencies can be overridden, 
but transitive plugin dependencies cannot be overridden.



> Cannot override plugin dependencies in maven 2.0.9
> --------------------------------------------------
>
>                 Key: MNG-3725
>                 URL: http://jira.codehaus.org/browse/MNG-3725
>             Project: Maven 2
>          Issue Type: Bug
>          Components: Dependencies
>    Affects Versions: 2.0.9
>         Environment: Maven version: 2.0.9
> Java version: 1.5.0_13
> OS name: "mac os x" version: "10.5.4" arch: "ppc" Family: "unix"
>            Reporter: Graham Leggett
>             Fix For: 3.x
>
>
> When an attempt is made to override the version of torque-templates used by 
> the maven-torque-plugin as below, maven still tries to use the original 
> version of the torque-templates jar. The overridden jar is ignored.
> According to http://jira.codehaus.org/browse/MNG-2972, this behaviour used to 
> be broken in maven v2.0.8 and earlier, and was apparently fixed. This doesn't 
> seem to be the case though.
> The configuration looks like this:
> {code:xml}
> <plugin>
>   <groupId>org.apache.torque</groupId>
>   <artifactId>torque-maven-plugin</artifactId>
>   <version>3.3</version>
>   <dependencies>
>     <dependency>
>       <groupId>org.apache.derby</groupId>
>       <artifactId>derby</artifactId>
>       <version>10.4.1.3</version>
>     </dependency>
>     <dependency>
>       <groupId>org.apache.torque</groupId>
>       <artifactId>torque-templates</artifactId>
>       <version>3.3.1</version>
>     </dependency>
>   </dependencies>
> </plugin>
> {code}
> The original torque-templates jar is v3.3. The overridden torque-templates 
> jar is v3.3.1.
> As the plugin gives no clues as to which version is being used, I deleted the 
> original torque-templates v3.3 release from the local repository. What I 
> expected to see was maven ignoring the v3.3 jar and using the v3.3.1 jar 
> instead, but maven tries to re-download the v3.3 release and use it instead.
> maven-torque-plugin depends on torque-gen, which in turn depends on 
> torque-templates. It may be that direct plugin dependencies can be 
> overridden, but transitive plugin dependencies cannot be overridden.

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

        

Reply via email to