[ 
https://issues.apache.org/jira/browse/KAFKA-9942?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Colin McCabe resolved KAFKA-9942.
---------------------------------
    Fix Version/s: 2.5.1
                   2.6.0
       Resolution: Fixed

> ConfigCommand fails to set client quotas for default users with 
> --bootstrap-server.
> -----------------------------------------------------------------------------------
>
>                 Key: KAFKA-9942
>                 URL: https://issues.apache.org/jira/browse/KAFKA-9942
>             Project: Kafka
>          Issue Type: Bug
>            Reporter: Cheng Tan
>            Assignee: Cheng Tan
>            Priority: Major
>             Fix For: 2.6.0, 2.5.1
>
>
> {quote}$ bin/kafka-configs.sh --bootstrap-server localhost:9092 --alter 
> --add-config producer_byte_rate=1000000000,consumer_byte_rate=1000000000 
> --entity-type clients --entity-default
> {quote}
> This usage of --entity-default with --bootstrap-server for alternating 
> configs will trigger the exception below. Similar for --describe
> {quote}/opt/kafka-dev/bin/kafka-configs.sh --bootstrap-server ducker04:9093 
> --describe --entity-type clients --entity-default --command-config 
> /opt/kafka-dev/bin/hi.properties
> {quote}
>  
> {quote}java.util.concurrent.ExecutionException: 
> org.apache.kafka.common.errors.UnknownServerException: Path must not end with 
> / character
> at 
> org.apache.kafka.common.internals.KafkaFutureImpl.wrapAndThrow(KafkaFutureImpl.java:45)
> at 
> org.apache.kafka.common.internals.KafkaFutureImpl.access$000(KafkaFutureImpl.java:32)
> at 
> org.apache.kafka.common.internals.KafkaFutureImpl$SingleWaiter.await(KafkaFutureImpl.java:104)
> at 
> org.apache.kafka.common.internals.KafkaFutureImpl.get(KafkaFutureImpl.java:272)
> at 
> kafka.admin.ConfigCommand$.getAllClientQuotasConfigs(ConfigCommand.scala:501)
> at kafka.admin.ConfigCommand$.getClientQuotasConfig(ConfigCommand.scala:487)
> at kafka.admin.ConfigCommand$.alterConfig(ConfigCommand.scala:361)
> at kafka.admin.ConfigCommand$.processCommand(ConfigCommand.scala:292)
> at kafka.admin.ConfigCommand$.main(ConfigCommand.scala:91)
> at kafka.admin.ConfigCommand.main(ConfigCommand.scala)
> Caused by: org.apache.kafka.common.errors.UnknownServerException: Path must 
> not end with / character
> {quote}
> However, if the --entity-type is brokers, the alternation works fine. 
> {quote}$ No exception, works properly
> bin/kafka-configs.sh --bootstrap-server localhost:9092 --entity-type brokers 
> --entity-default --alter --add-config unclean.leader.election.enable=true
> bin/kafka-configs.sh --bootstrap-server localhost:9092 --describe 
> --entity-type brokers --entity-default
> {quote}
>  
> Update:
>  
> For --describe:
> Commands work properly:
> {quote}bin/kafka-configs.sh --bootstrap-server localhost:9092 --describe 
> --entity-type brokers --entity-default
> bin/kafka-configs.sh --zookeeper localhost:2181 --describe --broker-defaults
> {quote}
> Commands do not work:
> {quote}bin/kafka-configs.sh --bootstrap-server localhost:9092 --describe 
> --entity-type topics --entity-default
> bin/kafka-configs.sh --bootstrap-server localhost:9092 --describe 
> --entity-type users --entity-default
> bin/kafka-configs.sh --bootstrap-server localhost:9092 --describe 
> --entity-type clients --entity-default
> bin/kafka-configs.sh --bootstrap-server localhost:9092 --describe 
> --client-defaults
> bin/kafka-configs.sh --bootstrap-server localhost:9092 --describe 
> --user-defaults
>  
> {quote}
>  
> For --alter:
> Commands work properly:
> {quote}bin/kafka-configs.sh --zookeeper localhost:2181 --alter --add-config 
> max.messages.bytes=128000 --entity-type topics --entity-default (an entity 
> name must be specified with --alter of topics)
> bin/kafka-configs.sh --bootstrap-server localhost:9092 --alter --add-config 
> unclean.leader.election.enable=true --entity-type brokers --entity-default
> {quote}
>  
> Commands do not work:
> {quote}bin/kafka-configs.sh --bootstrap-server localhost:9092 --alter 
> --add-config producer_byte_rate=1000000000,consumer_byte_rate=1000000000 
> --entity-type clients --entity-default
> bin/kafka-configs.sh --bootstrap-server localhost:9092 --alter --add-config 
> producer_byte_rate=44444 --entity-type users --entity-default (No exception 
> thrown but failed to add the config)
> bin/kafka-configs.sh --bootstrap-server localhost:9092 --alter --add-config 
> producer_byte_rate=1000000000,consumer_byte_rate=1000000000 --client-defaults
> bin/kafka-configs.sh --bootstrap-server localhost:9092 --alter --add-config 
> producer_byte_rate=44444 --user-defaults (No exception thrown but failed to 
> add the config)
>  
> {quote}
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to