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 B6E0AD8AC for ; Wed, 17 Oct 2012 13:22:22 +0000 (UTC) Received: (qmail 29761 invoked by uid 500); 17 Oct 2012 13:22:22 -0000 Delivered-To: apmail-hadoop-hdfs-issues-archive@hadoop.apache.org Received: (qmail 29697 invoked by uid 500); 17 Oct 2012 13:22:21 -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 29472 invoked by uid 99); 17 Oct 2012 13:22:20 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 17 Oct 2012 13:22:20 +0000 Date: Wed, 17 Oct 2012 13:22:20 +0000 (UTC) From: "Hudson (JIRA)" To: hdfs-issues@hadoop.apache.org Message-ID: <1901298672.57583.1350480140940.JavaMail.jiratomcat@arcas> In-Reply-To: <58920184.47253.1350333184606.JavaMail.jiratomcat@arcas> Subject: [jira] [Commented] (HDFS-4055) TestAuditLogs is flaky 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-4055?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13477864#comment-13477864 ] Hudson commented on HDFS-4055: ------------------------------ Integrated in Hadoop-Mapreduce-trunk #1228 (See [https://builds.apache.org/job/Hadoop-Mapreduce-trunk/1228/]) HDFS-4055. TestAuditLogs is flaky. Contributed by Binglin Chang (Revision 1399093) Result = FAILURE eli : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1399093 Files : * /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt * /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/namenode/TestAuditLogs.java > TestAuditLogs is flaky > ---------------------- > > Key: HDFS-4055 > URL: https://issues.apache.org/jira/browse/HDFS-4055 > Project: Hadoop HDFS > Issue Type: Bug > Reporter: Binglin Chang > Assignee: Binglin Chang > Fix For: 2.0.3-alpha > > Attachments: HDFS-4055-TestAuditLogs-bug.patch > > > {code} > InputStream istream = webfs.open(file); > int val = istream.read(); > istream.close(); > verifyAuditLogsRepeat(true, 3); > assertTrue("failed to read from file", val >= 0); > {code} > {code} > byte[] toWrite = new byte[bufferLen]; > Random rb = new Random(seed); > long bytesToWrite = fileLen; > while (bytesToWrite>0) { > rb.nextBytes(toWrite); > {code} > InputStream.read() return the first byte of the file, the bytes in the file is generated in using Random.nextBytes(), so you get 1/256 chance the first byte is 0, so some times it may fail. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira