-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
[Issue 8260] Support reset cursor to a batch index of the batching message #8285
Conversation
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
Still have some problem, unit test written by me can't be passed(due to timeout), Maybe there is some thing wrong with my test configuration
PTAL @codelipenghui |
/pulsarbot run-failure-checks |
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
/pulsarbot run-failure-checks |
1 similar comment
/pulsarbot run-failure-checks |
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.
I have double-checked the implementation of the Batch Index Acknowledgment
. Looks we can only pass the ackset
to the broker from the client-side, because currently true
in the BitSet
represent the message does not acked, and false
means the batch index are acked. So I think it's the root cause of why the consumer start receive message from the next message of the reset position. You can refer to
Lines 188 to 190 in 59e0cfb
BitSetRecyclable bitSet = BitSetRecyclable.create(); | |
bitSet.set(0, batchSize); | |
bitSet.clear(0, batchIndex + 1); |
pulsar-broker/src/main/java/org/apache/pulsar/broker/service/ServerCnx.java
Outdated
Show resolved
Hide resolved
pulsar-broker/src/test/java/org/apache/pulsar/broker/service/SubscriptionSeekTest.java
Outdated
Show resolved
Hide resolved
pulsar-common/src/main/java/org/apache/pulsar/common/protocol/Commands.java
Outdated
Show resolved
Hide resolved
pulsar-broker/src/main/java/org/apache/pulsar/broker/service/ServerCnx.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
/pulsarbot run-failure-checks |
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
/pulsarbot run-failure-checks |
Signed-off-by: Renkai <gaelookair@gmail.com>
pulsar-common/src/main/java/org/apache/pulsar/common/protocol/Commands.java
Outdated
Show resolved
Hide resolved
pulsar-broker/src/main/java/org/apache/pulsar/broker/service/ServerCnx.java
Outdated
Show resolved
Hide resolved
pulsar-broker/src/test/java/org/apache/pulsar/broker/service/SubscriptionSeekTest.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Renkai <gaelookair@gmail.com>
ping @codelipenghui PTAL again thanks. |
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
pulsar-broker/src/test/java/org/apache/pulsar/broker/service/SubscriptionSeekTest.java
Outdated
Show resolved
Hide resolved
pulsar-broker/src/test/java/org/apache/pulsar/broker/service/SubscriptionSeekTest.java
Outdated
Show resolved
Hide resolved
pulsar-broker/src/test/java/org/apache/pulsar/broker/service/SubscriptionSeekTest.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
Signed-off-by: Renkai <gaelookair@gmail.com>
/pulsarbot run-failure-checks |
cherry-picked to branch-2.6(2.6.2) |
…ssage (apache#8285) ### Motivation Make reset cursor command able to reset to a specific index in batch mode. ### Modifications Now reset offset command change index info on broker side
…ssage (apache#8285) ### Motivation Make reset cursor command able to reset to a specific index in batch mode. ### Modifications Now reset offset command change index info on broker side
Signed-off-by: Renkai gaelookair@gmail.com
(If this PR fixes a github issue, please add
Fixes #<xyz>
.)Fixes #8260
Motivation
Make reset cursor command able to reset to a specific index in batch mode.
Modifications
Now reset offset command change index info on broker side
Verifying this change
This change added tests and can be verified as follows:
(example:)
Does this pull request potentially affect one of the following parts:
If
yes
was chosen, please highlight the changesDocumentation