This is an automated email from the ASF dual-hosted git repository.

rxl pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pulsar-client-go.git


The following commit(s) were added to refs/heads/master by this push:
     new 15136a7  Fix ack request not set requestId when enable AckWithResponse 
option (#780)
15136a7 is described below

commit 15136a706f1293615507fcbfb85163be2932bbb0
Author: liushengzhong0927 <[email protected]>
AuthorDate: Sat May 28 01:41:00 2022 +0800

    Fix ack request not set requestId when enable AckWithResponse option (#780)
    
    Fixes #779
    
    Motivation
    Fix bug in #779
    
    Modifications
    Set requestId int the ack request command when the AckWithResponse option 
is enabled.
---
 pulsar/consumer_partition.go | 1 +
 1 file changed, 1 insertion(+)

diff --git a/pulsar/consumer_partition.go b/pulsar/consumer_partition.go
index 06ccfd5..b7c2c8e 100644
--- a/pulsar/consumer_partition.go
+++ b/pulsar/consumer_partition.go
@@ -534,6 +534,7 @@ func (pc *partitionConsumer) internalAck(req *ackRequest) {
        }
 
        if pc.options.ackWithResponse {
+               cmdAck.RequestId = proto.Uint64(reqID)
                _, err := pc.client.rpcClient.RequestOnCnx(pc._getConn(), 
reqID, pb.BaseCommand_ACK, cmdAck)
                if err != nil {
                        pc.log.WithError(err).Error("Ack with response error")

Reply via email to