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 70589DCBF for ; Wed, 10 Oct 2012 19:08:48 +0000 (UTC) Received: (qmail 33170 invoked by uid 500); 10 Oct 2012 19:08:46 -0000 Delivered-To: apmail-hbase-user-archive@hbase.apache.org Received: (qmail 33114 invoked by uid 500); 10 Oct 2012 19:08:46 -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 33101 invoked by uid 99); 10 Oct 2012 19:08:46 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 10 Oct 2012 19:08: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 chilinglam@gmail.com designates 209.85.217.169 as permitted sender) Received: from [209.85.217.169] (HELO mail-lb0-f169.google.com) (209.85.217.169) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 10 Oct 2012 19:08:39 +0000 Received: by mail-lb0-f169.google.com with SMTP id k6so812751lbo.14 for ; Wed, 10 Oct 2012 12:08:18 -0700 (PDT) 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=/7tizYd3ZqYMv/rPYAyD1HMFFMDiFZ3zVPEbbzjBdQA=; b=xnVl2sJosy45lMMmRknd0+l589KWXXiQoCtUg2bF16vD9+mlTfIzG+TcT6lpCEV1IB 2RigYVjQOXqcb3ltREEgwI6jZsWRB5wLf+/R5LfQ8acbe+4B4zSwrZ4ODxsjLM//I4i4 0DoH0FyIw/dSq4E6zBr0obsXO5z+nQCXabo07YTj6qcdRYlqIia8cliUIiFe+7w+sQFA ojBsdMBiBDMLyNhoyAwdlHCLpw2wU+yIbqJcxSiY0ddDzV1ZAwLhQzK/el2XowcUyHJh 5vb/arL36zsqp7kacG9AAC1AUgi6PeNbABSocpXvpwMsux+Snyp1KSt9Zs7EOqmvyThz SasA== MIME-Version: 1.0 Received: by 10.152.124.83 with SMTP id mg19mr21136318lab.6.1349896098703; Wed, 10 Oct 2012 12:08:18 -0700 (PDT) Received: by 10.114.62.15 with HTTP; Wed, 10 Oct 2012 12:08:18 -0700 (PDT) In-Reply-To: References: Date: Wed, 10 Oct 2012 15:08:18 -0400 Message-ID: Subject: Re: key design From: Jerry Lam To: user@hbase.apache.org Content-Type: multipart/alternative; boundary=f46d042dfc957268e004cbb92d94 --f46d042dfc957268e004cbb92d94 Content-Type: text/plain; charset=ISO-8859-1 That's true.Then there would be max. 86,400 records per day per userid. That is about 100MB per day. I don't see much difference in both approaches from the storage perspective. On Wed, Oct 10, 2012 at 1:09 PM, Doug Meil wrote: > Hi there- > > Given the fact that the userid is in the lead position of the key in both > approaches, I'm not sure that he'd have a region hotspotting problem > because the userid should be able to offer some spread. > > > > > On 10/10/12 12:55 PM, "Jerry Lam" wrote: > > >Hi: > > > >So you are saying you have ~3TB of data stored per day? > > > >Using the second approach, all data for one day will go to only 1 > >regionserver no matter what you do because HBase doesn't split a single > >row. > > > >Using the first approach, data will spread across regionservers but there > >will be hotspotted to each regionserver during write since this is a > >time-series problem. > > > >Best Regards, > > > >Jerry > > > >On Wed, Oct 10, 2012 at 11:24 AM, yutoo yanio > >wrote: > > > >> hi > >> i have a question about key & column design. > >> in my application we have 3,000,000,000 record in every day > >> each record contain : user-id, "time stamp", content(max 1KB). > >> we need to store records for one year, this means we will have about > >> 1,000,000,000,000 after 1 year. > >> we just search a user-id over rang of "time stamp" > >> table can design in two way > >> 1.key=userid-timestamp and column:=content > >> 2.key=userid-yyyyMMdd and column:HHmmss=content > >> > >> > >> in first design we have tall-narrow table but we have very very > >>records, in > >> second design we have flat-wide table. > >> which of them have better performance? > >> > >> thanks. > >> > > > --f46d042dfc957268e004cbb92d94--