Class PullConsumerImpl
- java.lang.Object
-
- com.aliyun.openservices.ons.client.rocketmq.impl.PullConsumerImpl
-
- All Implemented Interfaces:
Admin
,PullConsumer
public class PullConsumerImpl extends Object implements PullConsumer
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.aliyun.openservices.ons.api.PullConsumer
PullConsumer.TopicPartitionChangeListener
-
-
Constructor Summary
Constructors Constructor Description PullConsumerImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
assign(Collection<TopicPartition> topicPartitions)
void
commitSync()
Long
committed(TopicPartition topicPartition)
boolean
isClosed()
boolean
isStarted()
Long
offsetForTimestamp(TopicPartition topicPartition, Long timestamp)
void
pause(Collection<TopicPartition> topicPartitions)
List<Message>
poll(long timeout)
void
registerTopicPartitionChangedListener(String topic, PullConsumer.TopicPartitionChangeListener callback)
void
resume(Collection<TopicPartition> topicPartitions)
void
seek(TopicPartition topicPartition, long offset)
void
seekToBeginning(TopicPartition topicPartition)
void
seekToEnd(TopicPartition topicPartition)
void
shutdown()
void
start()
Set<TopicPartition>
topicPartitions(String topic)
void
updateCredential(Properties credentialProperties)
-
-
-
Method Detail
-
updateCredential
public void updateCredential(Properties credentialProperties)
- Specified by:
updateCredential
in interfaceAdmin
-
topicPartitions
public Set<TopicPartition> topicPartitions(String topic)
- Specified by:
topicPartitions
in interfacePullConsumer
-
assign
public void assign(Collection<TopicPartition> topicPartitions)
- Specified by:
assign
in interfacePullConsumer
-
registerTopicPartitionChangedListener
public void registerTopicPartitionChangedListener(String topic, PullConsumer.TopicPartitionChangeListener callback)
- Specified by:
registerTopicPartitionChangedListener
in interfacePullConsumer
-
poll
public List<Message> poll(long timeout)
- Specified by:
poll
in interfacePullConsumer
-
seek
public void seek(TopicPartition topicPartition, long offset)
- Specified by:
seek
in interfacePullConsumer
-
seekToBeginning
public void seekToBeginning(TopicPartition topicPartition)
- Specified by:
seekToBeginning
in interfacePullConsumer
-
seekToEnd
public void seekToEnd(TopicPartition topicPartition)
- Specified by:
seekToEnd
in interfacePullConsumer
-
pause
public void pause(Collection<TopicPartition> topicPartitions)
- Specified by:
pause
in interfacePullConsumer
-
resume
public void resume(Collection<TopicPartition> topicPartitions)
- Specified by:
resume
in interfacePullConsumer
-
offsetForTimestamp
public Long offsetForTimestamp(TopicPartition topicPartition, Long timestamp)
- Specified by:
offsetForTimestamp
in interfacePullConsumer
-
committed
public Long committed(TopicPartition topicPartition)
- Specified by:
committed
in interfacePullConsumer
-
commitSync
public void commitSync()
- Specified by:
commitSync
in interfacePullConsumer
-
-