@@ -22,7 +22,7 @@ import java.util.concurrent.TimeUnit
22
22
import java .util .{Collections , Properties }
23
23
import joptsimple ._
24
24
import kafka .server .DynamicConfig .QuotaConfigs
25
- import kafka .server .{ConfigEntityName , Defaults , DynamicBrokerConfig , DynamicConfig , KafkaConfig }
25
+ import kafka .server .{Defaults , DynamicBrokerConfig , DynamicConfig , KafkaConfig }
26
26
import kafka .utils .{Exit , Logging , PasswordEncoder }
27
27
import kafka .utils .Implicits ._
28
28
import kafka .zk .{AdminZkClient , KafkaZkClient }
@@ -35,7 +35,7 @@ import org.apache.kafka.common.quota.{ClientQuotaAlteration, ClientQuotaEntity,
35
35
import org .apache .kafka .common .security .JaasUtils
36
36
import org .apache .kafka .common .security .scram .internals .{ScramCredentialUtils , ScramFormatter , ScramMechanism }
37
37
import org .apache .kafka .common .utils .{Sanitizer , Time , Utils }
38
- import org .apache .kafka .server .config .ConfigType
38
+ import org .apache .kafka .server .config .{ ConfigEntityName , ConfigType }
39
39
import org .apache .kafka .server .util .{CommandDefaultOptions , CommandLineUtils }
40
40
import org .apache .kafka .storage .internals .log .LogConfig
41
41
import org .apache .zookeeper .client .ZKClientConfig
@@ -152,7 +152,7 @@ object ConfigCommand extends Logging {
152
152
if (! configsToBeAdded.isEmpty || configsToBeDeleted.nonEmpty) {
153
153
validateBrokersNotRunning(entityName, adminZkClient, zkClient, errorMessage)
154
154
155
- val perBrokerConfig = entityName != ConfigEntityName .Default
155
+ val perBrokerConfig = entityName != ConfigEntityName .DEFAULT
156
156
preProcessBrokerConfigs(configsToBeAdded, perBrokerConfig)
157
157
}
158
158
}
@@ -177,7 +177,7 @@ object ConfigCommand extends Logging {
177
177
adminZkClient : AdminZkClient ,
178
178
zkClient : KafkaZkClient ,
179
179
errorMessage : String ): Unit = {
180
- val perBrokerConfig = entityName != ConfigEntityName .Default
180
+ val perBrokerConfig = entityName != ConfigEntityName .DEFAULT
181
181
val info = " Broker configuration operations using ZooKeeper are only supported if the affected broker(s) are not running."
182
182
if (perBrokerConfig) {
183
183
adminZkClient.parseBroker(entityName).foreach { brokerId =>
@@ -696,7 +696,7 @@ object ConfigCommand extends Logging {
696
696
case t => t
697
697
}
698
698
sanitizedName match {
699
- case Some (ConfigEntityName .Default ) => " default " + typeName
699
+ case Some (ConfigEntityName .DEFAULT ) => " default " + typeName
700
700
case Some (n) =>
701
701
val desanitized = if (entityType == ConfigType .USER || entityType == ConfigType .CLIENT ) Sanitizer .desanitize(n) else n
702
702
s " $typeName ' $desanitized' "
@@ -757,7 +757,7 @@ object ConfigCommand extends Logging {
757
757
else {
758
758
// Exactly one entity type and at-most one entity name expected for other entities
759
759
val name = entityNames.headOption match {
760
- case Some (" " ) => Some (ConfigEntityName .Default )
760
+ case Some (" " ) => Some (ConfigEntityName .DEFAULT )
761
761
case v => v
762
762
}
763
763
ConfigEntity (Entity (entityTypes.head, name), None )
@@ -774,7 +774,7 @@ object ConfigCommand extends Logging {
774
774
775
775
def sanitizeName (entityType : String , name : String ) = {
776
776
if (name.isEmpty)
777
- ConfigEntityName .Default
777
+ ConfigEntityName .DEFAULT
778
778
else {
779
779
entityType match {
780
780
case ConfigType .USER | ConfigType .CLIENT => Sanitizer .sanitize(name)
0 commit comments