glassfish
  1. glassfish
  2. GLASSFISH-18628

Reference clearing should be disabled by default

    Details

    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 3.1.2
    • Fix Version/s: 4.0_b34
    • Component/s: web_container
    • Labels:
      None

      Description

      This is a follow-up to GLASSFISH-6637.

      Tomcat 7 changes the default value of ENABLE_CLEAR_REFERENCES from true to false and instead issues warnings of possible leaks. I recommend Glassfish follows suit because clearing static references still causes some serious problems with log4j and other libraries (I just ran into a problem with the bonecp library).

      See http://tomcat.apache.org/tomcat-7.0-doc/config/context.html "clearReferencesStatic" and similar properties (which now default to false)

        Activity

        Hide
        Shing Wai Chan added a comment -

        Besides changing default value, we also refactoring the code as in Tomcat 7.

        Adding war-util/src/main/java/org/glassfish/web/loader/ExceptionUtils.java
        Adding war-util/src/main/java/org/glassfish/web/loader/JdbcLeakPrevention.java
        Sending war-util/src/main/java/org/glassfish/web/loader/WebappClassLoader.java
        Sending war-util/src/main/resources/com/sun/logging/enterprise/system/container/web/LogStrings.properties
        Transmitting file data ....
        Committed revision 53590.

        Show
        Shing Wai Chan added a comment - Besides changing default value, we also refactoring the code as in Tomcat 7. Adding war-util/src/main/java/org/glassfish/web/loader/ExceptionUtils.java Adding war-util/src/main/java/org/glassfish/web/loader/JdbcLeakPrevention.java Sending war-util/src/main/java/org/glassfish/web/loader/WebappClassLoader.java Sending war-util/src/main/resources/com/sun/logging/enterprise/system/container/web/LogStrings.properties Transmitting file data .... Committed revision 53590.

          People

          • Assignee:
            Shing Wai Chan
            Reporter:
            cowwoc
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: