KAFKA-13769 Fix version check in SubscriptionStoreReceiveProcessorSupplier#12535
Conversation
|
@vvcephei Can you please review? |
|
Test failure: seems unrelated. |
There was a problem hiding this comment.
Thanks, @Gerrrr !
Since we've just been burned by the specificity of unit testing, do you think there's value in adding an upgrade test? There are good examples of upgrade tests in the system tests, if you can't immediately see how to do it in an integration test.
We can also do that in follow-up if you don't want to block this fix, but it's starting to look like a good idea for preventing regressions in the future.
| return; | ||
| } | ||
| if (record.value().getVersion() != SubscriptionWrapper.CURRENT_VERSION) { | ||
| if (record.value().getVersion() > SubscriptionWrapper.CURRENT_VERSION) { |
There was a problem hiding this comment.
I assume that you've now searched the code base for every usage of getVersion and CURRENT_VERSION to make sure we don't have any more sneaky bugs, right?
There was a problem hiding this comment.
There is
I did not update it because the version check there is for SubscriptionResponseWrapper and its version wasn't incremented.
There was a problem hiding this comment.
Ok, let's make sure we follow-up with that fix as well.
|
I added an upgrade test back in #12122. Unfortunately, it didn't catch these version check bugs. I am going to figure out why and improve the test. I'd prefer to do that in a separate patch though. |
|
Test failure was unrelated: |
…plier (#12535) This patch fixes another incorrect version check in the FK code and adds unit tests that would have caught this bug. Reviewers: John Roesler <vvcephei@apache.org>
This patch fixes another incorrect version check in the FK code and adds unit tests that would have caught this bug.
Committer Checklist (excluded from commit message)