Uploaded image for project: 'Gradle'
  1. Gradle
  2. GRADLE-2496

Forcing a module version has no effect on generated org.eclipse.wst.common.component

    Details

    • Gradle Forums topic Reference:

      Description

      I have a multi-project build some projects that depend on hibernate-core 3.6.8-Final, which in turn depends on commons-collections 3.1.

      I overrode this transitive dependency with the following in all java projects:

      configurations {
      all {
      resolutionStrategy.force "commons-collections:commons-collections:3.2.1"
      }
      }

      This works fine for all plugins (java, tomcat, war), though it fails to be applied in the case of the eclipse-wtp plugin. The original 3.1 jar is referenced in the generated .settings/org.eclipse.wst.common.component as a dependent-module instead of version 3.2.1.

      Thanks for any help!

      --David

        Activity

        Hide
        forums Gradle Forums added a comment -

        Did you do a `cleanEclipse`?

        Show
        forums Gradle Forums added a comment - Did you do a `cleanEclipse`?
        Hide
        forums Gradle Forums added a comment -

        Yes.

        Show
        forums Gradle Forums added a comment - Yes.
        Hide
        forums Gradle Forums added a comment -

        This reproduces the problem:

        apply plugin: "war"
        apply plugin: "eclipse-wtp"

        repositories {
        mavenCentral()
        }

        dependencies {
        compile "org.hibernate:hibernate-core:3.6.8.Final"
        }

        configurations {
        all {
        resolutionStrategy.force "commons-collections:commons-collections:3.2.1"
        }
        }

        Creating a JIRA issue.

        Show
        forums Gradle Forums added a comment - This reproduces the problem: apply plugin: "war" apply plugin: "eclipse-wtp" repositories { mavenCentral() } dependencies { compile "org.hibernate:hibernate-core:3.6.8.Final" } configurations { all { resolutionStrategy.force "commons-collections:commons-collections:3.2.1" } } Creating a JIRA issue.
        Hide
        gerhard Gerhard added a comment -

        Using the new dependency resolve rules from Gradle 1.4 has the same problem. eclipse-wtp ignores that too. Please fix this ASOP.

        configurations.all {
            resolutionStrategy.eachDependency { DependencyResolveDetails details ->
                if (details.requested.group == 'org.springframework') {
                    details.useVersion '3.2.0.RELEASE'
                }
            }
        }
        
        Show
        gerhard Gerhard added a comment - Using the new dependency resolve rules from Gradle 1.4 has the same problem. eclipse-wtp ignores that too. Please fix this ASOP. configurations.all { resolutionStrategy.eachDependency { DependencyResolveDetails details -> if (details.requested.group == 'org.springframework') { details.useVersion '3.2.0.RELEASE' } } }
        Hide
        aaschmid Andreas Schmid added a comment -

        Using Gradle 2.0 I am not able to reproduce this issue. Can you confirm that?

        Show
        aaschmid Andreas Schmid added a comment - Using Gradle 2.0 I am not able to reproduce this issue. Can you confirm that?

          People

          • Assignee:
            donat Donát Csikós
            Reporter:
            forums Gradle Forums
          • Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development