Uploaded image for project: 'Portals Apps (Retired)'
  1. Portals Apps (Retired)
  2. APA-48

WebResourceUtils bombs with NPX if application is packaged as a non-expanded WAR file under Tomcat

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Blocker
    • Resolution: Fixed
    • apa-webcontent-1.2
    • apa-webcontent-1.3
    • apa-webcontent
    • None

    Description

      While testing an application configuration when packaged as a non-expanded WAR file the DefaultHttpReverseProxyServlet dies with a NullPointerException when calling WebResourceUtils.getResourcesAsFiles(String, ClassLoader, Object).

      The reason for this is that when packaged in a WAR file and not expanded, Tomcat provides a WARDirContext which returns null when requesting "getRealPath"

      Would it be possible to change this around such that the code is not dealing with files specifically and dealing with them as references & streams?

      This configuration issue is a blocker for my current product.

      If possible could the ServletContext.getResource/getResourceAsStream be used to determine the resource location and load it that way when "/WEB-INF/" is the start of the path?

      Attachments

        Issue Links

          Activity

            People

              woon_san Woonsan Ko
              djgraff David Graff
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: