You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2019/01/24 06:25:55 UTC

[GitHub] wolfstudy commented on a change in pull request #3416: [pulsar-client-go]add producer.GetLastSequenceID in Go client

wolfstudy commented on a change in pull request #3416: [pulsar-client-go]add producer.GetLastSequenceID in Go client
URL: https://github.com/apache/pulsar/pull/3416#discussion_r250479365
 
 

 ##########
 File path: pulsar-client-go/pulsar/producer.go
 ##########
 @@ -163,6 +163,14 @@ type Producer interface {
 	// the eventual error in publishing
 	SendAsync(context.Context, ProducerMessage, func(ProducerMessage, error))
 
+	// Get the last sequence id that was published by this producer.
+	// This represent either the automatically assigned or custom sequence id (set on the MessageBuilder) that
+	// was published and acknowledged by the broker.
+	// After recreating a producer with the same producer name, this will return the last message that was
+	// published in the previous producer session, or -1 if there no message was ever published.
+	// return the last sequence id published by this producer.
+	GetLastSequenceID() int64
 
 Review comment:
    `LastSequenceID()` sounds good.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services