Return-Path: Delivered-To: apmail-hadoop-hbase-dev-archive@minotaur.apache.org Received: (qmail 82276 invoked from network); 22 Oct 2009 20:45:22 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 22 Oct 2009 20:45:22 -0000 Received: (qmail 4427 invoked by uid 500); 22 Oct 2009 20:45:21 -0000 Delivered-To: apmail-hadoop-hbase-dev-archive@hadoop.apache.org Received: (qmail 4396 invoked by uid 500); 22 Oct 2009 20:45:21 -0000 Mailing-List: contact hbase-dev-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: hbase-dev@hadoop.apache.org Delivered-To: mailing list hbase-dev@hadoop.apache.org Received: (qmail 4386 invoked by uid 99); 22 Oct 2009 20:45:21 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 22 Oct 2009 20:45:21 +0000 X-ASF-Spam-Status: No, hits=-10.5 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 22 Oct 2009 20:45:19 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 8373E234C1EF for ; Thu, 22 Oct 2009 13:44:59 -0700 (PDT) Message-ID: <566387540.1256244299537.JavaMail.jira@brutus> Date: Thu, 22 Oct 2009 20:44:59 +0000 (UTC) From: "Dave Latham (JIRA)" To: hbase-dev@hadoop.apache.org Subject: [jira] Updated: (HBASE-1930) Put.setTimeStamp misleading (doesn't change timestamp on existing KeyValues, not copied in copy constructor) In-Reply-To: <1750581611.1256244059540.JavaMail.jira@brutus> 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/HBASE-1930?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Dave Latham updated HBASE-1930: ------------------------------- Fix Version/s: (was: 0.20.2) 0.21.0 Realized this fix shouldn't go on branch, because it's an api change. > Put.setTimeStamp misleading (doesn't change timestamp on existing KeyValues, not copied in copy constructor) > ------------------------------------------------------------------------------------------------------------ > > Key: HBASE-1930 > URL: https://issues.apache.org/jira/browse/HBASE-1930 > Project: Hadoop HBase > Issue Type: Bug > Components: client > Affects Versions: 0.20.0, 0.20.1 > Reporter: Dave Latham > Priority: Minor > Fix For: 0.21.0 > > Attachments: 1930.patch > > > In the process of migrating some code from 0.19, and was changing BatchUpdate's to Put's. I was hit by a bit of a gotcha. In the old code, I populated the BatchUpdate, then set the timestamp. However, this doesn't wotk for Put, because Put creates KeyValue's with the currently set timestamp when adding values. Setting the timestamp at the end has no effect. Also, the copy constructor doesn't copy the timestamp (or writeToWAL) setting. > One option would be to simply update the javadoc to make it clear that the timestamp needs to be set prior to adding values. I'm attaching a proposed patch which moves the timestamp setting to constructor only so that it isn't possible to trigger the confusing case at all. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.