Kudu C++ client API
Loading...
Searching...
No Matches
Public Member Functions | List of all members
kudu::client::KuduBloomFilterBuilder Class Reference

Builder class to help build KuduBloomFilter to be used with IN Bloom filter predicate. More...

#include <scan_predicate.h>

Public Member Functions

 KuduBloomFilterBuilder (size_t num_keys)
 
KuduBloomFilterBuilderfalse_positive_probability (double fpp)
 
KuduBloomFilterBuilderhash_algorithm (HashAlgorithm hash_algorithm)
 
KuduBloomFilterBuilderhash_seed (uint32_t hash_seed)
 
Status Build (KuduBloomFilter **bloom_filter)
 

Detailed Description

Builder class to help build KuduBloomFilter to be used with IN Bloom filter predicate.

Constructor & Destructor Documentation

◆ KuduBloomFilterBuilder()

kudu::client::KuduBloomFilterBuilder::KuduBloomFilterBuilder ( size_t  num_keys)
explicit
Parameters
[in]num_keysExpected number of elements to be inserted in the Bloom filter.

Member Function Documentation

◆ Build()

Status kudu::client::KuduBloomFilterBuilder::Build ( KuduBloomFilter **  bloom_filter)

Build a new Bloom filter to be used with IN Bloom filter predicate.

Parameters
[out]bloom_filterOn success, the created Bloom filter raw pointer. Caller owns the Bloom filter until it's passed to KuduTable::NewInBloomFilterPredicate().
Returns
On success, Status::OK() with the created Bloom filter in bloom_filter output parameter. On failure to allocate memory or invalid arguments, corresponding error status.

◆ false_positive_probability()

KuduBloomFilterBuilder & kudu::client::KuduBloomFilterBuilder::false_positive_probability ( double  fpp)
Parameters
[in]fppDesired false positive probability between 0.0 and 1.0. If not provided, defaults to 0.01.
Returns
Reference to the updated object.

◆ hash_algorithm()

KuduBloomFilterBuilder & kudu::client::KuduBloomFilterBuilder::hash_algorithm ( HashAlgorithm  hash_algorithm)
Parameters
[in]hash_algorithmHash algorithm used to hash keys before inserting to the Bloom filter. If not provided, defaults to FAST_HASH.
Note
Currently only FAST_HASH is supported.
Returns
Reference to the updated object.

◆ hash_seed()

KuduBloomFilterBuilder & kudu::client::KuduBloomFilterBuilder::hash_seed ( uint32_t  hash_seed)
Parameters
[in]hash_seedSeed used with hash algorithm to hash the keys before inserting to the Bloom filter. If not provided, defaults to 0.
Returns
Reference to the updated object.

The documentation for this class was generated from the following file: