XMLWordPrintable

    Details

      Description

      Given

      A Deployment method

      When

      war.addAsManifestResource(X, "beans.xml")
      ear.addAsManifestResource(X, "beans.xml")
      war.addAsManifestResource(X, "persistence.xml")
      

      Then

      Warn that known EE descriptor files are in the wrong location

      Some mapping on top of my head:

      WebArchive

      web.xml          -> /WEB-INF/
      web-fragment.xml -> Not supported ? 
      beans.xml        -> /WEB-INF/
      persistence.xml  -> /WEB-INF/classes/META-INF/
      ejb-jar.xml      -> /WEB-INF/classes/META-INF/
      

      JavaArchive

      web.xml          -> Not supported
      web-fragment.xml -> /META-INF/
      beans.xml        -> /META-INF/
      persistence.xml  -> /META-INF/
      ejb-jar.xml      -> /META-INF/
      

      EnterpriseArchive

      beans.xml        -> Not supported
      persistence.xml  -> Not supported
      ejb-jar.xml      -> Not supported
      application.xml  -> /META-INF/
      

      One common mistake is using addAsManifestResource on WebArchives. A quickfix / suggestion would be to use addAsWebInfResource for the files located in /WEB-INF/

        Attachments

          Activity

            People

            Assignee:
            snjeza Snjezana Peco (Inactive)
            Reporter:
            aslak Aslak Knutsen
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: