mirror of https://github.com/apache/kafka.git
MINOR: Fix a startup NPE in BrokerServer (#10989)
Reviewers: Colin P. McCabe <cmccabe@apache.org>
This commit is contained in:
parent
862f814cc3
commit
61b6539517
|
@ -170,12 +170,13 @@ class BrokerServer(
|
|||
|
||||
logDirFailureChannel = new LogDirFailureChannel(config.logDirs.size)
|
||||
|
||||
metadataCache = MetadataCache.kRaftMetadataCache(config.nodeId)
|
||||
|
||||
// Create log manager, but don't start it because we need to delay any potential unclean shutdown log recovery
|
||||
// until we catch up on the metadata log and have up-to-date topic and broker configs.
|
||||
logManager = LogManager(config, initialOfflineDirs, metadataCache, kafkaScheduler, time,
|
||||
brokerTopicStats, logDirFailureChannel, keepPartitionMetadataFile = true)
|
||||
|
||||
metadataCache = MetadataCache.kRaftMetadataCache(config.nodeId)
|
||||
// Enable delegation token cache for all SCRAM mechanisms to simplify dynamic update.
|
||||
// This keeps the cache up-to-date if new SCRAM mechanisms are enabled dynamically.
|
||||
tokenCache = new DelegationTokenCache(ScramMechanism.mechanismNames)
|
||||
|
|
Loading…
Reference in New Issue