[jira] [Commented] (HBASE-14189) CF Level BC setting should override global one.
[ https://issues.apache.org/jira/browse/HBASE-14189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15354869#comment-15354869 ] Heng Chen commented on HBASE-14189: --- Consider the issue hang so long time. There is no need to merge the patch. Let me resolve it. > CF Level BC setting should override global one. > --- > > Key: HBASE-14189 > URL: https://issues.apache.org/jira/browse/HBASE-14189 > Project: HBase > Issue Type: Improvement > Components: BlockCache >Affects Versions: 2.0.0 >Reporter: Heng Chen >Assignee: Heng Chen > Attachments: HBASE-14189.patch, HBASE-14189_v1.patch, > HBASE-14189_v2.patch, HBASE-14189_v3.patch, HBASE-14189_v4.patch, > HBASE-14189_v5.patch, HBASE-14189_v6.patch, HBASE-14189_v7.patch > > > The original description is ambiguous. I think i will rewrite it. > Let's see {{BlockCache}} constructor firstly > {code} > public CacheConfig(Configuration conf, HColumnDescriptor family) { > this(CacheConfig.instantiateBlockCache(conf), > 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(HColumnDescriptor.CACHE_DATA_IN_L1, > HColumnDescriptor.DEFAULT_CACHE_DATA_IN_L1) || > family.isCacheDataInL1(), > > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY,DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > } > {code} > If we dig in it, we will see {{CacheConfig.cacheDataOnRead}} is used to > accept {{family.isBlockCacheEnabled()}}. > I think it is confused as comments about {{cacheDataOnRead}} > {code} > /** >* Whether blocks should be cached on read (default is on if there is a >* cache but this can be turned off on a per-family or per-request basis). >* If off we will STILL cache meta blocks; i.e. INDEX and BLOOM types. >* This cannot be disabled. >*/ > private boolean cacheDataOnRead; > {code} > So i think we should use another variable to represent for > {{family.isBlockCacheEnabled()}}. > The secondary point is we use 'or' to decide {{cacheDataOnWrite}} is on/off > when both CF and global has this setting. > {code} > conf.getBoolean(CACHE_BLOCKS_ON_WRITE_KEY, > DEFAULT_CACHE_DATA_ON_WRITE) || family.isCacheDataOnWrite() > {code} > IMO we should use CF Level setting to override global setting. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (HBASE-14189) CF Level BC setting should override global one.
[ https://issues.apache.org/jira/browse/HBASE-14189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15067864#comment-15067864 ] Anoop Sam John commented on HBASE-14189: bq.getOption(boolean globalSetting, Boolean cfSetting) This is good... HCD is public exposed and we are changing the return type of some methods. Target version is 2.0 only. cc [~mbertozzi] wdyt? > CF Level BC setting should override global one. > --- > > Key: HBASE-14189 > URL: https://issues.apache.org/jira/browse/HBASE-14189 > Project: HBase > Issue Type: Improvement > Components: BlockCache >Affects Versions: 2.0.0 >Reporter: Heng Chen >Assignee: Heng Chen > Attachments: HBASE-14189.patch, HBASE-14189_v1.patch, > HBASE-14189_v2.patch, HBASE-14189_v3.patch, HBASE-14189_v4.patch, > HBASE-14189_v5.patch, HBASE-14189_v6.patch, HBASE-14189_v7.patch > > > The original description is ambiguous. I think i will rewrite it. > Let's see {{BlockCache}} constructor firstly > {code} > public CacheConfig(Configuration conf, HColumnDescriptor family) { > this(CacheConfig.instantiateBlockCache(conf), > 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(HColumnDescriptor.CACHE_DATA_IN_L1, > HColumnDescriptor.DEFAULT_CACHE_DATA_IN_L1) || > family.isCacheDataInL1(), > > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY,DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > } > {code} > If we dig in it, we will see {{CacheConfig.cacheDataOnRead}} is used to > accept {{family.isBlockCacheEnabled()}}. > I think it is confused as comments about {{cacheDataOnRead}} > {code} > /** >* Whether blocks should be cached on read (default is on if there is a >* cache but this can be turned off on a per-family or per-request basis). >* If off we will STILL cache meta blocks; i.e. INDEX and BLOOM types. >* This cannot be disabled. >*/ > private boolean cacheDataOnRead; > {code} > So i think we should use another variable to represent for > {{family.isBlockCacheEnabled()}}. > The secondary point is we use 'or' to decide {{cacheDataOnWrite}} is on/off > when both CF and global has this setting. > {code} > conf.getBoolean(CACHE_BLOCKS_ON_WRITE_KEY, > DEFAULT_CACHE_DATA_ON_WRITE) || family.isCacheDataOnWrite() > {code} > IMO we should use CF Level setting to override global setting. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (HBASE-14189) CF Level BC setting should override global one.
[ https://issues.apache.org/jira/browse/HBASE-14189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15066450#comment-15066450 ] Hadoop QA commented on HBASE-14189: --- {color:red}-1 overall{color}. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12778808/HBASE-14189_v7.patch against master branch at commit e75e26e3c6cfe7fd378081839d60fc711c1e095f. ATTACHMENT ID: 12778808 {color:green}+1 @author{color}. The patch does not contain any @author tags. {color:green}+1 tests included{color}. The patch appears to include 12 new or modified tests. {color:green}+1 hadoop versions{color}. The patch compiles with all supported hadoop versions (2.4.0 2.4.1 2.5.0 2.5.1 2.5.2 2.6.0 2.6.1 2.7.0 2.7.1) {color:green}+1 javac{color}. The applied patch does not increase the total number of javac compiler warnings. {color:green}+1 protoc{color}. The applied patch does not increase the total number of protoc compiler warnings. {color:green}+1 javadoc{color}. The javadoc tool did not generate any warning messages. {color:red}-1 checkstyle{color}. The applied patch generated new checkstyle errors. Check build console for list of new errors. {color:green}+1 findbugs{color}. The patch does not introduce any new Findbugs (version 2.0.3) warnings. {color:green}+1 release audit{color}. The applied patch does not increase the total number of release audit warnings. {color:green}+1 lineLengths{color}. The patch does not introduce lines longer than 100 {color:green}+1 site{color}. The mvn post-site goal succeeds with this patch. {color:green}+1 core tests{color}. The patch passed unit tests in . {color:green}+1 zombies{color}. No zombie tests found running at the end of the build. Test results: https://builds.apache.org/job/PreCommit-HBASE-Build/16949//testReport/ Release Findbugs (version 2.0.3)warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/16949//artifact/patchprocess/newFindbugsWarnings.html Checkstyle Errors: https://builds.apache.org/job/PreCommit-HBASE-Build/16949//artifact/patchprocess/checkstyle-aggregate.html Console output: https://builds.apache.org/job/PreCommit-HBASE-Build/16949//console This message is automatically generated. > CF Level BC setting should override global one. > --- > > Key: HBASE-14189 > URL: https://issues.apache.org/jira/browse/HBASE-14189 > Project: HBase > Issue Type: Improvement > Components: BlockCache >Affects Versions: 2.0.0 >Reporter: Heng Chen >Assignee: Heng Chen > Attachments: HBASE-14189.patch, HBASE-14189_v1.patch, > HBASE-14189_v2.patch, HBASE-14189_v3.patch, HBASE-14189_v4.patch, > HBASE-14189_v5.patch, HBASE-14189_v6.patch, HBASE-14189_v7.patch > > > The original description is ambiguous. I think i will rewrite it. > Let's see {{BlockCache}} constructor firstly > {code} > public CacheConfig(Configuration conf, HColumnDescriptor family) { > this(CacheConfig.instantiateBlockCache(conf), > 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(HColumnDescriptor.CACHE_DATA_IN_L1, > HColumnDescriptor.DEFAULT_CACHE_DATA_IN_L1) || > family.isCacheDataInL1(), > > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY,DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > } > {code} > If we dig in it, we will see {{CacheConfig.cacheDataOnRead}} is used to > accept {{family.isBlockCacheEnabled()}}. > I think it is confused as comments about {{cacheDataOnRead}} > {code} > /** >* Whether blocks should be cached on read (default is on if there is a >* cache but this can be turned off on a per-family or per-request basis). >* If off we will STILL cache meta blocks; i.e. INDEX and BLOOM types. >* This cannot be disabled. >
[jira] [Commented] (HBASE-14189) CF Level BC setting should override global one.
[ https://issues.apache.org/jira/browse/HBASE-14189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15066181#comment-15066181 ] Anoop Sam John commented on HBASE-14189: We need a rebase I guess.. bq.family.isCacheDataOnRead() Not seeing isCacheDataOnRead() in HCD now. > CF Level BC setting should override global one. > --- > > Key: HBASE-14189 > URL: https://issues.apache.org/jira/browse/HBASE-14189 > Project: HBase > Issue Type: Improvement > Components: BlockCache >Affects Versions: 2.0.0 >Reporter: Heng Chen >Assignee: Heng Chen > Attachments: HBASE-14189.patch, HBASE-14189_v1.patch, > HBASE-14189_v2.patch, HBASE-14189_v3.patch, HBASE-14189_v4.patch, > HBASE-14189_v5.patch, HBASE-14189_v6.patch > > > The original description is ambiguous. I think i will rewrite it. > Let's see {{BlockCache}} constructor firstly > {code} > public CacheConfig(Configuration conf, HColumnDescriptor family) { > this(CacheConfig.instantiateBlockCache(conf), > 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(HColumnDescriptor.CACHE_DATA_IN_L1, > HColumnDescriptor.DEFAULT_CACHE_DATA_IN_L1) || > family.isCacheDataInL1(), > > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY,DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > } > {code} > If we dig in it, we will see {{CacheConfig.cacheDataOnRead}} is used to > accept {{family.isBlockCacheEnabled()}}. > I think it is confused as comments about {{cacheDataOnRead}} > {code} > /** >* Whether blocks should be cached on read (default is on if there is a >* cache but this can be turned off on a per-family or per-request basis). >* If off we will STILL cache meta blocks; i.e. INDEX and BLOOM types. >* This cannot be disabled. >*/ > private boolean cacheDataOnRead; > {code} > So i think we should use another variable to represent for > {{family.isBlockCacheEnabled()}}. > The secondary point is we use 'or' to decide {{cacheDataOnWrite}} is on/off > when both CF and global has this setting. > {code} > conf.getBoolean(CACHE_BLOCKS_ON_WRITE_KEY, > DEFAULT_CACHE_DATA_ON_WRITE) || family.isCacheDataOnWrite() > {code} > IMO we should use CF Level setting to override global setting. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (HBASE-14189) CF Level BC setting should override global one.
[ https://issues.apache.org/jira/browse/HBASE-14189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15066296#comment-15066296 ] Heng Chen commented on HBASE-14189: --- {quote} Not seeing isCacheDataOnRead() in HCD now. {quote} Yeah, the two methods below were added in this patch {code} + public HColumnDescriptor setCacheDataOnRead(boolean value) { +return setValue(CACHE_DATA_ON_READ, Boolean.toString(value)); + } + + public HColumnDescriptor setCacheDataBlockCompressed(boolean value) { +return setValue(CACHE_DATA_BLOCKS_COMPRESSED, Boolean.toString(value)); + } {code} I will rebase the patch, and submit a new one (it seems there is no conflicts but i still do it) > CF Level BC setting should override global one. > --- > > Key: HBASE-14189 > URL: https://issues.apache.org/jira/browse/HBASE-14189 > Project: HBase > Issue Type: Improvement > Components: BlockCache >Affects Versions: 2.0.0 >Reporter: Heng Chen >Assignee: Heng Chen > Attachments: HBASE-14189.patch, HBASE-14189_v1.patch, > HBASE-14189_v2.patch, HBASE-14189_v3.patch, HBASE-14189_v4.patch, > HBASE-14189_v5.patch, HBASE-14189_v6.patch > > > The original description is ambiguous. I think i will rewrite it. > Let's see {{BlockCache}} constructor firstly > {code} > public CacheConfig(Configuration conf, HColumnDescriptor family) { > this(CacheConfig.instantiateBlockCache(conf), > 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(HColumnDescriptor.CACHE_DATA_IN_L1, > HColumnDescriptor.DEFAULT_CACHE_DATA_IN_L1) || > family.isCacheDataInL1(), > > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY,DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > } > {code} > If we dig in it, we will see {{CacheConfig.cacheDataOnRead}} is used to > accept {{family.isBlockCacheEnabled()}}. > I think it is confused as comments about {{cacheDataOnRead}} > {code} > /** >* Whether blocks should be cached on read (default is on if there is a >* cache but this can be turned off on a per-family or per-request basis). >* If off we will STILL cache meta blocks; i.e. INDEX and BLOOM types. >* This cannot be disabled. >*/ > private boolean cacheDataOnRead; > {code} > So i think we should use another variable to represent for > {{family.isBlockCacheEnabled()}}. > The secondary point is we use 'or' to decide {{cacheDataOnWrite}} is on/off > when both CF and global has this setting. > {code} > conf.getBoolean(CACHE_BLOCKS_ON_WRITE_KEY, > DEFAULT_CACHE_DATA_ON_WRITE) || family.isCacheDataOnWrite() > {code} > IMO we should use CF Level setting to override global setting. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (HBASE-14189) CF Level BC setting should override global one.
[ https://issues.apache.org/jira/browse/HBASE-14189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15066127#comment-15066127 ] Heng Chen commented on HBASE-14189: --- [~anoop.hbase] Let's finish this issue, wdyt? :) > CF Level BC setting should override global one. > --- > > Key: HBASE-14189 > URL: https://issues.apache.org/jira/browse/HBASE-14189 > Project: HBase > Issue Type: Improvement > Components: BlockCache >Affects Versions: 2.0.0 >Reporter: Heng Chen >Assignee: Heng Chen > Attachments: HBASE-14189.patch, HBASE-14189_v1.patch, > HBASE-14189_v2.patch, HBASE-14189_v3.patch, HBASE-14189_v4.patch, > HBASE-14189_v5.patch, HBASE-14189_v6.patch > > > The original description is ambiguous. I think i will rewrite it. > Let's see {{BlockCache}} constructor firstly > {code} > public CacheConfig(Configuration conf, HColumnDescriptor family) { > this(CacheConfig.instantiateBlockCache(conf), > 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(HColumnDescriptor.CACHE_DATA_IN_L1, > HColumnDescriptor.DEFAULT_CACHE_DATA_IN_L1) || > family.isCacheDataInL1(), > > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY,DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > } > {code} > If we dig in it, we will see {{CacheConfig.cacheDataOnRead}} is used to > accept {{family.isBlockCacheEnabled()}}. > I think it is confused as comments about {{cacheDataOnRead}} > {code} > /** >* Whether blocks should be cached on read (default is on if there is a >* cache but this can be turned off on a per-family or per-request basis). >* If off we will STILL cache meta blocks; i.e. INDEX and BLOOM types. >* This cannot be disabled. >*/ > private boolean cacheDataOnRead; > {code} > So i think we should use another variable to represent for > {{family.isBlockCacheEnabled()}}. > The secondary point is we use 'or' to decide {{cacheDataOnWrite}} is on/off > when both CF and global has this setting. > {code} > conf.getBoolean(CACHE_BLOCKS_ON_WRITE_KEY, > DEFAULT_CACHE_DATA_ON_WRITE) || family.isCacheDataOnWrite() > {code} > IMO we should use CF Level setting to override global setting. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (HBASE-14189) CF Level BC setting should override global one.
[ https://issues.apache.org/jira/browse/HBASE-14189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15066145#comment-15066145 ] Anoop Sam John commented on HBASE-14189: Sorry for the delay.. I did not receive mail from Jira when name was referred !! Let me look at the last patch. > CF Level BC setting should override global one. > --- > > Key: HBASE-14189 > URL: https://issues.apache.org/jira/browse/HBASE-14189 > Project: HBase > Issue Type: Improvement > Components: BlockCache >Affects Versions: 2.0.0 >Reporter: Heng Chen >Assignee: Heng Chen > Attachments: HBASE-14189.patch, HBASE-14189_v1.patch, > HBASE-14189_v2.patch, HBASE-14189_v3.patch, HBASE-14189_v4.patch, > HBASE-14189_v5.patch, HBASE-14189_v6.patch > > > The original description is ambiguous. I think i will rewrite it. > Let's see {{BlockCache}} constructor firstly > {code} > public CacheConfig(Configuration conf, HColumnDescriptor family) { > this(CacheConfig.instantiateBlockCache(conf), > 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(HColumnDescriptor.CACHE_DATA_IN_L1, > HColumnDescriptor.DEFAULT_CACHE_DATA_IN_L1) || > family.isCacheDataInL1(), > > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY,DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > } > {code} > If we dig in it, we will see {{CacheConfig.cacheDataOnRead}} is used to > accept {{family.isBlockCacheEnabled()}}. > I think it is confused as comments about {{cacheDataOnRead}} > {code} > /** >* Whether blocks should be cached on read (default is on if there is a >* cache but this can be turned off on a per-family or per-request basis). >* If off we will STILL cache meta blocks; i.e. INDEX and BLOOM types. >* This cannot be disabled. >*/ > private boolean cacheDataOnRead; > {code} > So i think we should use another variable to represent for > {{family.isBlockCacheEnabled()}}. > The secondary point is we use 'or' to decide {{cacheDataOnWrite}} is on/off > when both CF and global has this setting. > {code} > conf.getBoolean(CACHE_BLOCKS_ON_WRITE_KEY, > DEFAULT_CACHE_DATA_ON_WRITE) || family.isCacheDataOnWrite() > {code} > IMO we should use CF Level setting to override global setting. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (HBASE-14189) CF Level BC setting should override global one.
[ https://issues.apache.org/jira/browse/HBASE-14189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15021852#comment-15021852 ] Heng Chen commented on HBASE-14189: --- ping [~anoop.hbase] :) > CF Level BC setting should override global one. > --- > > Key: HBASE-14189 > URL: https://issues.apache.org/jira/browse/HBASE-14189 > Project: HBase > Issue Type: Improvement > Components: BlockCache >Affects Versions: 2.0.0 >Reporter: Heng Chen >Assignee: Heng Chen > Attachments: HBASE-14189.patch, HBASE-14189_v1.patch, > HBASE-14189_v2.patch, HBASE-14189_v3.patch, HBASE-14189_v4.patch, > HBASE-14189_v5.patch, HBASE-14189_v6.patch > > > The original description is ambiguous. I think i will rewrite it. > Let's see {{BlockCache}} constructor firstly > {code} > public CacheConfig(Configuration conf, HColumnDescriptor family) { > this(CacheConfig.instantiateBlockCache(conf), > 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(HColumnDescriptor.CACHE_DATA_IN_L1, > HColumnDescriptor.DEFAULT_CACHE_DATA_IN_L1) || > family.isCacheDataInL1(), > > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY,DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > } > {code} > If we dig in it, we will see {{CacheConfig.cacheDataOnRead}} is used to > accept {{family.isBlockCacheEnabled()}}. > I think it is confused as comments about {{cacheDataOnRead}} > {code} > /** >* Whether blocks should be cached on read (default is on if there is a >* cache but this can be turned off on a per-family or per-request basis). >* If off we will STILL cache meta blocks; i.e. INDEX and BLOOM types. >* This cannot be disabled. >*/ > private boolean cacheDataOnRead; > {code} > So i think we should use another variable to represent for > {{family.isBlockCacheEnabled()}}. > The secondary point is we use 'or' to decide {{cacheDataOnWrite}} is on/off > when both CF and global has this setting. > {code} > conf.getBoolean(CACHE_BLOCKS_ON_WRITE_KEY, > DEFAULT_CACHE_DATA_ON_WRITE) || family.isCacheDataOnWrite() > {code} > IMO we should use CF Level setting to override global setting. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (HBASE-14189) CF Level BC setting should override global one.
[ https://issues.apache.org/jira/browse/HBASE-14189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15002053#comment-15002053 ] Hadoop QA commented on HBASE-14189: --- {color:green}+1 overall{color}. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12771945/HBASE-14189_v6.patch against master branch at commit 1f62a487284b57fca505bc1b3d04c1f86b2e7d76. ATTACHMENT ID: 12771945 {color:green}+1 @author{color}. The patch does not contain any @author tags. {color:green}+1 tests included{color}. The patch appears to include 12 new or modified tests. {color:green}+1 hadoop versions{color}. The patch compiles with all supported hadoop versions (2.4.0 2.4.1 2.5.0 2.5.1 2.5.2 2.6.0 2.6.1 2.7.0 2.7.1) {color:green}+1 javac{color}. The applied patch does not increase the total number of javac compiler warnings. {color:green}+1 protoc{color}. The applied patch does not increase the total number of protoc compiler warnings. {color:green}+1 javadoc{color}. The javadoc tool did not generate any warning messages. {color:green}+1 checkstyle{color}. The applied patch does not increase the total number of checkstyle errors {color:green}+1 findbugs{color}. The patch does not introduce any new Findbugs (version 2.0.3) warnings. {color:green}+1 release audit{color}. The applied patch does not increase the total number of release audit warnings. {color:green}+1 lineLengths{color}. The patch does not introduce lines longer than 100 {color:green}+1 site{color}. The mvn post-site goal succeeds with this patch. {color:green}+1 core tests{color}. The patch passed unit tests in . Test results: https://builds.apache.org/job/PreCommit-HBASE-Build/16498//testReport/ Release Findbugs (version 2.0.3)warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/16498//artifact/patchprocess/newFindbugsWarnings.html Checkstyle Errors: https://builds.apache.org/job/PreCommit-HBASE-Build/16498//artifact/patchprocess/checkstyle-aggregate.html Console output: https://builds.apache.org/job/PreCommit-HBASE-Build/16498//console This message is automatically generated. > CF Level BC setting should override global one. > --- > > Key: HBASE-14189 > URL: https://issues.apache.org/jira/browse/HBASE-14189 > Project: HBase > Issue Type: Improvement > Components: BlockCache >Affects Versions: 2.0.0 >Reporter: Heng Chen >Assignee: Heng Chen > Attachments: HBASE-14189.patch, HBASE-14189_v1.patch, > HBASE-14189_v2.patch, HBASE-14189_v3.patch, HBASE-14189_v4.patch, > HBASE-14189_v5.patch, HBASE-14189_v6.patch > > > The original description is ambiguous. I think i will rewrite it. > Let's see {{BlockCache}} constructor firstly > {code} > public CacheConfig(Configuration conf, HColumnDescriptor family) { > this(CacheConfig.instantiateBlockCache(conf), > 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(HColumnDescriptor.CACHE_DATA_IN_L1, > HColumnDescriptor.DEFAULT_CACHE_DATA_IN_L1) || > family.isCacheDataInL1(), > > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY,DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > } > {code} > If we dig in it, we will see {{CacheConfig.cacheDataOnRead}} is used to > accept {{family.isBlockCacheEnabled()}}. > I think it is confused as comments about {{cacheDataOnRead}} > {code} > /** >* Whether blocks should be cached on read (default is on if there is a >* cache but this can be turned off on a per-family or per-request basis). >* If off we will STILL cache meta blocks; i.e. INDEX and BLOOM types. >* This cannot be disabled. >*/ > private boolean cacheDataOnRead; > {code} > So i think we should use another variable to represent for > {{family.isBlockCacheEnabled()}}. > The
[jira] [Commented] (HBASE-14189) CF Level BC setting should override global one.
[ https://issues.apache.org/jira/browse/HBASE-14189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15000524#comment-15000524 ] Anoop Sam John commented on HBASE-14189: A change of boolean type to Boolean will do the work of new Enum no? When on the table or CF the setting is no set, we can avoid serialize that attribute into HCD? > CF Level BC setting should override global one. > --- > > Key: HBASE-14189 > URL: https://issues.apache.org/jira/browse/HBASE-14189 > Project: HBase > Issue Type: Improvement > Components: BlockCache >Affects Versions: 2.0.0 >Reporter: Heng Chen >Assignee: Heng Chen > Attachments: HBASE-14189.patch, HBASE-14189_v1.patch, > HBASE-14189_v2.patch, HBASE-14189_v3.patch, HBASE-14189_v4.patch, > HBASE-14189_v5.patch > > > The original description is ambiguous. I think i will rewrite it. > Let's see {{BlockCache}} constructor firstly > {code} > public CacheConfig(Configuration conf, HColumnDescriptor family) { > this(CacheConfig.instantiateBlockCache(conf), > 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(HColumnDescriptor.CACHE_DATA_IN_L1, > HColumnDescriptor.DEFAULT_CACHE_DATA_IN_L1) || > family.isCacheDataInL1(), > > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY,DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > } > {code} > If we dig in it, we will see {{CacheConfig.cacheDataOnRead}} is used to > accept {{family.isBlockCacheEnabled()}}. > I think it is confused as comments about {{cacheDataOnRead}} > {code} > /** >* Whether blocks should be cached on read (default is on if there is a >* cache but this can be turned off on a per-family or per-request basis). >* If off we will STILL cache meta blocks; i.e. INDEX and BLOOM types. >* This cannot be disabled. >*/ > private boolean cacheDataOnRead; > {code} > So i think we should use another variable to represent for > {{family.isBlockCacheEnabled()}}. > The secondary point is we use 'or' to decide {{cacheDataOnWrite}} is on/off > when both CF and global has this setting. > {code} > conf.getBoolean(CACHE_BLOCKS_ON_WRITE_KEY, > DEFAULT_CACHE_DATA_ON_WRITE) || family.isCacheDataOnWrite() > {code} > IMO we should use CF Level setting to override global setting. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (HBASE-14189) CF Level BC setting should override global one.
[ https://issues.apache.org/jira/browse/HBASE-14189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15001597#comment-15001597 ] Heng Chen commented on HBASE-14189: --- {quote} A change of boolean type to Boolean will do the work of new Enum no? When on the table or CF the setting is no set, we can avoid serialize that attribute into HCD? {quote} Sounds good! I will do it > CF Level BC setting should override global one. > --- > > Key: HBASE-14189 > URL: https://issues.apache.org/jira/browse/HBASE-14189 > Project: HBase > Issue Type: Improvement > Components: BlockCache >Affects Versions: 2.0.0 >Reporter: Heng Chen >Assignee: Heng Chen > Attachments: HBASE-14189.patch, HBASE-14189_v1.patch, > HBASE-14189_v2.patch, HBASE-14189_v3.patch, HBASE-14189_v4.patch, > HBASE-14189_v5.patch > > > The original description is ambiguous. I think i will rewrite it. > Let's see {{BlockCache}} constructor firstly > {code} > public CacheConfig(Configuration conf, HColumnDescriptor family) { > this(CacheConfig.instantiateBlockCache(conf), > 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(HColumnDescriptor.CACHE_DATA_IN_L1, > HColumnDescriptor.DEFAULT_CACHE_DATA_IN_L1) || > family.isCacheDataInL1(), > > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY,DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > } > {code} > If we dig in it, we will see {{CacheConfig.cacheDataOnRead}} is used to > accept {{family.isBlockCacheEnabled()}}. > I think it is confused as comments about {{cacheDataOnRead}} > {code} > /** >* Whether blocks should be cached on read (default is on if there is a >* cache but this can be turned off on a per-family or per-request basis). >* If off we will STILL cache meta blocks; i.e. INDEX and BLOOM types. >* This cannot be disabled. >*/ > private boolean cacheDataOnRead; > {code} > So i think we should use another variable to represent for > {{family.isBlockCacheEnabled()}}. > The secondary point is we use 'or' to decide {{cacheDataOnWrite}} is on/off > when both CF and global has this setting. > {code} > conf.getBoolean(CACHE_BLOCKS_ON_WRITE_KEY, > DEFAULT_CACHE_DATA_ON_WRITE) || family.isCacheDataOnWrite() > {code} > IMO we should use CF Level setting to override global setting. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (HBASE-14189) CF Level BC setting should override global one.
[ https://issues.apache.org/jira/browse/HBASE-14189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14996442#comment-14996442 ] Hadoop QA commented on HBASE-14189: --- {color:red}-1 overall{color}. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12771319/HBASE-14189_v5.patch against master branch at commit 4c2e0d95dc62ee42b3da820d751a11eb52ce0069. ATTACHMENT ID: 12771319 {color:green}+1 @author{color}. The patch does not contain any @author tags. {color:green}+1 tests included{color}. The patch appears to include 12 new or modified tests. {color:green}+1 hadoop versions{color}. The patch compiles with all supported hadoop versions (2.4.0 2.4.1 2.5.0 2.5.1 2.5.2 2.6.0 2.6.1 2.7.0 2.7.1) {color:green}+1 javac{color}. The applied patch does not increase the total number of javac compiler warnings. {color:green}+1 protoc{color}. The applied patch does not increase the total number of protoc compiler warnings. {color:green}+1 javadoc{color}. The javadoc tool did not generate any warning messages. {color:red}-1 checkstyle{color}. The applied patch generated 1727 checkstyle errors (more than the master's current 1726 errors). {color:green}+1 findbugs{color}. The patch does not introduce any new Findbugs (version 2.0.3) warnings. {color:green}+1 release audit{color}. The applied patch does not increase the total number of release audit warnings. {color:green}+1 lineLengths{color}. The patch does not introduce lines longer than 100 {color:green}+1 site{color}. The mvn post-site goal succeeds with this patch. {color:green}+1 core tests{color}. The patch passed unit tests in . Test results: https://builds.apache.org/job/PreCommit-HBASE-Build/16459//testReport/ Release Findbugs (version 2.0.3)warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/16459//artifact/patchprocess/newFindbugsWarnings.html Checkstyle Errors: https://builds.apache.org/job/PreCommit-HBASE-Build/16459//artifact/patchprocess/checkstyle-aggregate.html Console output: https://builds.apache.org/job/PreCommit-HBASE-Build/16459//console This message is automatically generated. > CF Level BC setting should override global one. > --- > > Key: HBASE-14189 > URL: https://issues.apache.org/jira/browse/HBASE-14189 > Project: HBase > Issue Type: Improvement > Components: BlockCache >Affects Versions: 2.0.0 >Reporter: Heng Chen >Assignee: Heng Chen > Attachments: HBASE-14189.patch, HBASE-14189_v1.patch, > HBASE-14189_v2.patch, HBASE-14189_v3.patch, HBASE-14189_v4.patch, > HBASE-14189_v5.patch > > > The original description is ambiguous. I think i will rewrite it. > Let's see {{BlockCache}} constructor firstly > {code} > public CacheConfig(Configuration conf, HColumnDescriptor family) { > this(CacheConfig.instantiateBlockCache(conf), > 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(HColumnDescriptor.CACHE_DATA_IN_L1, > HColumnDescriptor.DEFAULT_CACHE_DATA_IN_L1) || > family.isCacheDataInL1(), > > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY,DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > } > {code} > If we dig in it, we will see {{CacheConfig.cacheDataOnRead}} is used to > accept {{family.isBlockCacheEnabled()}}. > I think it is confused as comments about {{cacheDataOnRead}} > {code} > /** >* Whether blocks should be cached on read (default is on if there is a >* cache but this can be turned off on a per-family or per-request basis). >* If off we will STILL cache meta blocks; i.e. INDEX and BLOOM types. >* This cannot be disabled. >*/ > private boolean cacheDataOnRead; > {code} > So i think we should use another variable to represent for >
[jira] [Commented] (HBASE-14189) CF Level BC setting should override global one.
[ https://issues.apache.org/jira/browse/HBASE-14189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14996280#comment-14996280 ] Heng Chen commented on HBASE-14189: --- Update patch. Fix as QA suggestion. > CF Level BC setting should override global one. > --- > > Key: HBASE-14189 > URL: https://issues.apache.org/jira/browse/HBASE-14189 > Project: HBase > Issue Type: Improvement > Components: BlockCache >Affects Versions: 2.0.0 >Reporter: Heng Chen >Assignee: Heng Chen > Attachments: HBASE-14189.patch, HBASE-14189_v1.patch, > HBASE-14189_v2.patch, HBASE-14189_v3.patch, HBASE-14189_v4.patch, > HBASE-14189_v5.patch > > > The original description is ambiguous. I think i will rewrite it. > Let's see {{BlockCache}} constructor firstly > {code} > public CacheConfig(Configuration conf, HColumnDescriptor family) { > this(CacheConfig.instantiateBlockCache(conf), > 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(HColumnDescriptor.CACHE_DATA_IN_L1, > HColumnDescriptor.DEFAULT_CACHE_DATA_IN_L1) || > family.isCacheDataInL1(), > > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY,DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > } > {code} > If we dig in it, we will see {{CacheConfig.cacheDataOnRead}} is used to > accept {{family.isBlockCacheEnabled()}}. > I think it is confused as comments about {{cacheDataOnRead}} > {code} > /** >* Whether blocks should be cached on read (default is on if there is a >* cache but this can be turned off on a per-family or per-request basis). >* If off we will STILL cache meta blocks; i.e. INDEX and BLOOM types. >* This cannot be disabled. >*/ > private boolean cacheDataOnRead; > {code} > So i think we should use another variable to represent for > {{family.isBlockCacheEnabled()}}. > The secondary point is we use 'or' to decide {{cacheDataOnWrite}} is on/off > when both CF and global has this setting. > {code} > conf.getBoolean(CACHE_BLOCKS_ON_WRITE_KEY, > DEFAULT_CACHE_DATA_ON_WRITE) || family.isCacheDataOnWrite() > {code} > IMO we should use CF Level setting to override global setting. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (HBASE-14189) CF Level BC setting should override global one.
[ https://issues.apache.org/jira/browse/HBASE-14189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14991549#comment-14991549 ] Hadoop QA commented on HBASE-14189: --- {color:red}-1 overall{color}. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12770772/HBASE-14189_v4.patch against master branch at commit 050ebe850b32057860fb94b46f955352db139db1. ATTACHMENT ID: 12770772 {color:green}+1 @author{color}. The patch does not contain any @author tags. {color:green}+1 tests included{color}. The patch appears to include 12 new or modified tests. {color:green}+1 hadoop versions{color}. The patch compiles with all supported hadoop versions (2.4.0 2.4.1 2.5.0 2.5.1 2.5.2 2.6.0 2.6.1 2.7.0 2.7.1) {color:green}+1 javac{color}. The applied patch does not increase the total number of javac compiler warnings. {color:green}+1 protoc{color}. The applied patch does not increase the total number of protoc compiler warnings. {color:green}+1 javadoc{color}. The javadoc tool did not generate any warning messages. {color:red}-1 checkstyle{color}. The applied patch generated 1727 checkstyle errors (more than the master's current 1726 errors). {color:green}+1 findbugs{color}. The patch does not introduce any new Findbugs (version 2.0.3) warnings. {color:green}+1 release audit{color}. The applied patch does not increase the total number of release audit warnings. {color:green}+1 lineLengths{color}. The patch does not introduce lines longer than 100 {color:green}+1 site{color}. The mvn post-site goal succeeds with this patch. {color:red}-1 core tests{color}. The patch failed these unit tests: org.apache.hadoop.hbase.TestInterfaceAudienceAnnotations Test results: https://builds.apache.org/job/PreCommit-HBASE-Build/16406//testReport/ Release Findbugs (version 2.0.3)warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/16406//artifact/patchprocess/newFindbugsWarnings.html Checkstyle Errors: https://builds.apache.org/job/PreCommit-HBASE-Build/16406//artifact/patchprocess/checkstyle-aggregate.html Console output: https://builds.apache.org/job/PreCommit-HBASE-Build/16406//console This message is automatically generated. > CF Level BC setting should override global one. > --- > > Key: HBASE-14189 > URL: https://issues.apache.org/jira/browse/HBASE-14189 > Project: HBase > Issue Type: Improvement > Components: BlockCache >Affects Versions: 2.0.0 >Reporter: Heng Chen >Assignee: Heng Chen > Attachments: HBASE-14189.patch, HBASE-14189_v1.patch, > HBASE-14189_v2.patch, HBASE-14189_v3.patch, HBASE-14189_v4.patch > > > The original description is ambiguous. I think i will rewrite it. > Let's see {{BlockCache}} constructor firstly > {code} > public CacheConfig(Configuration conf, HColumnDescriptor family) { > this(CacheConfig.instantiateBlockCache(conf), > 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(HColumnDescriptor.CACHE_DATA_IN_L1, > HColumnDescriptor.DEFAULT_CACHE_DATA_IN_L1) || > family.isCacheDataInL1(), > > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY,DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > } > {code} > If we dig in it, we will see {{CacheConfig.cacheDataOnRead}} is used to > accept {{family.isBlockCacheEnabled()}}. > I think it is confused as comments about {{cacheDataOnRead}} > {code} > /** >* Whether blocks should be cached on read (default is on if there is a >* cache but this can be turned off on a per-family or per-request basis). >* If off we will STILL cache meta blocks; i.e. INDEX and BLOOM types. >* This cannot be disabled. >*/ > private boolean cacheDataOnRead; > {code} > So i think we should use
[jira] [Commented] (HBASE-14189) CF Level BC setting should override global one.
[ https://issues.apache.org/jira/browse/HBASE-14189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14982380#comment-14982380 ] Heng Chen commented on HBASE-14189: --- Thanks [~anoop.hbase], i will update next version ASAP. > CF Level BC setting should override global one. > --- > > Key: HBASE-14189 > URL: https://issues.apache.org/jira/browse/HBASE-14189 > Project: HBase > Issue Type: Improvement > Components: BlockCache >Affects Versions: 2.0.0 >Reporter: Heng Chen >Assignee: Heng Chen > Attachments: HBASE-14189.patch, HBASE-14189_v1.patch, > HBASE-14189_v2.patch, HBASE-14189_v3.patch > > > The original description is ambiguous. I think i will rewrite it. > Let's see {{BlockCache}} constructor firstly > {code} > public CacheConfig(Configuration conf, HColumnDescriptor family) { > this(CacheConfig.instantiateBlockCache(conf), > 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(HColumnDescriptor.CACHE_DATA_IN_L1, > HColumnDescriptor.DEFAULT_CACHE_DATA_IN_L1) || > family.isCacheDataInL1(), > > conf.getBoolean(DROP_BEHIND_CACHE_COMPACTION_KEY,DROP_BEHIND_CACHE_COMPACTION_DEFAULT) > ); > } > {code} > If we dig in it, we will see {{CacheConfig.cacheDataOnRead}} is used to > accept {{family.isBlockCacheEnabled()}}. > I think it is confused as comments about {{cacheDataOnRead}} > {code} > /** >* Whether blocks should be cached on read (default is on if there is a >* cache but this can be turned off on a per-family or per-request basis). >* If off we will STILL cache meta blocks; i.e. INDEX and BLOOM types. >* This cannot be disabled. >*/ > private boolean cacheDataOnRead; > {code} > So i think we should use another variable to represent for > {{family.isBlockCacheEnabled()}}. > The secondary point is we use 'or' to decide {{cacheDataOnWrite}} is on/off > when both CF and global has this setting. > {code} > conf.getBoolean(CACHE_BLOCKS_ON_WRITE_KEY, > DEFAULT_CACHE_DATA_ON_WRITE) || family.isCacheDataOnWrite() > {code} > Should we use CF Level setting to override global setting? -- This message was sent by Atlassian JIRA (v6.3.4#6332)