You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kafka.apache.org by mj...@apache.org on 2020/06/24 01:52:31 UTC

[kafka] branch 2.4 updated: HOTFIX: use equals() to compare HostInfo in StreamsMetadataState (#8919)

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

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


The following commit(s) were added to refs/heads/2.4 by this push:
     new a91e91b  HOTFIX: use equals() to compare HostInfo in StreamsMetadataState (#8919)
a91e91b is described below

commit a91e91b31b7d03acf43367a9230484d431ffd193
Author: A. Sophie Blee-Goldman <so...@confluent.io>
AuthorDate: Tue Jun 23 18:37:11 2020 -0700

    HOTFIX: use equals() to compare HostInfo in StreamsMetadataState (#8919)
    
    Reviewer: Matthias J. Sax <ma...@confluent.io>
---
 .../kafka/streams/processor/internals/StreamsMetadataState.java       | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/streams/src/main/java/org/apache/kafka/streams/processor/internals/StreamsMetadataState.java b/streams/src/main/java/org/apache/kafka/streams/processor/internals/StreamsMetadataState.java
index 27826a6..e81ff61 100644
--- a/streams/src/main/java/org/apache/kafka/streams/processor/internals/StreamsMetadataState.java
+++ b/streams/src/main/java/org/apache/kafka/streams/processor/internals/StreamsMetadataState.java
@@ -141,7 +141,7 @@ public class StreamsMetadataState {
         if (globalStores.contains(storeName)) {
             // global stores are on every node. if we dont' have the host info
             // for this host then just pick the first metadata
-            if (thisHost == UNKNOWN_HOST) {
+            if (thisHost.equals(UNKNOWN_HOST)) {
                 return allMetadata.get(0);
             }
             return myMetadata;
@@ -189,7 +189,7 @@ public class StreamsMetadataState {
         if (globalStores.contains(storeName)) {
             // global stores are on every node. if we dont' have the host info
             // for this host then just pick the first metadata
-            if (thisHost == UNKNOWN_HOST) {
+            if (thisHost.equals(UNKNOWN_HOST)) {
                 return allMetadata.get(0);
             }
             return myMetadata;