Uploaded image for project: 'Confluence Cloud'
  1. Confluence Cloud
  2. CONFCLOUD-18094

Bundle sun-web.xml with classloader settings required for GlassFish (PATCH)

XMLWordPrintable

    • Our product teams collect and evaluate feedback from a number of different sources. To learn more about how we use customer feedback in the planning process, check out our new feature policy.

      NOTE: This suggestion is for Confluence Cloud. Using Confluence Server? See the corresponding suggestion.

      Confluence won't work properly on Glassfish (v2.1 or v3) unless the classloader delegation is switched off. This can be configured via sun-web.xml which could be bundled with Confluence without affecting any other containers.

      diff -r 39c81074bb98 confluence/confluence-project/conf-webapp/src/main/webapp/WEB-INF/sun-web.xml
      --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
      +++ b/confluence/confluence-project/conf-webapp/src/main/webapp/WEB-INF/sun-web.xml	Sun Dec 20 09:28:16 2009 -0800
      @@ -0,0 +1,9 @@
      +<?xml version="1.0" encoding="UTF-8"?>
      +
      +<!DOCTYPE sun-web-app
      +        PUBLIC "-//Sun Microsystems, Inc.//DTD Application Server 8.1 Servlet 2.4//EN"
      +        "http://www.sun.com/software/appserver/dtds/sun-web-app_2_4-1.dtd">
      +
      +<sun-web-app error-url="">
      +    <class-loader delegate="false"/>
      +</sun-web-app>
      

      Unless the classloader delegation if turned off, the container will try to use container's classloader to load classes before the application specific classloader is used. This will result in all kinds of weird errors in cases where same libraries but different versions are bundled with both Confluence and GlassFish (e.g. Felix, Xalan, etc).

        1. sun-web.xml
          0.3 kB
          Igor Minar

              Unassigned Unassigned
              15d9a6950818 Igor Minar
              Votes:
              6 Vote for this issue
              Watchers:
              5 Start watching this issue

                Created:
                Updated:
                Resolved: