Return-Path: X-Original-To: apmail-tajo-dev-archive@minotaur.apache.org Delivered-To: apmail-tajo-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E9BA310BB8 for ; Mon, 17 Nov 2014 07:30:46 +0000 (UTC) Received: (qmail 94385 invoked by uid 500); 17 Nov 2014 07:30:46 -0000 Delivered-To: apmail-tajo-dev-archive@tajo.apache.org Received: (qmail 94340 invoked by uid 500); 17 Nov 2014 07:30:46 -0000 Mailing-List: contact dev-help@tajo.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@tajo.apache.org Delivered-To: mailing list dev@tajo.apache.org Received: (qmail 94328 invoked by uid 99); 17 Nov 2014 07:30:46 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 17 Nov 2014 07:30:46 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of eminency@gmail.com designates 209.85.214.171 as permitted sender) Received: from [209.85.214.171] (HELO mail-ob0-f171.google.com) (209.85.214.171) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 17 Nov 2014 07:30:20 +0000 Received: by mail-ob0-f171.google.com with SMTP id wp18so15275472obc.2 for ; Sun, 16 Nov 2014 23:28:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:references:from:date:message-id:subject:to :content-type; bh=y92EpxBLKPEpv4IJ/ketXPtlNmNhiqe//7MwSEtuV6w=; b=t9znyFecq+lt0gS5COQRyjcNI0zAvRH2JW3X6R5e0nDXoPRZuwMuuCVJpGEIIYlLO/ gmoVDN9mFIsSh/8kkNGRLXVdEBrvj4UhiTYYGRlVji4f4unanjKmZ1a0DJ2KA2T+1vE5 jJk43IiA38FR2TB3w95YFOu4s9XZEAQ5xWnsHki7H9zMbNNUTL8GZomOsetbSaM3r11v yIfLwKWAWv3OEeYbVZmw/JZ2ARD8NJN5heQEv7kGZcK8Pqo0rvFgofkjllb0s9nFXz1A QW09SGCxx6vZ3VT9LtIVmp/ZpzUlbZkPtq72crKJxoA7GcrXkurdbE1HoaNsMG900d1K gaNw== X-Received: by 10.202.87.212 with SMTP id l203mr21738700oib.36.1416209328591; Sun, 16 Nov 2014 23:28:48 -0800 (PST) MIME-Version: 1.0 References: From: Jong-young Park Date: Mon, 17 Nov 2014 07:28:47 +0000 Message-ID: Subject: Re: Timezone issues To: dev@tajo.apache.org Content-Type: multipart/alternative; boundary=001a113ad19cf55ee6050808ed1a X-Virus-Checked: Checked by ClamAV on apache.org --001a113ad19cf55ee6050808ed1a Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable As I know, there are remained timezone issues currently and somethings are known. Including theses, https://issues.apache.org/jira/browse/TAJO-1063 https://issues.apache.org/jira/browse/TAJO-1064 (One is assigned to me, but never mind. I'm not touching now) As I investigated, timezone problems are connected one another. Thus, if it is modified simply, other problems happens and test cases are failed. So I have delayed the issue for weeks because of other tasks. Anyway, I think no one is taking a look at them and you can handle. Regards, Jongyoung. On Mon Nov 17 2014 at =EC=98=A4=ED=9B=84 12:47:54 Jaewoong Jung wrote: > I found two test cases are failing on my machines due to timezone > issues. (Of course, on unmodified latest clients) > > 1. TestIntervalDatum#testOperation - the one testing DateDatum + > TimeDatume (line #91) > > On my machines, the result value is 2001-09-29 03:00:00, not > 2001-09-28 03:00:00. The reason it fails is, I assume, in > DateDatum#plus, it converts tm2 to a local time before adding it to > tm1, where I see two issues. > > (1) Why does it bother to change it to a local time before adding and > change it back to UTC after that? I don't see any points in doing so. > > (2) Supposing there are some reasons behind it, why does it convert an > "interval" (in this case, tm2) to a local time? Intervals don't have > timezones, so it doesn't make sense at all. And, in my case, since my > machines are set to PST, which is UTC -8:00, it tries to subtract 8 > hours from 3 hours, and I'm thinking it's causing some kind of > underflow error. As a proof, it works just fine if I change DateDatum, > line 129 from DateTimeUtil.toUserTimezone(tm2) to > DateTimeUtil.toUserTimezone(tm1). (tm1 is a TimeMeta of the DateDatum > to add an interval to, and tm2 is the interval's TimeMeta.) > > 2. TestTimestampDatum#testTimestampConstructor, line 163 > > It compares a Calendar instance, which returns local year, month, date > values, with a TimestampDatum instance, which returns UTC year, month, > date values except for toString and asChars values. As a result, it > passes on my machine in the morning, but fails in the evening. > > --- > > Both tests run fine if I change the timezone to London, which is > another reason I strongly believe these are timezone issues. > > Is anyone working on these issues? If not, I can fix them myself. > > Cheers, > Jaewoong > --001a113ad19cf55ee6050808ed1a--