Uploaded image for project: 'WildFly'
  1. WildFly
  2. WFLY-4591

Memory leak inPerThreadTagHandlerPool | Wildfly 8.2.0.Final (Undertow)

    XMLWordPrintable

Details

    Description

      We upgraded from Jboss 7.1.1.Final to Wildfly 8.2.0.Final. After the upgrade we are seeing full frequent garbage collection (happening every 2 mins) during load test. This was not the case in Jboss 7.1.1.Final. Our heap dumps suggested that there is huge memory leak with
      org.apache.jasper.runtime.BodyContentImpl. This is part of JSP runtime (jastow). On analysis we found that undertow uses default as PerThreadTagHanlderPool. By changing this to TagHanlderPool, this issue seems to vanish.

      diff --git a/src/main/java/org/apache/jasper/runtime/TagHandlerPool.java b/src/main/java/org/apache/jasper/runtime/TagHandlerPool.java
      index eaa8560..c6c785f 100644
      — a/src/main/java/org/apache/jasper/runtime/TagHandlerPool.java
      +++ b/src/main/java/org/apache/jasper/runtime/TagHandlerPool.java
      @@ -53,7 +53,7 @@ public class TagHandlerPool

      { result = null; }

      }

      • if( result==null ) result=new PerThreadTagHandlerPool();
        + if( result==null ) result=new TagHandlerPool();
        result.init(config);

      return result;

      I think this issue may be related to https://issues.jboss.org/browse/WFLY-4617 as there were huge garbage created and most of the contents were char array (rendered html). May be TagHanlderPool is creating more char instead of reusing from pool. Please provide thoughts. I can share, heapdump or MAT screenshots if needed.

      Attachments

        Activity

          People

            tomazcerar Tomaž Cerar (Inactive)
            srivathsan_jira Srivathsan Agaram Venkatavaradhan (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: