类 KafkaProperties
- java.lang.Object
- org.springframework.boot.autoconfigure.kafka.KafkaProperties
@ConfigurationProperties(prefix="spring.kafka") public class KafkaProperties extends Object
Configuration properties for Spring for Apache Kafka.Users should refer to Kafka documentation for complete descriptions of these properties.
- 从以下版本开始:
- 1.5.0
嵌套类概要
嵌套类 修饰符和类型 类 说明 static class
KafkaProperties.Admin
static class
KafkaProperties.Consumer
static class
KafkaProperties.Jaas
static class
KafkaProperties.Listener
static class
KafkaProperties.Producer
static class
KafkaProperties.Ssl
static class
KafkaProperties.Streams
High (and some medium) priority Streams properties and a general properties bucket.static class
KafkaProperties.Template
构造器概要
构造器 构造器 说明 KafkaProperties()
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 Map<String,Object>
buildAdminProperties()
Create an initial map of admin properties from the state of this instance.Map<String,Object>
buildConsumerProperties()
Create an initial map of consumer properties from the state of this instance.Map<String,Object>
buildProducerProperties()
Create an initial map of producer properties from the state of this instance.Map<String,Object>
buildStreamsProperties()
Create an initial map of streams properties from the state of this instance.KafkaProperties.Admin
getAdmin()
List<String>
getBootstrapServers()
String
getClientId()
KafkaProperties.Consumer
getConsumer()
KafkaProperties.Jaas
getJaas()
KafkaProperties.Listener
getListener()
KafkaProperties.Producer
getProducer()
Map<String,String>
getProperties()
KafkaProperties.Ssl
getSsl()
KafkaProperties.Streams
getStreams()
KafkaProperties.Template
getTemplate()
void
setBootstrapServers(List<String> bootstrapServers)
void
setClientId(String clientId)
构造器详细资料
KafkaProperties
public KafkaProperties()
方法详细资料
getBootstrapServers
public List<String> getBootstrapServers()
setBootstrapServers
public void setBootstrapServers(List<String> bootstrapServers)
getClientId
public String getClientId()
setClientId
public void setClientId(String clientId)
getProperties
public Map<String,String> getProperties()
getConsumer
public KafkaProperties.Consumer getConsumer()
getProducer
public KafkaProperties.Producer getProducer()
getListener
public KafkaProperties.Listener getListener()
getAdmin
public KafkaProperties.Admin getAdmin()
getStreams
public KafkaProperties.Streams getStreams()
getSsl
public KafkaProperties.Ssl getSsl()
getJaas
public KafkaProperties.Jaas getJaas()
getTemplate
public KafkaProperties.Template getTemplate()
buildConsumerProperties
public Map<String,Object> buildConsumerProperties()
Create an initial map of consumer properties from the state of this instance.This allows you to add additional properties, if necessary, and override the default kafkaConsumerFactory bean.
- 返回:
- the consumer properties initialized with the customizations defined on this instance
buildProducerProperties
public Map<String,Object> buildProducerProperties()
Create an initial map of producer properties from the state of this instance.This allows you to add additional properties, if necessary, and override the default kafkaProducerFactory bean.
- 返回:
- the producer properties initialized with the customizations defined on this instance
buildAdminProperties
public Map<String,Object> buildAdminProperties()
Create an initial map of admin properties from the state of this instance.This allows you to add additional properties, if necessary, and override the default kafkaAdmin bean.
- 返回:
- the admin properties initialized with the customizations defined on this instance
buildStreamsProperties
public Map<String,Object> buildStreamsProperties()
Create an initial map of streams properties from the state of this instance.This allows you to add additional properties, if necessary.
- 返回:
- the streams properties initialized with the customizations defined on this instance