Problem
I am thinking about implementing binary search to find a starting offset for time-based event replaying. In order to do so I was thinking about using EARLIEST to find the beginning offset and LATEST to find the latest offset. After that I could implement binary search to find what offset I need to start replaying from.
Question
I was wondering how efficient seeking to EARLIEST and LATEST is and how it is implemented. Do they simply just use the znode timestamp in your topic's directory and find the file with the latest timestamp to look at? That would be my guess but I'm just shooting into the dark there.
Thank you in advance!