|
Spring Integration Kafka Support | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.springframework.integration.kafka.core.DefaultConnectionFactory
public class DefaultConnectionFactory
Default implementation of ConnectionFactory
| Field Summary | |
|---|---|
static com.gs.collections.api.block.predicate.Predicate<kafka.javaapi.TopicMetadata> |
errorlessTopicMetadataPredicate
|
| Constructor Summary | |
|---|---|
DefaultConnectionFactory(Configuration configuration)
|
|
| Method Summary | |
|---|---|
void |
afterPropertiesSet()
|
Connection |
connect(BrokerAddress brokerAddress)
Create a connection to a Kafka broker, caching it internally |
void |
destroy()
|
Configuration |
getConfiguration()
|
BrokerAddress |
getLeader(Partition partition)
Return the leader for a single partition |
java.util.Map<Partition,BrokerAddress> |
getLeaders(java.lang.Iterable<Partition> partitions)
Retrieve the leaders for a set of partitions. |
java.util.Collection<Partition> |
getPartitions(java.lang.String topic)
Retrieves the partitions of a given topic |
void |
refreshMetadata(java.util.Collection<java.lang.String> topics)
Refresh the cached metadata (i.e. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final com.gs.collections.api.block.predicate.Predicate<kafka.javaapi.TopicMetadata> errorlessTopicMetadataPredicate
| Constructor Detail |
|---|
public DefaultConnectionFactory(Configuration configuration)
| Method Detail |
|---|
public Configuration getConfiguration()
public void afterPropertiesSet()
throws java.lang.Exception
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBeanjava.lang.Exception
public void destroy()
throws java.lang.Exception
destroy in interface org.springframework.beans.factory.DisposableBeanjava.lang.Exceptionpublic java.util.Map<Partition,BrokerAddress> getLeaders(java.lang.Iterable<Partition> partitions)
ConnectionFactory
getLeaders in interface ConnectionFactorypartitions - whose leaders are queried
ConnectionFactory.getLeaders(Iterable)public BrokerAddress getLeader(Partition partition)
ConnectionFactory
getLeader in interface ConnectionFactorypartition - the partition whose leader is queried
ConnectionFactory.getLeader(Partition)public Connection connect(BrokerAddress brokerAddress)
ConnectionFactory
connect in interface ConnectionFactorybrokerAddress - a broker address
ConnectionFactory.connect(BrokerAddress)public void refreshMetadata(java.util.Collection<java.lang.String> topics)
ConnectionFactory
refreshMetadata in interface ConnectionFactorytopics - the topics for which to refresh the leadersConnectionFactory.refreshMetadata(Collection)public java.util.Collection<Partition> getPartitions(java.lang.String topic)
ConnectionFactory
getPartitions in interface ConnectionFactorytopic - the topic to query for
ConnectionFactory.getPartitions(String)
|
Spring Integration Kafka Support | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||