I have a stream topology which consumes from a topic and runs an aggregation and builds a KTable which is materialized into rocksDB.
I have another application that consumes all events from that same topic daily, and sends tombstone messages for events that meet some specific criteria (i.e. they are no longer needed). The aggregation deals with this and deletes from the state stores, but I'm looking at monitoring either the size of the state store or the change log topic - anything really that tells me the size of the ktable.
I have exposed the JMX metrics, but there is nothing there that appears to give me what I need. I can see the total number of "puts" into rocksDB, but not the total number of keys. My apps are spring boot and I would like to expose the metrics via prometheus.
Has anyone solved this issue or any ideas that would help?