-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[fix][txn] Transaction cumulative ack redeliver change #14371
[fix][txn] Transaction cumulative ack redeliver change #14371
Conversation
@congbobo184:Thanks for your contribution. For this PR, do we need to update docs? |
@congbobo184:Thanks for providing doc info! |
…tion_cumulative_abort_redeliver_message
The pr had no activity for 30 days, mark with Stale label. |
…tion_cumulative_abort_redeliver_message
…tion_cumulative_abort_redeliver_message
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That makes sense, LGTM, left a comment about the test.
pulsar-broker/src/test/java/org/apache/pulsar/client/impl/TransactionEndToEndTest.java
Show resolved
Hide resolved
…tion_cumulative_abort_redeliver_message # Conflicts: # pulsar-broker/src/test/java/org/apache/pulsar/client/impl/TransactionEndToEndTest.java
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
…tion_cumulative_abort_redeliver_message
…tion_cumulative_abort_redeliver_message
apache#10478 ### Motivation since apache#10478 merged, we should change the cumulative ack with transaction abort redeliver logic. We can't redeliver unCumulativeAck message by the server because the client will receive the new message and ack then will receive the old message they abort. in this case: 1. we have 5 message 2. cumulative ack 3 messages with the transaction 3. we abort this transaction 4. server redeliver message by the current consumer_epoch 5. the client will not filter the 4 or 5 messages, because in apache#10478 we don't change the client consumer epoch 6. client cumulative ack 4 5 with transaction and commit will lose the 1 2 3 messages and the consume message, not in order. ### Modifications don't redeliver any cumulative ack messages, it will do by user self
#10478
Motivation
since #10478 merged, we should change the cumulative ack with transaction abort redeliver logic. We can't redeliver unCumulativeAck message by the server because the client will receive the new message and ack then will receive the old message they abort.
in this case:
Modifications
don't redeliver any cumulative ack messages, it will do by user self
Verifying this change
don't need to add a test, the original test has been overwritten
Does this pull request potentially affect one of the following parts:
If
yes
was chosen, please highlight the changesDocumentation
Does this pull request introduces a new feature? (yes)
If yes, how is the feature documented? (not applicable / docs / JavaDocs / not documented)
If a feature is not applicable for documentation, explain why?
If a feature is not documented yet in this PR, please create a follow-up issue for adding the documentation
doc-not-needed