pulsar-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] wolfstudy commented on a change in pull request #3416: [pulsar-client-go]add producer.GetLastSequenceID in Go client
Date Thu, 24 Jan 2019 06:25:55 GMT
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

Mime
View raw message