Cassandra nodetool cfstats - 读取计数始终为 0

Cassandra nodetool cfstats - Read Count is always 0

我在监控我的 Cassandra 节点时遇到了问题。我运行

nodetool cfstats keyspaceName.tableName

不幸的是,读取计数始终为 0,读取延迟为 NaN。我正在进行读取和写入操作,但只有写入指标会更新。

这是我得到的输出:

Starting NodeTool
Keyspace: realtimetrader
    Read Count: 0
    Read Latency: NaN ms.
    Write Count: 402
    Write Latency: 0.09648756218905473 ms.
    Pending Flushes: 0
            Table: currencies
            SSTable count: 1
            Space used (live): 5254
            Space used (total): 5254
            Space used by snapshots (total): 0
            Off heap memory used (total): 40
            SSTable Compression Ratio: 0.0
            Number of keys (estimate): 14
            Memtable cell count: 1608
            Memtable data size: 567
            Memtable off heap memory used: 0
            Memtable switch count: 0
            Local read count: 0
            Local read latency: NaN ms
            Local write count: 402
            Local write latency: 0.106 ms
            Pending flushes: 0
            Bloom filter false positives: 0
            Bloom filter false ratio: 0,00000
            Bloom filter space used: 24
            Bloom filter off heap memory used: 16
            Index summary off heap memory used: 16
            Compression metadata off heap memory used: 8
            Compacted partition minimum bytes: 125
            Compacted partition maximum bytes: 149
            Compacted partition mean bytes: 149
            Average live cells per slice (last five minutes): 0.0
            Maximum live cells per slice (last five minutes): 0
            Average tombstones per slice (last five minutes): 0.0
            Maximum tombstones per slice (last five minutes): 0

----------------

感谢任何帮助。

由于每个节点负责不同的数据集,所以有可能你一直在读取的所有数据都属于其他节点。许多驱动程序都有一个令牌感知负载平衡策略,该策略会将读取发送到应该拥有它的节点。使用 CL.ONE 默认一致性,这也意味着它将读取发送到其他节点的捷径(除了达到读取修复机会的情况)。

根据您使用的版本以及您进行的查询,您可能也看不到此增量:https://issues.apache.org/jira/browse/CASSANDRA-7338