Monitor Kafka to prevent data loss


Is there any way we can monitor Kafka offsets through supervisor tasks ? we want to make sure there is no data loss when supervisor runs subsequent tasks.

Also, Can we use aggregateLag to monitor delay across all partitions ? OR should we consider looking at minimumLag ?

Thanks !