cassandra icon indicating copy to clipboard operation
cassandra copied to clipboard

CNDB-8772 Add sensors for index access

Open aymkhalil opened this issue 1 year ago • 3 comments

Addresses: https://github.com/riptano/cndb/issues/8772

Added INDEX_BYTES & SEARCH_BYTES sensors tracking for SAI and Seconday Index.

aymkhalil avatar Feb 27 '24 01:02 aymkhalil

I added rudimentary support for 2i index. lthough it shares code with the regular memtable updates, it is hard to come up with the written bytes from the standard cfs#apply code path (because it index column are treated as partition keys and excluded from the pu#dataSize calculations

@sbtourist let me know if this is good enough. My current "intuition" for now is to just remove 2i support and only focus on SAI. But I'm open to both supporting it at a basic level or even continue working on it for better support.

aymkhalil avatar Feb 27 '24 22:02 aymkhalil

@sbtourist I separated index writes into their own sensor (INDEX_BYTES) and added support for SEARCH_BYTES utilizing TrackingRowIterator - please take a look.

aymkhalil avatar Mar 07 '24 00:03 aymkhalil

@maxtomassi addressed your feedback in https://github.com/datastax/cassandra/pull/1019/commits/24de7ab2bcfa7ca39b70379fbd4d2f81b3e7f1ea. PTAL.

aymkhalil avatar May 07 '24 17:05 aymkhalil