public ModifyableColumnFamilyDescriptor setBloomFilterType(final BloomType bt) { return setValue(BLOOMFILTER_BYTES, bt.name()); }
private void parseColumnFamilyOptions(CommandLine cmd) { String dataBlockEncodingStr = cmd.getOptionValue(HFileTestUtil.OPT_DATA_BLOCK_ENCODING); dataBlockEncodingAlgo = dataBlockEncodingStr == null ? null : DataBlockEncoding.valueOf(dataBlockEncodingStr); String compressStr = cmd.getOptionValue(OPT_COMPRESSION); compressAlgo = compressStr == null ? Compression.Algorithm.NONE : Compression.Algorithm.valueOf(compressStr); String bloomStr = cmd.getOptionValue(OPT_BLOOM); bloomType = bloomStr == null ? BloomType.ROW : BloomType.valueOf(bloomStr); if (bloomType == BloomType.ROWPREFIX_FIXED_LENGTH) { if (!cmd.hasOption(OPT_BLOOM_PARAM)) { LOG.error("the parameter of bloom filter {} is not specified", bloomType.name()); } else { conf.set(BloomFilterUtil.PREFIX_LENGTH_KEY, cmd.getOptionValue(OPT_BLOOM_PARAM)); } } if (bloomType == BloomType.ROWPREFIX_DELIMITED) { if (!cmd.hasOption(OPT_BLOOM_PARAM)) { LOG.error("the parameter of bloom filter {} is not specified", bloomType.name()); } else { conf.set(BloomFilterUtil.DELIMITER_KEY, cmd.getOptionValue(OPT_BLOOM_PARAM)); } } inMemoryCF = cmd.hasOption(OPT_INMEMORY); if (cmd.hasOption(OPT_ENCRYPTION)) { cipher = Encryption.getCipher(conf, cmd.getOptionValue(OPT_ENCRYPTION)); } }
public ModifyableColumnFamilyDescriptor setBloomFilterType(final BloomType bt) { return setValue(BLOOMFILTER_BYTES, bt.name()); }
public ModifyableColumnFamilyDescriptor setBloomFilterType(final BloomType bt) { return setValue(BLOOMFILTER_BYTES, bt.name()); }
private static ColumnFamilyDescriptor getColumnFamilyDescriptor(HColumnDescriptor descriptor) { String name = descriptor.getNameAsString(); int maxVersions = descriptor.getMaxVersions(); ColumnFamilyDescriptor.CompressionType compressionType = ColumnFamilyDescriptor.CompressionType.valueOf(descriptor.getCompressionType().getName().toUpperCase()); ColumnFamilyDescriptor.BloomType bloomType = ColumnFamilyDescriptor.BloomType.valueOf(descriptor.getBloomFilterType().name().toUpperCase()); Map<String, String> properties = new HashMap<>(); for (Map.Entry<ImmutableBytesWritable, ImmutableBytesWritable> value : descriptor.getValues().entrySet()) { properties.put(org.apache.hadoop.hbase.util.Bytes.toString(value.getKey().get()), org.apache.hadoop.hbase.util.Bytes.toString(value.getValue().get())); } return new ColumnFamilyDescriptor(name, maxVersions, compressionType, bloomType, properties); } }
private static ColumnFamilyDescriptor getColumnFamilyDescriptor(HColumnDescriptor descriptor) { String name = descriptor.getNameAsString(); int maxVersions = descriptor.getMaxVersions(); ColumnFamilyDescriptor.CompressionType compressionType = ColumnFamilyDescriptor.CompressionType.valueOf(descriptor.getCompressionType().getName().toUpperCase()); ColumnFamilyDescriptor.BloomType bloomType = ColumnFamilyDescriptor.BloomType.valueOf(descriptor.getBloomFilterType().name().toUpperCase()); Map<String, String> properties = new HashMap<>(); for (Map.Entry<ImmutableBytesWritable, ImmutableBytesWritable> value : descriptor.getValues().entrySet()) { properties.put(org.apache.hadoop.hbase.util.Bytes.toString(value.getKey().get()), org.apache.hadoop.hbase.util.Bytes.toString(value.getValue().get())); } return new ColumnFamilyDescriptor(name, maxVersions, compressionType, bloomType, properties); } }
private static ColumnFamilyDescriptor getColumnFamilyDescriptor(HColumnDescriptor descriptor) { String name = descriptor.getNameAsString(); int maxVersions = descriptor.getMaxVersions(); ColumnFamilyDescriptor.CompressionType compressionType = ColumnFamilyDescriptor.CompressionType.valueOf(descriptor.getCompressionType().getName().toUpperCase()); ColumnFamilyDescriptor.BloomType bloomType = ColumnFamilyDescriptor.BloomType.valueOf(descriptor.getBloomFilterType().name().toUpperCase()); Map<String, String> properties = new HashMap<>(); for (Map.Entry<ImmutableBytesWritable, ImmutableBytesWritable> value : descriptor.getValues().entrySet()) { properties.put(org.apache.hadoop.hbase.util.Bytes.toString(value.getKey().get()), org.apache.hadoop.hbase.util.Bytes.toString(value.getValue().get())); } return new ColumnFamilyDescriptor(name, maxVersions, compressionType, bloomType, properties); } }
private static ColumnFamilyDescriptor getColumnFamilyDescriptor(HColumnDescriptor descriptor) { String name = descriptor.getNameAsString(); int maxVersions = descriptor.getMaxVersions(); ColumnFamilyDescriptor.CompressionType compressionType = ColumnFamilyDescriptor.CompressionType.valueOf(descriptor.getCompressionType().getName().toUpperCase()); ColumnFamilyDescriptor.BloomType bloomType = ColumnFamilyDescriptor.BloomType.valueOf(descriptor.getBloomFilterType().name().toUpperCase()); Map<String, String> properties = new HashMap<>(); for (Map.Entry<ImmutableBytesWritable, ImmutableBytesWritable> value : descriptor.getValues().entrySet()) { properties.put(org.apache.hadoop.hbase.util.Bytes.toString(value.getKey().get()), org.apache.hadoop.hbase.util.Bytes.toString(value.getValue().get())); } return new ColumnFamilyDescriptor(name, maxVersions, compressionType, bloomType, properties); } }
private static ColumnFamilyDescriptor getColumnFamilyDescriptor(HColumnDescriptor descriptor) { String name = descriptor.getNameAsString(); int maxVersions = descriptor.getMaxVersions(); ColumnFamilyDescriptor.CompressionType compressionType = ColumnFamilyDescriptor.CompressionType.valueOf(descriptor.getCompressionType().getName().toUpperCase()); ColumnFamilyDescriptor.BloomType bloomType = ColumnFamilyDescriptor.BloomType.valueOf(descriptor.getBloomFilterType().name().toUpperCase()); Map<String, String> properties = new HashMap<>(); for (Map.Entry<ImmutableBytesWritable, ImmutableBytesWritable> value : descriptor.getValues().entrySet()) { properties.put(org.apache.hadoop.hbase.util.Bytes.toString(value.getKey().get()), org.apache.hadoop.hbase.util.Bytes.toString(value.getValue().get())); } return new ColumnFamilyDescriptor(name, maxVersions, compressionType, bloomType, properties); } }
private static ColumnFamilyDescriptor getColumnFamilyDescriptor(HColumnDescriptor descriptor) { String name = descriptor.getNameAsString(); int maxVersions = descriptor.getMaxVersions(); ColumnFamilyDescriptor.CompressionType compressionType = ColumnFamilyDescriptor.CompressionType.valueOf(descriptor.getCompressionType().getName().toUpperCase()); ColumnFamilyDescriptor.BloomType bloomType = ColumnFamilyDescriptor.BloomType.valueOf(descriptor.getBloomFilterType().name().toUpperCase()); Map<String, String> properties = new HashMap<>(); for (Map.Entry<ImmutableBytesWritable, ImmutableBytesWritable> value : descriptor.getValues().entrySet()) { properties.put(org.apache.hadoop.hbase.util.Bytes.toString(value.getKey().get()), org.apache.hadoop.hbase.util.Bytes.toString(value.getValue().get())); } return new ColumnFamilyDescriptor(name, maxVersions, compressionType, bloomType, properties); } }
private static ColumnFamilyDescriptor getColumnFamilyDescriptor(HColumnDescriptor descriptor) { String name = descriptor.getNameAsString(); int maxVersions = descriptor.getMaxVersions(); ColumnFamilyDescriptor.CompressionType compressionType = ColumnFamilyDescriptor.CompressionType.valueOf(descriptor.getCompressionType().getName().toUpperCase()); ColumnFamilyDescriptor.BloomType bloomType = ColumnFamilyDescriptor.BloomType.valueOf(descriptor.getBloomFilterType().name().toUpperCase()); Map<String, String> properties = new HashMap<>(); for (Map.Entry<ImmutableBytesWritable, ImmutableBytesWritable> value : descriptor.getValues().entrySet()) { properties.put(org.apache.hadoop.hbase.util.Bytes.toString(value.getKey().get()), org.apache.hadoop.hbase.util.Bytes.toString(value.getValue().get())); } return new ColumnFamilyDescriptor(name, maxVersions, compressionType, bloomType, properties); } }
public HFileTarget(Path path, HColumnDescriptor hcol) { super(path, HFileOutputFormatForCrunch.class, SequentialFileNamingScheme.getInstance()); if (hcol != null) { outputConf(HFileOutputFormatForCrunch.HCOLUMN_DESCRIPTOR_COMPRESSION_TYPE_KEY, hcol.getCompressionType().getName()); outputConf(HFileOutputFormatForCrunch.HCOLUMN_DESCRIPTOR_DATA_BLOCK_ENCODING_KEY, hcol.getDataBlockEncoding().name()); outputConf(HFileOutputFormatForCrunch.HCOLUMN_DESCRIPTOR_BLOOM_FILTER_TYPE_KEY, hcol.getBloomFilterType().name()); } }
columnFamily.setAttribute(ATTR_CF_BLOOMFILTER_TYPE, (hColumnDescriptor.getBloomFilterType() != null ? hColumnDescriptor.getBloomFilterType().name():null)); columnFamily.setAttribute(ATTR_CF_CACHED_BLOOM_ON_WRITE, hColumnDescriptor.isCacheBloomsOnWrite()); columnFamily.setAttribute(ATTR_CF_CACHED_DATA_ON_WRITE, hColumnDescriptor.isCacheDataOnWrite());
columnFamily.setAttribute(ATTR_CF_BLOOMFILTER_TYPE, (hColumnDescriptor.getBloomFilterType() != null ? hColumnDescriptor.getBloomFilterType().name():null)); columnFamily.setAttribute(ATTR_CF_CACHED_BLOOM_ON_WRITE, hColumnDescriptor.isCacheBloomsOnWrite()); columnFamily.setAttribute(ATTR_CF_CACHED_DATA_ON_WRITE, hColumnDescriptor.isCacheDataOnWrite());
ret.setAttribute(OWNER, owner); ret.setAttribute(ATTR_CF_BLOCK_CACHE_ENABLED, hcdt.isBlockCacheEnabled()); ret.setAttribute(ATTR_CF_BLOOMFILTER_TYPE, (hcdt.getBloomFilterType() != null ? hcdt.getBloomFilterType().name():null)); ret.setAttribute(ATTR_CF_CACHED_BLOOM_ON_WRITE, hcdt.isCacheBloomsOnWrite()); ret.setAttribute(ATTR_CF_CACHED_DATA_ON_WRITE, hcdt.isCacheDataOnWrite());
ret.setAttribute(OWNER, owner); ret.setAttribute(ATTR_CF_BLOCK_CACHE_ENABLED, hcdt.isBlockCacheEnabled()); ret.setAttribute(ATTR_CF_BLOOMFILTER_TYPE, (hcdt.getBloomFilterType() != null ? hcdt.getBloomFilterType().name():null)); ret.setAttribute(ATTR_CF_CACHED_BLOOM_ON_WRITE, hcdt.isCacheBloomsOnWrite()); ret.setAttribute(ATTR_CF_CACHED_DATA_ON_WRITE, hcdt.isCacheDataOnWrite());