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 2020/04/15 15:33:46 UTC

[GitHub] [pulsar-client-go] skyrocknroll commented on a change in pull request #225: Added an function to serialize the messageID to string

skyrocknroll commented on a change in pull request #225: Added an function to serialize the messageID to string
URL: https://github.com/apache/pulsar-client-go/pull/225#discussion_r408936946
 
 

 ##########
 File path: pulsar/impl_message.go
 ##########
 @@ -93,6 +94,10 @@ func (id *messageID) Serialize() []byte {
 	data, _ := proto.Marshal(msgID)
 	return data
 }
+func (id *messageID) SerializeToString() string {
+
+	return fmt.Sprintf("%d:%d:%d:%d", id.ledgerID, id.entryID, id.batchIdx, id.partitionIdx)
 
 Review comment:
   Make sense. Thanks @merlimat

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to 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