Issue Details (XML | Word | Printable)

Key: DIRSERVER-644
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Blocker Blocker
Assignee: Emmanuel Lecharny
Reporter: Emmanuel Lecharny
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Directory ApacheDS

Memory Leak in Persistent search ?

Created: 13/Jun/06 01:39 PM   Updated: 21/Jul/09 10:22 PM
Return to search
Component/s: core
Affects Version/s: 1.5.4, 1.0-RC3
Fix Version/s: 1.5.5

Time Tracking:
Not Specified

File Attachments:
  Size
Java Source File Licensed for inclusion in ASF works SearchTest.java 2006-06-13 01:40 PM Emmanuel Lecharny 3 kB

Resolution Date: 21/Jul/09 10:22 PM


 Description  « Hide
After having profiled memory, it seems we have a memory leak in SessionRegistry.

A little test (attached) does a search N times for N threads, and for each search, a OutstandingRequest is attached to the session. After a few thousands of search we fall in OOM. I've put some trace in those methods :
SessionRegistry.addOutstandingRequest
and
SessionRegistry.removeOutstandingRequest

Session Released
addOutstandingRequest 2
addOutstandingRequest 3
addOutstandingRequest 4
... ( 100 requests)
addOutstandingRequest 99
addOutstandingRequest 100
addOutstandingRequest 101
remove session

The SessionRegistry.removeOutstandingRequest is never called, except if an exception is raised (NamingException).

It may be on purpose ( persistent search), but we can't assume the server will be able to hold as many OutstandingRequest as we have search requests - or entries -.


 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Emmanuel Lecharny made changes - 13/Jun/06 01:40 PM
Field Original Value New Value
Attachment SearchTest.java [ 12335363 ]
Alex Karasulu made changes - 14/Jun/06 06:28 AM
Status Open [ 1 ] In Progress [ 3 ]
Alex Karasulu made changes - 14/Jun/06 07:38 AM
Resolution Fixed [ 1 ]
Status In Progress [ 3 ] Resolved [ 5 ]
Emmanuel Lecharny made changes - 24/Jun/06 06:50 PM
Status Resolved [ 5 ] Closed [ 6 ]
Emmanuel Lecharny made changes - 19/Jun/09 10:59 AM
Assignee Alex Karasulu [ akarasulu ]
Status Closed [ 6 ] Reopened [ 4 ]
Resolution Fixed [ 1 ]
Emmanuel Lecharny made changes - 19/Jun/09 10:59 AM
Affects Version/s 1.5.4 [ 12313147 ]
Fix Version/s 1.0-RC4 [ 12311053 ]
Fix Version/s 1.5.5 [ 12313148 ]
Emmanuel Lecharny made changes - 21/Jul/09 10:21 PM
Assignee Emmanuel Lecharny [ elecharny ]
Emmanuel Lecharny made changes - 21/Jul/09 10:22 PM
Resolution Fixed [ 1 ]
Status Reopened [ 4 ] Closed [ 6 ]