I am trying to diagnose a memory leak in the android application that I am writing. I got a bunch of heaps loaded in Eclipse, but the results that I see are very curious. There are about 20,000 exception instances (notably LDAPException from the LDAP UnboundID library) on the heap without inbound links.
That is, they appear in the root of the dominant tree. OQL SELECT objects e FROM com.unboundid.ldap.sdk.LDAPException e WHERE (inbounds(e).length = 0) returns more than 20,000 results, which corresponds to almost the entire heap. Nevertheless, GC works before the heap dump, and I see that it works on the console repeatedly during the execution of leaky code. If these instances do not have inbound links, what can support them?
I also tried to execute the "shortest paths to the GC" query. It shows one LDAPConnectionReader line that stores 2 instances, and ~ 20k LDAPException @ <addr> unknown lines with different hexadecimal addresses.
Update . I did not have time to continue to diagnose this, after publishing it, and the award I noted ends earlier than I probably will. I reward him as best as possible so that the glasses are not wasted. Thanks to everyone who looked into this! I will come back later and again clarify the results of a further diagnosis, when life will be a little less hectic.
java android memory-leaks
Walter mundt
source share