KafkaConfig

KafkaConfig is the configuration of a Kafka broker and the services.

KafkaConfig is created when:

Table 1. KafkaConfig’s Configuration Values
Value Kafka Property

advertisedListeners

Used when:

authorizerClassName

Used exclusively for KafkaServer

autoCreateTopicsEnable

autoLeaderRebalanceEnable

Used exclusively when KafkaController is requested to onControllerFailover

backgroundThreads

brokerId

brokerIdGenerationEnable

Used exclusively when KafkaServer is requested to getBrokerIdAndOfflineDirs

connectionsMaxIdleMs

Used when:

deleteTopicEnable

delete.topic.enable

failedAuthenticationDelayMs

Used exclusively when SocketServer is requested to create a new network processor thread

hostName

host.name

interBrokerListenerName

interBrokerProtocolVersion

interBrokerSecurityProtocol

leaderImbalanceCheckIntervalSeconds

Used exclusively when KafkaController is requested to processAutoPreferredReplicaLeaderElection

leaderImbalancePerBrokerPercentage

Used exclusively when KafkaController is requested to checkAndTriggerAutoLeaderRebalance

listeners

listenerSecurityProtocolMap

logCleanerThreads

logCleanerDedupeBufferSize

logCleanerDedupeBufferLoadFactor

logCleanerIoBufferSize

logCleanerIoMaxBytesPerSecond

logCleanerBackoffMs

logCleanerEnable

logDirs

At least one log directory must be defined via log.dirs or log.dir properties.

Used when:

logIndexSizeMaxBytes

maxConnectionsPerIp

Used exclusively when SocketServer is requested to start up

maxConnectionsPerIpOverrides

Used exclusively when SocketServer is requested to start up

maxReservedBrokerId

Used exclusively when KafkaServer is requested to generateBrokerId

messageMaxBytes

numIoThreads

numNetworkThreads

numRecoveryThreadsPerDataDir

Used exclusively when LogManager is created

numReplicaFetchers

port

port

PrincipalBuilderClassProp

replicaLagTimeMaxMs

replicaFetchBackoffMs

SaslMechanismInterBrokerProtocolProp

SaslJaasConfigProp

SaslEnabledMechanismsProp

SaslKerberosServiceNameProp

SaslKerberosKinitCmdProp

SaslKerberosTicketRenewWindowFactorProp

SaslKerberosTicketRenewJitterProp

SaslKerberosMinTimeBeforeReloginProp

SaslKerberosPrincipalToLocalRulesProp

SaslLoginRefreshWindowFactorProp

SaslLoginRefreshWindowJitterProp

SaslLoginRefreshMinPeriodSecondsProp

SaslLoginRefreshBufferSecondsProp

SslProtocolProp

SslProviderProp

SslCipherSuitesProp

SslEnabledProtocolsProp

SslKeystoreTypeProp

SslKeystoreLocationProp

SslKeystorePasswordProp

SslKeyPasswordProp

SslTruststoreTypeProp

SslTruststoreLocationProp

SslTruststorePasswordProp

SslKeyManagerAlgorithmProp

SslTrustManagerAlgorithmProp

SslEndpointIdentificationAlgorithmProp

SslSecureRandomImplementationProp

SslClientAuthProp

socketRequestMaxBytes

Used when SocketServer is created and requested to create a new network processor thread

tokenAuthEnabled

transactionMaxTimeoutMs

Used exclusively when TransactionCoordinator is created

queuedMaxRequests

Used exclusively when SocketServer is created

zkConnect

Used when:

zkConnectionTimeoutMs

Used when:

zkEnableSecureAcls

Used when:

zkMaxInFlightRequests

Used when:

zkSessionTimeoutMs

Used when:

Table 2. KafkaConfig’s Internal Properties (e.g. Registries, Counters and Flags)
Name Description

dynamicConfig

Used when:

Creating Listeners — getListeners Internal Method

getListeners: Seq[EndPoint]

getListeners creates the EndPoints if defined using listeners Kafka property or defaults to PLAINTEXT://[hostName]:[port] (for hostName and port Kafka properties).

Note
getListeners is used when KafkaConfig is created and for getAdvertisedListeners.

getNumReplicaAlterLogDirsThreads Method

getNumReplicaAlterLogDirsThreads: Int

getNumReplicaAlterLogDirsThreads…​FIXME

Note
getNumReplicaAlterLogDirsThreads is used when…​FIXME

Creating KafkaConfig Instance

KafkaConfig takes the following when created:

KafkaConfig initializes the internal registries and counters.

Creating KafkaConfig From Java Properties — fromProps Object Method

fromProps(props: Properties): KafkaConfig (1)
fromProps(props: Properties, doLog: Boolean): KafkaConfig
fromProps(defaults: Properties, overrides: Properties): KafkaConfig (2)
fromProps(defaults: Properties, overrides: Properties, doLog: Boolean): KafkaConfig (3)
  1. Seems to be used in tests only

  2. Seems to be used in tests only

  3. Seems to be used in tests only

fromProps…​FIXME

Note

fromProps is used when:

Creating KafkaConfig — apply Factory Method

apply(props: java.util.Map[_, _]): KafkaConfig

apply simply creates a KafkaConfig with the props and the doLog flag on.

Note
apply seems to be used in tests only.

addReconfigurable Method

addReconfigurable(reconfigurable: Reconfigurable): Unit

addReconfigurable…​FIXME

Note
addReconfigurable is used when…​FIXME

validateValues Internal Method

validateValues(): Unit

validateValues…​FIXME

Note
validateValues is used when…​FIXME

getInterBrokerListenerNameAndSecurityProtocol Internal Method

getInterBrokerListenerNameAndSecurityProtocol: (ListenerName, SecurityProtocol)

getInterBrokerListenerNameAndSecurityProtocol…​FIXME

Note
getInterBrokerListenerNameAndSecurityProtocol is used when KafkaConfig is requested for interBrokerListenerName and interBrokerSecurityProtocol.

results matching ""

    No results matching ""