Return-Path: X-Original-To: apmail-incubator-chukwa-commits-archive@www.apache.org Delivered-To: apmail-incubator-chukwa-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 70A4D9FC3 for ; Sun, 25 Mar 2012 10:08:21 +0000 (UTC) Received: (qmail 4322 invoked by uid 500); 25 Mar 2012 10:08:21 -0000 Delivered-To: apmail-incubator-chukwa-commits-archive@incubator.apache.org Received: (qmail 4249 invoked by uid 500); 25 Mar 2012 10:08:19 -0000 Mailing-List: contact chukwa-commits-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: chukwa-dev@incubator.apache.org Delivered-To: mailing list chukwa-commits@incubator.apache.org Received: (qmail 4215 invoked by uid 99); 25 Mar 2012 10:08:17 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 25 Mar 2012 10:08:17 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 25 Mar 2012 10:08:14 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 2C3F62388865; Sun, 25 Mar 2012 10:07:53 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1305002 - in /incubator/chukwa/trunk: CHANGES.txt src/test/java/org/apache/hadoop/chukwa/datacollection/writer/TestChukwaWriters.java Date: Sun, 25 Mar 2012 10:07:53 -0000 To: chukwa-commits@incubator.apache.org From: eyang@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20120325100753.2C3F62388865@eris.apache.org> Author: eyang Date: Sun Mar 25 10:07:52 2012 New Revision: 1305002 URL: http://svn.apache.org/viewvc?rev=1305002&view=rev Log: CHUKWA-638. Fixed timezone offset in test case. (Eric Yang) Modified: incubator/chukwa/trunk/CHANGES.txt incubator/chukwa/trunk/src/test/java/org/apache/hadoop/chukwa/datacollection/writer/TestChukwaWriters.java Modified: incubator/chukwa/trunk/CHANGES.txt URL: http://svn.apache.org/viewvc/incubator/chukwa/trunk/CHANGES.txt?rev=1305002&r1=1305001&r2=1305002&view=diff ============================================================================== --- incubator/chukwa/trunk/CHANGES.txt (original) +++ incubator/chukwa/trunk/CHANGES.txt Sun Mar 25 10:07:52 2012 @@ -12,6 +12,8 @@ Trunk (unreleased changes) CHUKWA-636. Updated dependency to HBase 0.92.0. (Eric Yang) + CHUKWA-638. Fixed timezone offset in test case. (Eric Yang) + Release 0.5 NEW FEATURES Modified: incubator/chukwa/trunk/src/test/java/org/apache/hadoop/chukwa/datacollection/writer/TestChukwaWriters.java URL: http://svn.apache.org/viewvc/incubator/chukwa/trunk/src/test/java/org/apache/hadoop/chukwa/datacollection/writer/TestChukwaWriters.java?rev=1305002&r1=1305001&r2=1305002&view=diff ============================================================================== --- incubator/chukwa/trunk/src/test/java/org/apache/hadoop/chukwa/datacollection/writer/TestChukwaWriters.java (original) +++ incubator/chukwa/trunk/src/test/java/org/apache/hadoop/chukwa/datacollection/writer/TestChukwaWriters.java Sun Mar 25 10:07:52 2012 @@ -323,24 +323,24 @@ public class TestChukwaWriters extends T Date date = formatter.parse("2011/06/15 01:05:00"); currentTimestamps[0] = date.getTime(); - expectedRotateTimestamps[0] = 1308125460000L; //2011/06/15 01:11:00 + expectedRotateTimestamps[0] = 1308096660000L; //2011/06/15 01:11:00 date = formatter.parse("2011/06/15 01:06:00"); currentTimestamps[1] = date.getTime(); - expectedRotateTimestamps[1] = 1308125460000L; //2011/06/15 01:11:00 + expectedRotateTimestamps[1] = 1308096660000L; //2011/06/15 01:11:00 date = formatter.parse("2011/06/15 01:02:00"); currentTimestamps[2] = date.getTime(); - expectedRotateTimestamps[2] = 1308125160000L; //2011/06/15 01:06:00 + expectedRotateTimestamps[2] = 1308096360000L; //2011/06/15 01:06:00 date = formatter.parse("2011/06/15 01:04:00"); currentTimestamps[3] = date.getTime(); - expectedRotateTimestamps[3] = 1308125160000L; //2011/06/15 01:06:00 + expectedRotateTimestamps[3] = 1308096360000L; //2011/06/15 01:06:00 //edge case, when there is a change in the "hour" date = formatter.parse("2011/06/15 01:56:00"); currentTimestamps[4] = date.getTime(); - expectedRotateTimestamps[4] = 1308128460000L; //2011/06/15 02:01:00 + expectedRotateTimestamps[4] = 1308099660000L; //2011/06/15 02:01:00 int i=0; long expectedDelay = 0; @@ -349,7 +349,7 @@ public class TestChukwaWriters extends T expectedDelay = seqFileWriter.getDelayForFixedInterval( currentTimestamps[i], rotateInterval, offsetInterval); actualRotateTimestamp = currentTimestamps[i] + expectedDelay; - Assert.assertTrue("Incorrect value for delay", + Assert.assertTrue("Incorrect value for delay "+i+" current "+currentTimestamps[i]+" expectedDelay "+expectedDelay+" actualRotate "+actualRotateTimestamp+" expectedRotateTimestamp "+expectedRotateTimestamps[i], (actualRotateTimestamp==expectedRotateTimestamps[i])); } @@ -359,24 +359,24 @@ public class TestChukwaWriters extends T date = formatter.parse("2011/06/15 01:05:00"); currentTimestamps[0] = date.getTime(); - expectedRotateTimestamps[0] = 1308125190000L; //2011/06/15 01:06:30 + expectedRotateTimestamps[0] = 1308096390000L; //2011/06/15 01:06:30 date = formatter.parse("2011/06/15 01:04:30"); currentTimestamps[1] = date.getTime(); - expectedRotateTimestamps[1] = 1308125130000L; //2011/06/15 01:05:30 + expectedRotateTimestamps[1] = 1308096330000L; //2011/06/15 01:05:30 date = formatter.parse("2011/06/15 01:05:30"); currentTimestamps[2] = date.getTime(); - expectedRotateTimestamps[2] = 1308125190000L; //2011/06/15 01:06:30 + expectedRotateTimestamps[2] = 1308096390000L; //2011/06/15 01:06:30 date = formatter.parse("2011/06/15 01:04:00"); currentTimestamps[3] = date.getTime(); - expectedRotateTimestamps[3] = 1308125130000L; //2011/06/15 01:05:30 + expectedRotateTimestamps[3] = 1308096330000L; //2011/06/15 01:05:30 //edge case, when there is a change in the "hour" date = formatter.parse("2011/06/15 01:59:30"); currentTimestamps[4] = date.getTime(); - expectedRotateTimestamps[4] = 1308128430000L; //2011/06/15 02:00:30 + expectedRotateTimestamps[4] = 1308099630000L; //2011/06/15 02:00:30 for(i=0; i<5; i++){ expectedDelay = seqFileWriter.getDelayForFixedInterval( @@ -392,16 +392,16 @@ public class TestChukwaWriters extends T date = formatter.parse("2011/06/15 01:02:00"); currentTimestamps[0] = date.getTime(); - expectedRotateTimestamps[0] = 1308125040000L; //2011/06/15 01:04:00 + expectedRotateTimestamps[0] = 1308096240000L; //2011/06/15 01:04:00 date = formatter.parse("2011/06/15 01:02:30"); currentTimestamps[1] = date.getTime(); - expectedRotateTimestamps[1] = 1308125040000L; //2011/06/15 01:04:00 + expectedRotateTimestamps[1] = 1308096240000L; //2011/06/15 01:04:00 //edge case, when there is a change in the "hour" date = formatter.parse("2011/06/15 01:59:30"); currentTimestamps[2] = date.getTime(); - expectedRotateTimestamps[2] = 1308128460000L; //2011/06/15 02:01:00 + expectedRotateTimestamps[2] = 1308099660000L; //2011/06/15 02:01:00 for(i=0; i<3; i++){ expectedDelay = seqFileWriter.getDelayForFixedInterval( @@ -417,16 +417,16 @@ public class TestChukwaWriters extends T date = formatter.parse("2011/06/15 01:02:00"); currentTimestamps[0] = date.getTime(); - expectedRotateTimestamps[0] = 1308125100000L; //2011/06/15 01:05:00 + expectedRotateTimestamps[0] = 1308096300000L; //2011/06/15 01:05:00 date = formatter.parse("2011/06/15 01:02:30"); currentTimestamps[1] = date.getTime(); - expectedRotateTimestamps[1] = 1308125100000L; //2011/06/15 01:05:00 + expectedRotateTimestamps[1] = 1308096300000L; //2011/06/15 01:05:00 //edge case, when there is a change in the "hour" date = formatter.parse("2011/06/15 01:59:30"); currentTimestamps[2] = date.getTime(); - expectedRotateTimestamps[2] = 1308128520000L; //2011/06/15 02:02:00 + expectedRotateTimestamps[2] = 1308099720000L; //2011/06/15 02:02:00 for(i=0; i<3; i++){ expectedDelay = seqFileWriter.getDelayForFixedInterval(