I think the java doc of the setStartFromTimestamp
method has been explained very clearly, posted here:
* Specify the consumer to start reading
partitions from a specified timestamp.
* The specified timestamp must be before the
* This lets the consumer ignore any committed
group offsets in Zookeeper / Kafka brokers.
* <p>The consumer will look up the
earliest offset whose timestamp is greater than or
* to the specific timestamp from Kafka. If
there's no such offset, the consumer will use the
* latest offset to read data from kafka.
* <p>This method does not affect where
partitions are read from when the consumer is
* from a checkpoint or savepoint. When the
consumer is restored from a checkpoint or
* savepoint, only the offsets in the restored
state will be used.
* @param startupOffsetsTimestamp timestamp
for the startup offsets, as milliseconds from
* @return The consumer object, to allow