Uploaded image for project: 'ShrinkWrap'
  1. ShrinkWrap
  2. SHRINKWRAP-266

Manifest container for WebArchive should be WEB-INF/classes/META-INF

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: 1.0.0-alpha-12
    • Fix Version/s: 1.0.0-beta-3
    • Component/s: impl-base
    • Labels:
      None

      Description

      This issue is a regression of SHRINKWRAP-186. The location of the ManifestContainer for a WebArchive should be /WEB-INF/classes/META-INF, not /META-INF. This location is backed up by our target locations per archive type page.

      http://community.jboss.org/wiki/Containerrootsperspecarchive

      A sample use case is bundling a persistence.xml in a web archive:

      WebArchive war = ShrinkWrap.create(WebArchive.class, "test.war")
         .addAsManifestResource("test-persistence.xml", "persistence.xml");
      System.out.println(war.toString(true));
      

      Current output:

      test.war
      /META-INF/
      /META-INF/persistence.xml
      

      Expected output:

      test.war
      /WEB-INF/
      /WEB-INF/classes/
      /WEB-INF/classes/persistence.xml
      

      This also breaks the ServiceLoader registrations, as they appear in /META-INF/services/ rather than in /WEB-INF/classes/META-INF/services/

        Attachments

          Activity

            People

            Assignee:
            tommysdk Tommy Tynjä (Inactive)
            Reporter:
            dan.j.allen Dan Allen (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: