Uploaded image for project: 'Maven'
  1. Maven
  2. MNG-3196

Allow exclusion of a certain transitive dependency across all direct dependencies.

    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Closed
    • Major
    • Resolution: Incomplete
    • 2.0.7
    • None
    • Dependencies
    • None

    Description

      I would like to be able to put exludes at the top level of dependencies so that it can easily be excluded from all transitive dependencies, instead of just excluding it from a single dependency at a time. For example assume that project1 and project2 both have transitive dependencies on different versions of project-trans:

      <dependencies>
        <exclusions>
          <exclusion>
            <groupId>com.stuff</groupId>
            <artifactId>project-trans</artifactId>
          </exclusion>
        </exclusions>
        <dependency>
          <groupId>com.stuff</groupId>
          <artifactId>project1</artifactId>
          <version>1.0</version>
        <dependency>
        <dependency>
          <groupId>com.stuff</groupId>
          <artifactId>project2</artifactId>
          <version>1.0</version>
        <dependency>
      </dependencies>
      

      In this example, the "project-trans" dependency would be exluded from both project1 and project2. It can be difficult to find all the locations of a transitively included dependency for a large project that has a large number of frequently changing dependencies.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              pgier Paul Gier
              Votes:
              31 Vote for this issue
              Watchers:
              24 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: