Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-10140

Incremental config api excludes plugin config changes

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Reopened
    • Priority: Critical
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      I was trying to alter the jmx metric filters using the incremental alter config api and hit this error:
      ```
      java.util.NoSuchElementException: key not found: metrics.jmx.blacklist
      at scala.collection.MapLike.default(MapLike.scala:235)
      at scala.collection.MapLike.default$(MapLike.scala:234)
      at scala.collection.AbstractMap.default(Map.scala:65)
      at scala.collection.MapLike.apply(MapLike.scala:144)
      at scala.collection.MapLike.apply$(MapLike.scala:143)
      at scala.collection.AbstractMap.apply(Map.scala:65)
      at kafka.server.AdminManager.listType$1(AdminManager.scala:681)
      at kafka.server.AdminManager.$anonfun$prepareIncrementalConfigs$1(AdminManager.scala:693)
      at kafka.server.AdminManager.prepareIncrementalConfigs(AdminManager.scala:687)
      at kafka.server.AdminManager.$anonfun$incrementalAlterConfigs$1(AdminManager.scala:618)
      at scala.collection.TraversableLike.$anonfun$map$1(TraversableLike.scala:273)
      at scala.collection.immutable.Map$Map1.foreach(Map.scala:154)
      at scala.collection.TraversableLike.map(TraversableLike.scala:273)
      at scala.collection.TraversableLike.map$(TraversableLike.scala:266)
      at scala.collection.AbstractTraversable.map(Traversable.scala:108)
      at kafka.server.AdminManager.incrementalAlterConfigs(AdminManager.scala:589)
      at kafka.server.KafkaApis.handleIncrementalAlterConfigsRequest(KafkaApis.scala:2698)
      at kafka.server.KafkaApis.handle(KafkaApis.scala:188)
      at kafka.server.KafkaRequestHandler.run(KafkaRequestHandler.scala:78)
      at java.base/java.lang.Thread.run(Thread.java:834)
      ```

      It looks like we are only allowing changes to the keys defined in `KafkaConfig` through this API. This excludes config changes to any plugin components such as `JmxReporter`.

      Note that I was able to use the regular `alterConfig` API to change this config.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              hachikuji Jason Gustafson
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated: