[jboss-jira] [JBoss JIRA] (AS7-4675) Memory leak when reading EJB 2.1 CMP EntityBeans

jaikiran pai (JIRA) jira-events at lists.jboss.org
Fri May 4 05:56:20 EDT 2012


    [ https://issues.jboss.org/browse/AS7-4675?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12690366#comment-12690366 ] 

jaikiran pai commented on AS7-4675:
-----------------------------------

I still can't reproduce a leak here. I tested the attached application against current upstream:

1) Deployed the application
2) Ran the remote client which triggers entity bean instance creation (around 90K) 
3) Undeployed the application after the client finished

Monitored this entire run using JProfiler and after the undeployment, I don't see any references being held to org.jboss.invocation.Interceptor or any other related classes for the application.

Are you sure the instances stick around after undeploying the application? Can you take a JProfiler snapshot after the application undeployment and attach it here?

By the way, I've attached the Maven version of your project, if anyone else wants to test it, outside of an IDE. Here's how you run it:

1) mvn clean install
2) Start the server and cp target/JCTest.jar JBOSS_HOME/standalone/deployments
3) mvn exec:exec


                
> Memory leak when reading EJB 2.1 CMP EntityBeans
> ------------------------------------------------
>
>                 Key: AS7-4675
>                 URL: https://issues.jboss.org/browse/AS7-4675
>             Project: Application Server 7
>          Issue Type: Bug
>          Components: EJB
>    Affects Versions: 7.1.1.Final
>         Environment: Windows 7 Pro SP1 (64bit);  JDK 1.6.0_31 (64bit); Oracle Database 11g Release 11.1.0.6.0 - 64bit Production; AS71.1Final / AS71.2 latest build
>            Reporter: Klaus Benary
>            Assignee: jaikiran pai
>         Attachments: JCTest-maven.zip, JCTest.zip
>
>
> 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 

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the jboss-jira mailing list