You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kafka.apache.org by rs...@apache.org on 2019/06/27 16:50:38 UTC

[kafka] branch trunk updated: MINOR: Fix failing upgrade test by supporting both security.inter.broker.protocol and inter.broker.listener.name depending on kafka version (#7000)

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

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


The following commit(s) were added to refs/heads/trunk by this push:
     new 594d043  MINOR: Fix failing upgrade test by supporting both security.inter.broker.protocol and inter.broker.listener.name depending on kafka version (#7000)
594d043 is described below

commit 594d0430377446e672322e8ef3f509eca419ec46
Author: Stanislav Vodetskyi <49...@users.noreply.github.com>
AuthorDate: Thu Jun 27 09:50:17 2019 -0700

    MINOR: Fix failing upgrade test by supporting both security.inter.broker.protocol and inter.broker.listener.name depending on kafka version (#7000)
    
    Reviewers: Brian Bushree <bb...@confluent.io>, Rajini Sivaram <ra...@googlemail.com>
---
 tests/kafkatest/services/kafka/templates/kafka.properties | 4 ++++
 tests/kafkatest/version.py                                | 3 +++
 2 files changed, 7 insertions(+)

diff --git a/tests/kafkatest/services/kafka/templates/kafka.properties b/tests/kafkatest/services/kafka/templates/kafka.properties
index 2736e91..11e43be 100644
--- a/tests/kafkatest/services/kafka/templates/kafka.properties
+++ b/tests/kafkatest/services/kafka/templates/kafka.properties
@@ -21,7 +21,11 @@ listeners={{ listeners }}
 advertised.listeners={{ advertised_listeners }}
 listener.security.protocol.map={{ listener_security_protocol_map }}
 
+{% if node.version.supports_named_listeners() %}
 inter.broker.listener.name={{ interbroker_listener.name }}
+{% else %}
+security.inter.broker.protocol={{ interbroker_listener.security_protocol }}
+{% endif %}
 
 ssl.keystore.location=/mnt/security/test.keystore.jks
 ssl.keystore.password=test-ks-passwd
diff --git a/tests/kafkatest/version.py b/tests/kafkatest/version.py
index 403da03..fa1caa7 100644
--- a/tests/kafkatest/version.py
+++ b/tests/kafkatest/version.py
@@ -49,6 +49,9 @@ class KafkaVersion(LooseVersion):
         else:
             return LooseVersion.__str__(self)
 
+    def supports_named_listeners(self):
+        return self >= V_0_10_2_0
+
 
 def get_version(node=None):
     """Return the version attached to the given node.