Broker Partition Write Rate (bytes/s)

I am attempting to retrieve some broker metrics which I don’t seem to find anywhere available.

The metric I require is the write rate of all the partitions that belong to a certain topic (not avg max or min).

From what I have seen the JMX metrics do not provide any information w.r.t. these metrics, and as such, I have been trying to implement a workaround using the total amount of bytes in a single partition spanned through a predefined time delta (like 30s). The problem I am now facing, is that I can’t find any metric that indicates the historic size of a partition, so if passes, the partition starts releasing records, and the byte count reduces for the partition, providing a misleading negative write rate.

Is anyone aware of any metric that provides any of the information I require?

Thank you in advance!

what about saving the metrics in
prometheus or something like this to have nice overview about the history?

maybe this one helps