private long getTotalOffsetAfterTokenPointedStoreKey(StoreFindToken indexBasedToken) throws StoreException {
    StoreKey storeKey = indexBasedToken.getStoreKey();
    List<MessageInfo> entries = new ArrayList<>();
    IndexSegment indexSegment = validIndexSegments.get(indexBasedToken.getOffset());
    indexSegment.getEntriesSince(storeKey, new FindEntriesCondition(Long.MAX_VALUE), entries, new AtomicLong(0), false);
    long totalSizeNotReplicated = 0;
    for (MessageInfo messageInfo : entries) {
      totalSizeNotReplicated += messageInfo.getSize();
    }
    return totalSizeNotReplicated;
  }
Get the absolute read bytes after index based token {@link StoreKey}.
@param indexBasedToken the point until which the log has been read.
@return the absolute read bytes after index based token {@link StoreKey}.
@throws StoreException
ambry-store/src/main/java/com/github/ambry/store/PersistentIndex.java