Database Reference
In-Depth Information
You can create a table with the false-positive chance as 0.001 as follows:
# Create column family with false positive chance = 0.001
CREATE TABLE toomanyrows (id int PRIMARY KEY, name text)
WITH
bloom_filter_fp_chance = 0.001;
One may alter the false-positive chance on an up-and-running cluster without any need to
reboot. Alternatively, the false-positive chance is applied only to the newer SST-
ables—created by means of flush or via compaction.
One can always see the bloom filter chance by running the describe command in
cqlsh or cassandra-cli or by running a nodetool request for cfstats . The
node tool displays the current ratio too. The following is an example using the DESC com-
mand:
# Incassandra-cli
DESC TABLE toomanyrows;
CREATE TABLE demo_cql.toomanyrows (
id int PRIMARY KEY,
name text
) WITH bloom_filter_fp_chance = 0.001
[-- snip --]
AND speculative_retry = '99.0PERCENTILE';
The current ratio is displayed via nodetool (all the statistics are zero because the table
is unused, but as soon as you start reading and writing out of it statistics like this are pretty
helpful to make decisions):
bin/nodetool cfstats demo_cql.toomanyrows
Keyspace: demo_cql
Read Count: 0
Read Latency: NaN ms.
Write Count: 0
Write Latency: NaN ms.
Pending Flushes: 0
Table: toomanyrows
SSTable count: 0
[-- snip -- ]
Search WWH ::




Custom Search