Uploaded image for project: 'OFBiz'
  1. OFBiz
  2. OFBIZ-5521

WebAppUtil.getWebappInfoFromWebsiteId throws IllegalArgumentException when web.xml not found

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • Trunk
    • 16.11.01
    • ALL COMPONENTS
    • None

    Description

      WebAppUtil.getWebappInfoFromWebsiteId throws IllegalArgumentException when web.xml does not exist in applications/content/webapp/content/images/WEB-INF/web.xml. This causes org.ofbiz.common.email.NotificationServices.setBaseUrl to fail when webSiteId is a custom component site id.

      Stack trace
      java.lang.IllegalArgumentException: applications/content/webapp/content/images/WEB-INF/web.xml does not exist.
      org.ofbiz.webapp.WebAppUtil.parseWebXmlFile(WebAppUtil.java:148)
      org.ofbiz.webapp.WebAppUtil.getWebXml(WebAppUtil.java:131)
      org.ofbiz.webapp.WebAppUtil.getWebSiteId(WebAppUtil.java:117)
      org.ofbiz.webapp.WebAppUtil.getWebappInfoFromWebsiteId(WebAppUtil.java:100)
      org.ofbiz.common.email.NotificationServices.setBaseUrl(NotificationServices.java:262)
      org.ofbiz.common.email.NotificationServices.prepareNotification(NotificationServices.java:200)
      org.ofbiz.common.email.NotificationServices.sendNotification(NotificationServices.java:132)

      Attachments

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            jleroux Jacques Le Roux
            gareth.carter Gareth Carter
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment