Uploaded image for project: 'Application Server 7'
  1. Application Server 7
  2. AS7-4675

Memory leak when reading EJB 2.1 CMP EntityBeans

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Critical
    • 7.1.2.Final (EAP)
    • 7.1.1.Final
    • EJB
    • None

    Description

      After reading 12000 EJB 2.1 EntityBeans in a test application there are about 5 million Interceptor[] arrays firmely bound in the heap. A heap dump shows this as a typical reference chain:

      GC Root: ServiceContainerImpl$ServiceThread
      ServiceContainerImpl$ServiceThread.container = ServiceContainerImpl
      ServiceContainerImpl.registry = UnlockedReadHashMap
      UnlockedReadHashMap.table = AtomicReferenceArray
      AtomicReferenceArray.array = Object[16384]
      Object[6209] = UnlockedReadHashMap$Item[3]
      UnlockedReadHashMap$Item[1] = UnlockedReadHashMap$Item
      UnlockedReadHashMap$Item.value = ServiceRegistrationImpl
      ServiceRegistrationImpl.instance = ServiceControllerImpl
      ServiceControllerImpl.serviceValue = ImmediateValue
      ImmediateValue.value = TimedObjectInvokerImpl
      TimedObjectInvokerImpl.timeoutInterceptors = HashMap
      HashMap.table = HashMap$Entry[128]
      HashMap$Entry[123] = HashMap$Entry
      HashMap$Entry.value = ChainedInterceptor
      ChainedInterceptor.interceptors = Arrays$ArrayList
      Arrays$ArrayList.a = Interceptor[6]

      The number of bound objects keeps growing when reading more EntityBeans - even wehn reading the same beans again.
      Even after undeploy of the application the

      Attachments

        1. HeapDumpScreenShot.png
          HeapDumpScreenShot.png
          81 kB
        2. JCTest.zip
          50 kB
        3. JCTest-maven.zip
          34 kB

        Activity

          People

            sdouglas1@redhat.com Stuart Douglas
            k_benary Klaus Benary (Inactive)
            Votes:
            2 Vote for this issue
            Watchers:
            10 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: