Return-Path: X-Original-To: apmail-hbase-user-archive@www.apache.org Delivered-To: apmail-hbase-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 799E917953 for ; Thu, 6 Nov 2014 17:02:53 +0000 (UTC) Received: (qmail 91387 invoked by uid 500); 6 Nov 2014 17:02:51 -0000 Delivered-To: apmail-hbase-user-archive@hbase.apache.org Received: (qmail 91326 invoked by uid 500); 6 Nov 2014 17:02:51 -0000 Mailing-List: contact user-help@hbase.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hbase.apache.org Delivered-To: mailing list user@hbase.apache.org Received: (qmail 90982 invoked by uid 99); 6 Nov 2014 17:02:50 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 06 Nov 2014 17:02:50 +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 (athena.apache.org: domain of yuzhihong@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; Thu, 06 Nov 2014 17:02:46 +0000 Received: by mail-ob0-f171.google.com with SMTP id wp18so1176528obc.2 for ; Thu, 06 Nov 2014 09:01:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=M66Y0WiACN/00eQBSkgPCJjWEPNGo1UTIcHsjKkG/ls=; b=ryW2f7w7T/HNAIkRqVis2xOVVxDVv8jUA/7/GxKSuACB3wf0NLUaxkPUuhQLj3zgS0 9eRxCC81f9jdvbj//ZWnU2jnemirfm8W5NoSlOeDgtOv17jlCQFZtkf7LXjR8qm1UCxT dmkvCu4nfcr+oWyvCOZ1AZTSpLIEhfmWZ/oYsP6f1cjh7WnLhNAmKwJAsur6yUa8SOq7 O9HBqaKzWTAg0CtccRJ4F7CiCi56FbIyx2IgVMoD8bp4SpNDh/u0Clk6RsBhh1F73lZS 5+LDKi+5P9Wq4kHhd69IQSlaLwbLdlQ2wKQuEDXF8IFmNS9HXuQhsG6uuwl2e5rlsfQP Iz7g== MIME-Version: 1.0 X-Received: by 10.182.121.129 with SMTP id lk1mr1989757obb.83.1415293300847; Thu, 06 Nov 2014 09:01:40 -0800 (PST) Received: by 10.202.65.130 with HTTP; Thu, 6 Nov 2014 09:01:40 -0800 (PST) In-Reply-To: <150xtipwh34np7wqv931gelm.1415286303933@email.android.com> References: <150xtipwh34np7wqv931gelm.1415286303933@email.android.com> Date: Thu, 6 Nov 2014 09:01:40 -0800 Message-ID: Subject: Re: key byte pattern From: Ted Yu To: "user@hbase.apache.org" Content-Type: multipart/alternative; boundary=089e013c5da6733af6050733a6cb X-Virus-Checked: Checked by ClamAV on apache.org --089e013c5da6733af6050733a6cb Content-Type: text/plain; charset=UTF-8 See http://hbase.apache.org/book.html#keysize Cheers On Thu, Nov 6, 2014 at 7:05 AM, David Larsen wrote: > You could simply take the timestamp as a Long and store it as as a byte > array. > > What's the main advantage you are after with smaller keys? > > > Sent from my Verizon Wireless 4G LTE smartphone > > > -------- Original message -------- > From: Rita > Date:11/06/2014 4:19 AM (GMT-08:00) > To: hbase-user@hadoop.apache.org > Subject: key byte pattern > > ATM, i have a key which is a string. > > "Z.1415276116.223232" > > Are there any algorithms or design patterns I should follow for something > like this to decrease the key size? Obviously, storing it as a String is > costly was wondering if there was a better way to store something like > this? > BTW, 1415276116.223232 is a epoch second > > > > -- > --- Get your facts first, then you can distort them as you please.-- > --089e013c5da6733af6050733a6cb--