Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 38310 invoked from network); 17 Feb 2007 21:46:27 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 17 Feb 2007 21:46:27 -0000 Received: (qmail 37254 invoked by uid 500); 17 Feb 2007 21:46:35 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 37043 invoked by uid 500); 17 Feb 2007 21:46:34 -0000 Mailing-List: contact derby-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: Delivered-To: mailing list derby-dev@db.apache.org Received: (qmail 37034 invoked by uid 99); 17 Feb 2007 21:46:34 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 17 Feb 2007 13:46:34 -0800 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 17 Feb 2007 13:46:25 -0800 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 8D48F7141E1 for ; Sat, 17 Feb 2007 13:46:05 -0800 (PST) Message-ID: <22026322.1171748765543.JavaMail.jira@brutus> Date: Sat, 17 Feb 2007 13:46:05 -0800 (PST) From: "Daniel John Debrunner (JIRA)" To: derby-dev@db.apache.org Subject: [jira] Commented: (DERBY-2344) 'java.lang.OutOfMemoryError: Java heap space' in NetworkServerThread In-Reply-To: <31764776.1171616765500.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/DERBY-2344?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12473962 ] Daniel John Debrunner commented on DERBY-2344: ---------------------------------------------- I created a simple test that only opens and closes a statement and added to a suite 6000 times (to mimic the ~6000 fixtures in suites.All). Running this seems to show no memory leak under windows, but some more testing on other platforms would be good. If this shows no leaks then it's very confusing what the problem is, given my earlier tests seem to show it was related to the test code and not the engine. package org.apache.derbyTesting.functionTests.tests.jdbcapi; import java.sql.SQLException; import junit.framework.Test; import junit.framework.TestSuite; import org.apache.derbyTesting.junit.BaseJDBCTestCase; public class ManyTest extends BaseJDBCTestCase { public ManyTest(String name) { super(name); // TODO Auto-generated constructor stub } public static Test suite() { TestSuite suite = new TestSuite("ManyTest"); for (int i = 0; i < 6000; i++) { suite.addTest(new ManyTest("testConnection")); } return suite; } public void testConnection() throws SQLException { createStatement().close(); } } > 'java.lang.OutOfMemoryError: Java heap space' in NetworkServerThread > -------------------------------------------------------------------- > > Key: DERBY-2344 > URL: https://issues.apache.org/jira/browse/DERBY-2344 > Project: Derby > Issue Type: Bug > Affects Versions: 10.3.0.0 > Environment: JVM: Sun Microsystems Inc. - 1.5.0_05-b05 > OS: Fedora Core release 5 (Bordeaux) 32bits - Linux 2.6.17-1.2174_FC5 #1 Tue Aug 8 15:30:55 EDT 2006 > HW: 1 X Intel(R) Pentium(R) 4 CPU 2.66GHz: 2656.261 MHz, 512 KB cache. 773284 kB Total Memory. > JVM: Sun Microsystems Inc. 1.5.0_06-b04 > OS: Solaris Nevada snv_27a X86 64 bits - SunOS 5.11 snv_27 > HW: 1 X x86 AuthenticAMD family 15 model 36 step 2 (AMD Turion(tm) 64 Mobile Technology ML-37): 2000 MHz, unknown cache. 1023 Megabytes Total Memory > JVM: Sun Microsystems Inc. - 1.5.0_05-b05 > OS: Microsoft Windows XP Professional - 5.1.2600 Service Pack 2 Build 2600 - CYGWIN_NT-5.1 1.5.18(0.132/4/2) 2005-07-02 20:30 Cygwin > HW: 1 X Ferrari 4000 x86 Family 15 Model 36 Stepping 2 AuthenticAMD: ~2000 MHz, 2,048 MB cache. 1,022 Total Memory. > Reporter: Ole Solberg > Attachments: VM_Summary-1.txt, VM_Summary-507428JDK14Jvm15-clientjvm.jpg, VM_Summary-507428JDK6Jvm6-clientjvm.jpg, VM_Summary-J507152DK14Jvm15-clientjvm.jpg, VM_Summary-serverJvm-PS_Old_Gen.jpg, VM_Summary-serverJvm.jpg, VM_Summary-serverJvm.txt, VM_Summary.jpg > > > I see this only on test machines with 1Gb of memory or less. Our lab-machines with 2Gb mem show now problems. > See http://dbtg.thresher.com/derby/test/trunk15/jvm1.5/testing/Limited/testSummary-508068.html > Extract from a typical thread dump: > "main" prio=1 tid=0x09e2a760 nid=0xef6 runnable [0xbfd89000..0xbfd8a418] > at java.net.SocketInputStream.socketRead0(Native Method) > at java.net.SocketInputStream.read(SocketInputStream.java:129) > at org.apache.derby.client.net.Reply.fill(Unknown Source) > at org.apache.derby.client.net.Reply.ensureALayerDataInBuffer(Unknown Source) > at org.apache.derby.client.net.Reply.readDssHeader(Unknown Source) > at org.apache.derby.client.net.Reply.startSameIdChainParse(Unknown Source) > at org.apache.derby.client.net.NetConnectionReply.readExchangeServerAttributes(Unknown Source) > at org.apache.derby.client.net.NetConnection.readServerAttributesAndKeyExchange(Unknown Source) > at org.apache.derby.client.net.NetConnection.flowServerAttributesAndKeyExchange(Unknown Source) > at org.apache.derby.client.net.NetConnection.flowUSRIDPWDconnect(Unknown Source) > at org.apache.derby.client.net.NetConnection.flowConnect(Unknown Source) > at org.apache.derby.client.net.NetConnection.(Unknown Source) > at org.apache.derby.client.net.ClientJDBCObjectFactoryImpl.newNetConnection(Unknown Source) > at org.apache.derby.jdbc.ClientDriver.connect(Unknown Source) > at java.sql.DriverManager.getConnection(DriverManager.java:525) > - locked <0x8cda8a18> (a java.lang.Class) > at java.sql.DriverManager.getConnection(DriverManager.java:171) > - locked <0x8cda8a18> (a java.lang.Class) > at org.apache.derbyTesting.junit.DriverManagerConnector.openConnection(DriverManagerConnector.java:76) > at org.apache.derbyTesting.junit.DriverManagerConnector.openConnection(DriverManagerConnector.java:43) > at org.apache.derbyTesting.junit.TestConfiguration.openDefaultConnection(TestConfiguration.java:764) > at org.apache.derbyTesting.junit.BaseJDBCTestCase.openDefaultConnection(BaseJDBCTestCase.java:205) > at org.apache.derbyTesting.junit.BaseJDBCTestCase.getConnection(BaseJDBCTestCase.java:90) > at org.apache.derbyTesting.functionTests.tests.jdbcapi.BlobClob4BlobTest.setUp(BlobClob4BlobTest.java:56) > at junit.framework.TestCase.runBare(TestCase.java:128) > . > . -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.