codelipenghui opened a new pull request #5653: Add highest sequenceId for CommandSendReceipt. URL: https://github.com/apache/pulsar/pull/5653 # Motivation Since #5491 merged, while user use new pulsar client to produce batch messages to older version broker(e.g. 2.4.0), send ack error will occur: ``` [pulsar-client-io-8-2] WARN org.apache.pulsar.client.impl.ProducerImpl - [persistent://sandbox/pressure-test/test-A-partition-11] [pulsar-cluster-test-13-294] Got ack for msg. expecting: 13 - got: 224 - queue-size: 9 ``` The problem is client use highest sequence id to match the response sequence id, but in old version broker can not return the highest id. So, this pr is try to fix the problem of produce batch message with new version client and old version broker. ### Modifications Add highest sequence id to CommandSendReceipt. If the response highest sequence id of send receipt > lowest sequence id, it means broker is a new version broker, so we need to verify the highest sequence id, otherwise we only verify the lowest sequence id. ### Verifying this change I have test on my mac book, use new version client to produce batch messages to new version broker passed and use new version client to produce batch messages to old version broker (2.4.0)passed. ### Does this pull request potentially affect one of the following parts: *If `yes` was chosen, please highlight the changes* - Dependencies (does it add or upgrade a dependency): (no) - The public API: (no) - The schema: (no) - The default values of configurations: (no) - The wire protocol: (yes) - The rest endpoints: (no) - The admin cli options: (no) - Anything that affects deployment: (no) ### Documentation - Does this pull request introduce a new feature? (no)
---------------------------------------------------------------- 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: [email protected] With regards, Apache Git Services
