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

don't read assembly descriptor from thread classloader but plugin classloader

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 3.0.0
    • 3.1.0
    • None
    • None

    Description

      before MASSEMBLY-331 (in 2.2-beta-3), assembly descriptor was read from plugin classloader: it switched inadvertently (apparently) to thread classloader.
      In MNG-6209 for Maven 3.5.1, thread classloader evolves when plugin is flagged as extension and the assembly descriptor won't be available any more
      using thread classloader was not really a good idea, even if it didn't hurt for years: but now, it hurts: a lot of MASSEMBLY ITs related to classpath resources fail with Maven 3.5.1-SNAPSHOT:

      [INFO] --- maven-invoker-plugin:3.0.0:verify (integration-test) @ maven-assembly-plugin ---
      [INFO] -------------------------------------------------
      [INFO] Build Summary:
      [INFO]   Passed: 119, Failed: 14, Errors: 0, Skipped: 2
      [INFO] -------------------------------------------------
      [ERROR] The following builds failed:
      [ERROR] *  projects\bugs\massembly-306\pom.xml
      [ERROR] *  projects\descriptor-refs\bin\jars-in-archive-root\pom.xml
      [ERROR] *  projects\descriptor-refs\jar-with-dependencies\component-descriptors-merged\pom.xml
      [ERROR] *  projects\descriptor-refs\jar-with-dependencies\deps-unpacked-to-root-dir\pom.xml
      [ERROR] *  projects\descriptor-refs\jar-with-dependencies\no-target-dir\pom.xml
      [ERROR] *  projects\descriptor-refs\project\multimodule-sources-copied\pom.xml
      [ERROR] *  projects\descriptor-refs\project\no-target-dir-multimodule\pom.xml
      [ERROR] *  projects\descriptor-refs\project\no-target-dir\pom.xml
      [ERROR] *  projects\descriptor-refs\project\sources-copied\pom.xml
      [ERROR] *  projects\descriptor-refs\src\no-target-dir\pom.xml
      [ERROR] *  projects\descriptor-refs\src\src-dir-copied\pom.xml
      [ERROR] *  projects\mojo-configuration\manifest-with-customEntry\pom.xml
      [ERROR] *  projects\mojo-configuration\manifest-with-mainClass\pom.xml
      [ERROR] *  projects\mojo-configuration\no-appendAssemblyId-no-classifier\pom.xml
      [INFO] -------------------------------------------------
      [INFO] ------------------------------------------------------------------------
      [INFO] BUILD FAILURE
      [INFO] ------------------------------------------------------------------------
      [INFO] Total time: 12:05 min
      [INFO] Finished at: 2017-06-05T13:14:21+02:00
      [INFO] Final Memory: 88M/1005M
      [INFO] ------------------------------------------------------------------------

      it's time to go back to normal classloader use
      (and it's time also to not flag the plugin as extension in ITs, since it's not the usual configuration for users)

      Attachments

        Issue Links

          Activity

            People

              hboutemy Herve Boutemy
              hboutemy Herve Boutemy
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: