@Override
        public Map<SystemStreamPartition, SystemStreamMetadata.SystemStreamPartitionMetadata> apply(
            ExponentialSleepStrategy.RetryLoop loop) {
          OffsetsMaps topicPartitionsMetadata = fetchTopicPartitionsMetadata(topicPartitions);

          Map<SystemStreamPartition, SystemStreamMetadata.SystemStreamPartitionMetadata> sspToSSPMetadata = new HashMap<>();
          for (SystemStreamPartition ssp : ssps) {
            String oldestOffset = topicPartitionsMetadata.getOldestOffsets().get(ssp);
            String newestOffset = topicPartitionsMetadata.getNewestOffsets().get(ssp);
            String upcomingOffset = topicPartitionsMetadata.getUpcomingOffsets().get(ssp);

            sspToSSPMetadata.put(ssp,
                new SystemStreamMetadata.SystemStreamPartitionMetadata(oldestOffset, newestOffset, upcomingOffset));
          }
          loop.done();
          return sspToSSPMetadata;
        }
Given a set of SystemStreamPartition, fetch metadata from Kafka for each
of them, and return a map from ssp to SystemStreamPartitionMetadata for
each of them. This method will return null for oldest and newest offsets
if a given SystemStreamPartition is empty. This method will block and
retry indefinitely until it gets a successful response from Kafka.
@param ssps a set of strings of SSP
@param retryBackoff retry backoff strategy
@return a map from ssp to sspMetadata which has offsets
samza-kafka/src/main/java/org/apache/samza/system/kafka/KafkaSystemAdmin.java