Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 4F8D3200BBE for ; Fri, 28 Oct 2016 07:47:00 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 4E4B0160B01; Fri, 28 Oct 2016 05:47:00 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 940B7160AF6 for ; Fri, 28 Oct 2016 07:46:59 +0200 (CEST) Received: (qmail 71979 invoked by uid 500); 28 Oct 2016 05:46:58 -0000 Mailing-List: contact issues-help@hbase.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list issues@hbase.apache.org Received: (qmail 71957 invoked by uid 99); 28 Oct 2016 05:46:58 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 28 Oct 2016 05:46:58 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 7F83C2C014E for ; Fri, 28 Oct 2016 05:46:58 +0000 (UTC) Date: Fri, 28 Oct 2016 05:46:58 +0000 (UTC) From: "ramkrishna.s.vasudevan (JIRA)" To: issues@hbase.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (HBASE-16747) Track memstore data size and heap overhead separately MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Fri, 28 Oct 2016 05:47:00 -0000 [ https://issues.apache.org/jira/browse/HBASE-16747?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15614388#comment-15614388 ] ramkrishna.s.vasudevan commented on HBASE-16747: ------------------------------------------------ +1. Great patch. > Track memstore data size and heap overhead separately > ------------------------------------------------------ > > Key: HBASE-16747 > URL: https://issues.apache.org/jira/browse/HBASE-16747 > Project: HBase > Issue Type: Sub-task > Components: regionserver > Reporter: Anoop Sam John > Assignee: Anoop Sam John > Fix For: 2.0.0 > > Attachments: HBASE-16747.patch, HBASE-16747.patch, HBASE-16747_V2.patch, HBASE-16747_V2.patch, HBASE-16747_V3.patch, HBASE-16747_V3.patch, HBASE-16747_V3.patch, HBASE-16747_V4.patch, HBASE-16747_WIP.patch > > > We track the memstore size in 3 places. > 1. Global at RS level in RegionServerAccounting. This tracks all memstore's size and used to calculate whether forced flushes needed because of global heap pressure > 2. At region level in HRegion. This is sum of sizes of all memstores within this region. This is used to decide whether region reaches flush size (128 MB) > 3. Segment level. This tracks the in memory flush/compaction decisions. > All these use the Cell's heap size which include the data bytes# as well as Cell object heap overhead. Also we include the overhead because of addition of Cells into Segment's data structures (Like CSLM). > Once we have off heap memstore, we will keep the cell data bytes in off heap area. So we can not track both data size and heap overhead as one entity. We need to separate them and track. > Proposal here is to track both cell data size and heap overhead separately at global accounting layer. As of now we have only on heap memstore. So the global memstore boundary checks will consider both (adds up and check against global max memstore size) > Track cell data size alone (This can be on heap or off heap) in region level. Region flushes use cell data size alone for the region flush decision. A user configuring 128 MB as flush size, normally he will expect to get a 128MB data flush size. But as we were including the heap overhead also, once the flush happens, the actual data size getting flushed is way behind this 128 MB. Now with this change we will behave more like what a user thinks. > Segment level in memory flush/compaction also considers cell data size alone. But we will need to track the heap overhead also. (Once the in memory flush or normal flush happens, we will have to adjust both cell data size and heap overhead) -- This message was sent by Atlassian JIRA (v6.3.4#6332)