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

cadonna pushed a commit to branch 3.0
in repository https://gitbox.apache.org/repos/asf/kafka.git


The following commit(s) were added to refs/heads/3.0 by this push:
     new 08d2677  HOTFIX: Fix verification of version probing (#10943)
08d2677 is described below

commit 08d26773ec437b9dc8e780c622e1cf6a4d41da01
Author: Bruno Cadonna <[email protected]>
AuthorDate: Mon Jul 12 18:50:25 2021 +0200

    HOTFIX: Fix verification of version probing (#10943)
    
    Fixes and improves version probing in system test 
test_version_probing_upgrade().
---
 .../internals/assignment/StreamsAssignmentProtocolVersions.java      | 2 +-
 tests/kafkatest/tests/streams/streams_upgrade_test.py                | 5 +++--
 2 files changed, 4 insertions(+), 3 deletions(-)

diff --git 
a/streams/src/main/java/org/apache/kafka/streams/processor/internals/assignment/StreamsAssignmentProtocolVersions.java
 
b/streams/src/main/java/org/apache/kafka/streams/processor/internals/assignment/StreamsAssignmentProtocolVersions.java
index 42bb766..9bd7142 100644
--- 
a/streams/src/main/java/org/apache/kafka/streams/processor/internals/assignment/StreamsAssignmentProtocolVersions.java
+++ 
b/streams/src/main/java/org/apache/kafka/streams/processor/internals/assignment/StreamsAssignmentProtocolVersions.java
@@ -28,7 +28,7 @@ public final class StreamsAssignmentProtocolVersions {
      * Last version bump: May 2021, before 3.0
      *
      * When changing the version:
-     * 1) Update the version_probing_message and end_of_upgrade_message in 
streams_upgrade_test.py::StreamsUpgradeTest.test_version_probing_upgrade
+     * 1) Update variable highest_version in 
streams_upgrade_test.py::StreamsUpgradeTest.test_version_probing_upgrade
      * 2) Add a unit test in SubscriptionInfoTest and/or AssignmentInfoTest
      * 3) Note the date & corresponding Kafka version of this bump
      */
diff --git a/tests/kafkatest/tests/streams/streams_upgrade_test.py 
b/tests/kafkatest/tests/streams/streams_upgrade_test.py
index cb5375d..d3fa1a3 100644
--- a/tests/kafkatest/tests/streams/streams_upgrade_test.py
+++ b/tests/kafkatest/tests/streams/streams_upgrade_test.py
@@ -474,8 +474,9 @@ class StreamsUpgradeTest(Test):
                     monitors[first_other_processor] = first_other_monitor
                     monitors[second_other_processor] = second_other_monitor
 
-                    version_probing_message = "Sent a version 10 subscription 
and got version 10 assignment back (successful version probing). Downgrade 
subscription metadata to commonly supported version 10 and trigger new 
rebalance.",
-                    end_of_upgrade_message = "Sent a version 10 subscription 
and group.s latest commonly supported version is 11 (successful version probing 
and end of rolling upgrade). Upgrading subscription metadata version to 11 for 
next rebalance."
+                    highest_version = 10
+                    version_probing_message = "Sent a version " + 
str(highest_version + 1) + " subscription and got version " + 
str(highest_version) + " assignment back (successful version probing). 
Downgrade subscription metadata to commonly supported version " + 
str(highest_version) + " and trigger new rebalance."
+                    end_of_upgrade_message = "Sent a version " + 
str(highest_version) + " subscription and group.s latest commonly supported 
version is " + str(highest_version + 1) + " (successful version probing and end 
of rolling upgrade). Upgrading subscription metadata version to " + 
str(highest_version + 1) + " for next rebalance."
                     end_of_upgrade_error_message = "Could not detect 
'successful version probing and end of rolling upgrade' at upgraded node "
                     followup_rebalance_message = "Triggering the followup 
rebalance scheduled for 0 ms."
                     followup_rebalance_error_message = "Could not detect 
'Triggering followup rebalance' at node "

Reply via email to