Class KafkaResourceFactory

java.lang.Object
org.springframework.kafka.core.KafkaResourceFactory
Direct Known Subclasses:
DefaultKafkaConsumerFactory, DefaultKafkaProducerFactory, KafkaAdmin

public abstract class KafkaResourceFactory extends Object
Base class for consumer/producer/admin creators.
Since:
2.5
Author:
Gary Russell
  • Constructor Details

    • KafkaResourceFactory

      public KafkaResourceFactory()
  • Method Details

    • getBootstrapServers

      @Nullable protected String getBootstrapServers()
    • setBootstrapServersSupplier

      public void setBootstrapServersSupplier(Supplier<String> bootstrapServersSupplier)
      Set a supplier for the bootstrap server list to override any configured in a subclass.
      Parameters:
      bootstrapServersSupplier - the supplier.
    • checkBootstrap

      protected void checkBootstrap(Map<String,Object> configs)
      Enhance the properties by calling the setBootstrapServersSupplier(Supplier) and replace the bootstrap servers properties.
      Parameters:
      configs - the configs.