Return-Path: Delivered-To: apmail-harmony-dev-archive@www.apache.org Received: (qmail 46606 invoked from network); 11 Sep 2009 22:14:51 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 11 Sep 2009 22:14:51 -0000 Received: (qmail 87989 invoked by uid 500); 11 Sep 2009 22:14:50 -0000 Delivered-To: apmail-harmony-dev-archive@harmony.apache.org Received: (qmail 87908 invoked by uid 500); 11 Sep 2009 22:14:50 -0000 Mailing-List: contact dev-help@harmony.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@harmony.apache.org Delivered-To: mailing list dev@harmony.apache.org Received: (qmail 87897 invoked by uid 99); 11 Sep 2009 22:14:50 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 11 Sep 2009 22:14:50 +0000 X-ASF-Spam-Status: No, hits=-2.8 required=10.0 tests=RCVD_IN_DNSWL_MED,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (athena.apache.org: 195.212.29.140 is neither permitted nor denied by domain of mark.hindess@googlemail.com) Received: from [195.212.29.140] (HELO mtagate7.uk.ibm.com) (195.212.29.140) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 11 Sep 2009 22:14:39 +0000 Received: from d06nrmr1407.portsmouth.uk.ibm.com (d06nrmr1407.portsmouth.uk.ibm.com [9.149.38.185]) by mtagate7.uk.ibm.com (8.14.3/8.13.8) with ESMTP id n8BMDwOQ688714 for ; Fri, 11 Sep 2009 22:14:03 GMT Received: from d06av03.portsmouth.uk.ibm.com (d06av03.portsmouth.uk.ibm.com [9.149.37.213]) by d06nrmr1407.portsmouth.uk.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id n8BMDmTd1364194 for ; Fri, 11 Sep 2009 23:13:48 +0100 Received: from d06av03.portsmouth.uk.ibm.com (loopback [127.0.0.1]) by d06av03.portsmouth.uk.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id n8BMDmke027090 for ; Fri, 11 Sep 2009 23:13:48 +0100 Received: from anaheim.local (sev93551.de.ibm.com [9.145.166.153]) by d06av03.portsmouth.uk.ibm.com (8.12.11.20060308/8.12.11) with ESMTP id n8BMDlFF027083 for ; Fri, 11 Sep 2009 23:13:48 +0100 Message-Id: <200909112213.n8BMDlFF027083@d06av03.portsmouth.uk.ibm.com> X-Mailer: exmh version 2.7.2 01/07/2005 (debian 1:2.7.2-16) with nmh-1.2 From: "Mark Hindess" To: "Apache Harmony Dev List" Subject: [classlib] java.io.DataOutputStream behaviour doesn't match RI Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Fri, 11 Sep 2009 23:13:41 +0100 X-Virus-Checked: Checked by ClamAV on apache.org I am trying to work through the JDWP java6 branch test failures (so is Oliver). I see quite a lot of intermittent failures on Linux[0]. I think they are mostly caused by failures at the time when the socket used for synchronising the debuggee/debugger is being closed. The sychronisation is simply one end calling "DataOutputStream.writeUTF("continue"); DataOutputStream.flush();" and the other end trying to do DataInputStream.readUTF(). When running on the RI, the tests pass consistently. Strace of the RI shows the writeUTF making syscalls like: send(10, "\0\10continue", 10, 0) = 10 close(10) = 0 where as our implementation does: send(58, "\0\10", 2, 0) = 2 send(58, "continue", 8, 0) = 8 close(58) = 0 Examining the packet dump for the socket shows a packet containing the length ('\0\10') followed by a RST packet as the socket is closed but no packet containing the "continue" text. So, the "continue" is lost with the result that the other end reads the length then loops waiting for the message until the test timeout is reached.[1] I think it would probably be useful if we fixed our implementation to have the same behaviour as the RI. Regards, Mark. [0] I'm using org.apache.harmony.jpda.tests.jdwp.MultiSession.RefTypeIDTest for testing but there are plenty of intermittently failing tests to choose from. [1] I wonder why doesn't it see the socket close and bail out? This is probably another bug (perhaps with the framework).