AdminClientFactory represents the ability to create a
new Kafka AdminClient given AdminClientSettings. We
normally do not need a custom AdminClientFactory, but
it can be useful for testing purposes. If you can instead
have a custom trait or class with only the required parts
from KafkaAdminClient for testing, then prefer that.
AdminClientFactory represents the ability to create a new Kafka
AdminClient
given AdminClientSettings. We normally do not need a custom AdminClientFactory, but it can be useful for testing purposes. If you can instead have a custom trait or class with only the required parts from KafkaAdminClient for testing, then prefer that.To create a new AdminClientFactory, simply create a new instance and implement the create function with the desired behaviour. To use a custom instance, set it with AdminClientSettings#withAdminClientFactory.
AdminClientFactory#Default is the default instance, and it creates a default
AdminClient
instance from the provided AdminClientSettings.