Uploaded image for project: 'Maven Assembly Plugin'
  1. Maven Assembly Plugin
  2. MASSEMBLY-730

jar-with-dependencies : a file in a dependency is overridden by the same file in JDK / JRE

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.5, 2.5.1
    • 2.5.2
    • predefined descriptors
    • None
    • JDK 6
      Maven 3.0.4
      Linux / Windows

    Description

      Since version 2.5, when I try to make a "jar-with-dependencies" with the "single" goal, I get a strange mistake.

      A file in a dependency (a JDBC driver in my example) is overridden by a file with the same path / name included in a dependency from the JDK / JRE (in my example jre/lib/resources.jar).

      In my example, I just add the dependency org.postgresql:postgresql:9.3-1102-jdbc4 to my POM.
      Then I package to make a "jar-with-dependencies".
      I can find the file META-INF/services/java.sql.Driver in this jar.
      But with the version 2.5 of plugin assembly, it contains

      • sun.jdbc.odbc.JdbcOdbcDriver (originated from JRE : resources.jar)

      and with version 2.4.1 of the plugin, it contains

      • org.postgresql.Driver (originated from postgresql-9.3-1102-jdbc4.jar), what I expect

      In the previous version (2.4.1) there was no problem.

      Attachments

        Activity

          People

            krosenvold Kristian Rosenvold
            ghusta Guillaume Husta
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: