[ 
https://issues.apache.org/jira/browse/KAFKA-17094?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17864662#comment-17864662
 ] 

Mickael Maison commented on KAFKA-17094:
----------------------------------------

It seems we explicitly remove inactive observers when describing the Quorum: 
[https://github.com/apache/kafka/blob/trunk/raft/src/main/java/org/apache/kafka/raft/LeaderState.java#L469]

Unfortunately the observers field does not have a docstring associated so its 
expected value is not clearly defined: 
[https://github.com/apache/kafka/blob/trunk/clients/src/main/resources/common/message/DescribeQuorumResponse.json#L46]

We need a way to retrieve all registered observers. So either we include 
inactive observers or we need to change the response schema.

> Make it possible to list registered KRaft nodes in order to know which nodes 
> should be unregistered
> ---------------------------------------------------------------------------------------------------
>
>                 Key: KAFKA-17094
>                 URL: https://issues.apache.org/jira/browse/KAFKA-17094
>             Project: Kafka
>          Issue Type: Bug
>    Affects Versions: 3.7.1
>            Reporter: Jakub Scholz
>            Priority: Major
>
> Kafka seems to require nodes that are removed from the cluster to be 
> unregistered using the Kafka Admin API. If they are unregistred, that you 
> might run into problems later. For example, after upgrade when you try to 
> bump the KRaft metadata version, you might get an error like this:
>  
> {code:java}
> g.apache.kafka.common.errors.InvalidUpdateVersionException: Invalid update 
> version 19 for feature metadata.version. Broker 3002 only supports versions 
> 1-14 {code}
> In this case, 3002 is an old node that was removed before the upgrade and 
> doesn't support the KRaft metadata version 19 and blocks the metadata update.
>  
> However, it seems to be impossible to list the registered nodes in order to 
> unregister them:
>  * The describe cluster metadata request in the Admin API seems to return 
> only the IDs of running brokers
>  * The describe metadata quorum command seems to list the removed nodes in 
> the list of observers. But it does so only until the controller nodes are 
> restarted.
> If Kafka expects the inactive nodes to be registered, it should provide a 
> list of the registered nodes so that it can be checked what nodes to 
> unregister.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to