Yunyung commented on code in PR #19867:
URL: https://github.com/apache/kafka/pull/19867#discussion_r2119665968
##########
core/src/main/scala/kafka/server/ConfigHelper.scala:
##########
@@ -39,14 +39,30 @@ import org.apache.kafka.server.logger.LoggingController
import org.apache.kafka.server.metrics.ClientMetricsConfigs
import org.apache.kafka.storage.internals.log.LogConfig
+import java.util.stream.Collectors
import scala.collection.{Map, mutable}
import scala.jdk.CollectionConverters._
import scala.jdk.OptionConverters.RichOptional
+import java.util.{HashMap, HashSet, List => JList, Map => JMap}
class ConfigHelper(metadataCache: MetadataCache, config: KafkaConfig,
configRepository: ConfigRepository) extends Logging {
- def allConfigs(config: AbstractConfig): mutable.Map[String, Any] = {
- config.originals.asScala.filter(_._2 != null) ++
config.nonInternalValues.asScala
+ def allConfigs(config: AbstractConfig): JMap[String, Object] = {
Review Comment:
I prefer this way, and the same goes for `java.util.List`. For example, this
makes it easier to grep.
```suggestion
def allConfigs(config: AbstractConfig): java.util.Map[String, Object] = {
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]