diff --git a/async_producer.go b/async_producer.go index 5db0a73d47..75b95e49c4 100644 --- a/async_producer.go +++ b/async_producer.go @@ -191,10 +191,16 @@ type ProducerMessage struct { // Partition is the partition that the message was sent to. This is only // guaranteed to be defined if the message was successfully delivered. Partition int32 - // Timestamp is the timestamp assigned to the message by the broker. This - // is only guaranteed to be defined if the message was successfully - // delivered, RequiredAcks is not NoResponse, and the Kafka broker is at - // least version 0.10.0. + // Timestamp can be one of CreateTime or LogAppendTime (configured at the broker, + // default value CreateTime) when the broker version is at least 0.10.0. + // + // When configured to CreateTime, the timestamp is specified by the producer + // either by explicitly setting this field, or when the message is added + // to a produce set. + // + // When configured to LogAppendTime, the timestamp assigned to the message + // by the broker. This is only guaranteed to be defined if the message was + // successfully delivered and RequiredAcks is not NoResponse. Timestamp time.Time retries int