Return-Path: X-Original-To: apmail-hadoop-hdfs-issues-archive@minotaur.apache.org Delivered-To: apmail-hadoop-hdfs-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id AC92219C45 for ; Thu, 14 Apr 2016 20:30:26 +0000 (UTC) Received: (qmail 52453 invoked by uid 500); 14 Apr 2016 20:30:26 -0000 Delivered-To: apmail-hadoop-hdfs-issues-archive@hadoop.apache.org Received: (qmail 52394 invoked by uid 500); 14 Apr 2016 20:30:26 -0000 Mailing-List: contact hdfs-issues-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: hdfs-issues@hadoop.apache.org Delivered-To: mailing list hdfs-issues@hadoop.apache.org Received: (qmail 52280 invoked by uid 99); 14 Apr 2016 20:30:26 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 14 Apr 2016 20:30:26 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 0D5522C1F4E for ; Thu, 14 Apr 2016 20:30:26 +0000 (UTC) Date: Thu, 14 Apr 2016 20:30:26 +0000 (UTC) From: "Eric Payne (JIRA)" To: hdfs-issues@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (HDFS-9905) TestWebHdfsTimeouts fails occasionally 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/HDFS-9905?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15241844#comment-15241844 ] Eric Payne commented on HDFS-9905: ---------------------------------- bq. java.net.SocksSocketImpl is possible to throw SocketTimeoutException with null message. We seem not to be able to expect that SocketTimeoutException always contains message such as "Read timed out" or "connect timed out". bq. Use GenericTestUtils.assertExceptionContains instead of Assert.assertEquals so that if the string doesn't match, it logs the exception. Thanks, [~iwasakims] and [~jojochuang] for your work on this issue. I don't know what would cause {{SocketTimeoutException}} to give a null message instead of the expected {{Read timed out}}. However, your point about the original stack trace being lost is a very good one: bq. the exception object was reinterpreted in the exception handling, so the original stack trace was lost. In {{WebHdfsFileSystem#AbstractRunner#runWithRetry}}, the code that recreates the exception with the node name should also propagate the stack trace: {code} ioe = ioe.getClass().getConstructor(String.class) .newInstance(node + ": " + ioe.getMessage()); {code} Should be: {code} IOException newIoe = ioe.getClass().getConstructor(String.class) .newInstance(node + ": " + ioe.getMessage()); newIoe.setStackTrace(ioe.getStackTrace()); ioe = newIoe; {code} I can open a separate JIRA for this if you want. > TestWebHdfsTimeouts fails occasionally > -------------------------------------- > > Key: HDFS-9905 > URL: https://issues.apache.org/jira/browse/HDFS-9905 > Project: Hadoop HDFS > Issue Type: Bug > Components: test > Affects Versions: 2.7.3 > Reporter: Kihwal Lee > Assignee: Wei-Chiu Chuang > Attachments: HDFS-9905.001.patch > > > When checking for a timeout, it does get {{SocketTimeoutException}}, but the message sometimes does not contain "connect timed out". Since the original exception is not logged, we do not know details. -- This message was sent by Atlassian JIRA (v6.3.4#6332)