You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kafka.apache.org by gu...@apache.org on 2020/06/02 16:49:44 UTC

[kafka] branch 2.4 updated: MINOR: Remove unused variable to fix spotBugs failure (#8779)

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

guozhang 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 86c4dae  MINOR: Remove unused variable to fix spotBugs failure (#8779)
86c4dae is described below

commit 86c4dae1327e80b0c7917127a98f1e8ddbf1bbcb
Author: Nikolay <ni...@apache.org>
AuthorDate: Tue Jun 2 18:59:56 2020 +0300

    MINOR: Remove unused variable to fix spotBugs failure (#8779)
    
    Fixed spotBugs error introduced by c6633a1:
    
    >Dead store to isFreshAssignment in org.apache.kafka.clients.consumer.internals.AbstractStickyAssignor.generalAssign(Map, Map)
    
    Reviewers: Ismael Juma <is...@juma.me.uk>
---
 .../apache/kafka/clients/consumer/internals/AbstractStickyAssignor.java  | 1 -
 1 file changed, 1 deletion(-)

diff --git a/clients/src/main/java/org/apache/kafka/clients/consumer/internals/AbstractStickyAssignor.java b/clients/src/main/java/org/apache/kafka/clients/consumer/internals/AbstractStickyAssignor.java
index d4e023c..353a225 100644
--- a/clients/src/main/java/org/apache/kafka/clients/consumer/internals/AbstractStickyAssignor.java
+++ b/clients/src/main/java/org/apache/kafka/clients/consumer/internals/AbstractStickyAssignor.java
@@ -274,7 +274,6 @@ public abstract class AbstractStickyAssignor extends AbstractPartitionAssignor {
         Map<TopicPartition, ConsumerGenerationPair> prevAssignment = new HashMap<>();
 
         prepopulateCurrentAssignments(subscriptions, currentAssignment, prevAssignment);
-        boolean isFreshAssignment = currentAssignment.isEmpty();
 
         // a mapping of all topic partitions to all consumers that can be assigned to them
         final Map<TopicPartition, List<String>> partition2AllPotentialConsumers = new HashMap<>();