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 E31BE200CF2 for ; Sat, 2 Sep 2017 08:52:13 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id D85A816D18D; Sat, 2 Sep 2017 06:52:13 +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 28B7916D18C for ; Sat, 2 Sep 2017 08:52:13 +0200 (CEST) Received: (qmail 49113 invoked by uid 500); 2 Sep 2017 06:52:12 -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 49102 invoked by uid 99); 2 Sep 2017 06:52:11 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 02 Sep 2017 06:52:11 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 6DE4AD1AC3 for ; Sat, 2 Sep 2017 06:52:11 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -99.202 X-Spam-Level: X-Spam-Status: No, score=-99.202 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id C_hSskV56WDr for ; Sat, 2 Sep 2017 06:52:06 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTP id B074B5F121 for ; Sat, 2 Sep 2017 06:52:06 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 62224E0044 for ; Sat, 2 Sep 2017 06:52:04 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id F2E1B23F0D for ; Sat, 2 Sep 2017 06:52:02 +0000 (UTC) Date: Sat, 2 Sep 2017 06:52:00 +0000 (UTC) From: "Chia-Ping Tsai (JIRA)" To: issues@hbase.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (HBASE-18742) Make cache configuration like global switch MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Sat, 02 Sep 2017 06:52:14 -0000 [ https://issues.apache.org/jira/browse/HBASE-18742?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16151426#comment-16151426 ] Chia-Ping Tsai commented on HBASE-18742: ---------------------------------------- The different conditions(||, &&) serves for different purposes....We should unity them. > Make cache configuration like global switch > ------------------------------------------- > > Key: HBASE-18742 > URL: https://issues.apache.org/jira/browse/HBASE-18742 > Project: HBase > Issue Type: New Feature > Reporter: Chia-Ping Tsai > Assignee: Chia-Ping Tsai > > I'm profiling phoenix query w/wo hbase cache. And then i noticed the following codes in CacheConfig. > {code} > this(CacheConfig.instantiateBlockCache(conf), > conf.getBoolean(CACHE_DATA_ON_READ_KEY, DEFAULT_CACHE_DATA_ON_READ) > && family.isBlockCacheEnabled(), > family.isInMemory(), > // For the following flags we enable them regardless of per-schema settings > // if they are enabled in the global configuration. > conf.getBoolean(CACHE_BLOCKS_ON_WRITE_KEY, > DEFAULT_CACHE_DATA_ON_WRITE) || family.isCacheDataOnWrite(), > conf.getBoolean(CACHE_INDEX_BLOCKS_ON_WRITE_KEY, > DEFAULT_CACHE_INDEXES_ON_WRITE) || family.isCacheIndexesOnWrite(), > conf.getBoolean(CACHE_BLOOM_BLOCKS_ON_WRITE_KEY, > DEFAULT_CACHE_BLOOMS_ON_WRITE) || family.isCacheBloomsOnWrite(), > conf.getBoolean(EVICT_BLOCKS_ON_CLOSE_KEY, > DEFAULT_EVICT_ON_CLOSE) || family.isEvictBlocksOnClose(), > conf.getBoolean(CACHE_DATA_BLOCKS_COMPRESSED_KEY, DEFAULT_CACHE_DATA_COMPRESSED), > conf.getBoolean(PREFETCH_BLOCKS_ON_OPEN_KEY, > DEFAULT_PREFETCH_ON_OPEN) || family.isPrefetchBlocksOnOpen(), > conf.getBoolean(ColumnFamilyDescriptorBuilder.CACHE_DATA_IN_L1, > ColumnFamilyDescriptorBuilder.DEFAULT_CACHE_DATA_IN_L1) || family.isCacheDataInL1(), > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY, DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > {code} > The global configuration for cache do NOT look like global switch. The codes should be like this. > {code} > config.get(xxx, family.isxxx) > {code} > The cf level config should honor the global config. -- This message was sent by Atlassian JIRA (v6.4.14#64029)