Return-Path: X-Original-To: apmail-directory-dev-archive@www.apache.org Delivered-To: apmail-directory-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 9D87149A9 for ; Mon, 23 May 2011 20:54:28 +0000 (UTC) Received: (qmail 20721 invoked by uid 500); 23 May 2011 20:54:28 -0000 Delivered-To: apmail-directory-dev-archive@directory.apache.org Received: (qmail 20688 invoked by uid 500); 23 May 2011 20:54:28 -0000 Mailing-List: contact dev-help@directory.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Apache Directory Developers List" Delivered-To: mailing list dev@directory.apache.org Received: (qmail 20679 invoked by uid 99); 23 May 2011 20:54:28 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 23 May 2011 20:54:28 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 23 May 2011 20:54:27 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 726C2DA4BB for ; Mon, 23 May 2011 20:53:47 +0000 (UTC) Date: Mon, 23 May 2011 20:53:47 +0000 (UTC) From: "Emmanuel Lecharny (JIRA)" To: dev@directory.apache.org Message-ID: <1512141342.37351.1306184027465.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Resolved] (DIRSHARED-108) Recursively drilling into the directory structure causes java.lang.OutOfMemoryError MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/DIRSHARED-108?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Emmanuel Lecharny resolved DIRSHARED-108. ----------------------------------------- Resolution: Cannot Reproduce Closed. If someone has a clear evidence that the latest version has some issue, feel free to reopen the issue > Recursively drilling into the directory structure causes java.lang.OutOfMemoryError > ----------------------------------------------------------------------------------- > > Key: DIRSHARED-108 > URL: https://issues.apache.org/jira/browse/DIRSHARED-108 > Project: Directory Shared > Issue Type: Bug > Affects Versions: 1.0.0-M1 > Environment: Windows XP SP3 > Reporter: Sebu Koleth > Fix For: 1.0.0-M4 > > Attachments: ApacheLdapAPITest.java, UnboundidLdapAPITest.java > > > private static void recursivelyDescend(LdapConnection connection, String dn) { > System.out.println("Searching for children of dn : " + dn); > try > { > Cursor cursor = connection.search(dn, "(objectclass=*)", SearchScope.ONELEVEL, "*"); > while (cursor.next()) > { > SearchResponse response = cursor.get(); > if(response instanceof SearchResultEntry) { > recursivelyDescend(connection, ((SearchResultEntry)response).getObjectName().getName()); > } else { > System.out.println("Unusable response type " + response); > } > } > } catch (LdapException le) { > le.printStackTrace(); > } catch (Exception e) { > e.printStackTrace(); > } > } > The above piece of code is exercised after obtaining an SSL-based LDAP connection. The target server has hundreds of thousands of records at different levels. Logging at WARN level shows a *lot* of messages : > WARN NioProcessor-1 org.apache.directory.shared.asn1.ber.Asn1Decoder - The PDU has been fully decoded but there are still bytes in the buffer. > The code chokes at processing the 52nd entry that is two levels deep from the base DN. At this level there are around 1000 sub-levels. -- This message is automatically generated by JIRA. For more information on JIRA, see: http://www.atlassian.com/software/jira