public class ZeroQueueConsumerImpl<T> extends ConsumerImpl<T>
ConsumerBase.OpBatchReceive<T>| Modifier and Type | Field and Description |
|---|---|
protected PulsarClientImpl |
client |
protected String |
topic |
lastDequeuedMessage, paused, statsbatchReceivePolicy, batchReceiveTimeout, conf, consumerEventListener, consumerName, INCOMING_MESSAGES_SIZE_UPDATER, incomingMessagesSize, interceptors, listener, listenerExecutor, maxReceiverQueueSize, pendingBatchReceives, pendingReceives, schema, subscribeFuture, subscription| Constructor and Description |
|---|
ZeroQueueConsumerImpl(PulsarClientImpl client,
String topic,
ConsumerConfigurationData<T> conf,
ExecutorService listenerExecutor,
int partitionIndex,
boolean hasParentConsumer,
CompletableFuture<Consumer<T>> subscribeFuture,
org.apache.pulsar.client.impl.ConsumerImpl.SubscriptionMode subscriptionMode,
MessageId startMessageId,
Schema<T> schema,
ConsumerInterceptors<T> interceptors,
boolean createTopicIfDoesNotExist) |
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
canEnqueueMessage(Message<T> message) |
protected boolean |
changeToReadyState() |
protected boolean |
changeToRegisteringSchemaState() |
protected void |
consumerIsReconnectedToBroker(ClientCnx cnx,
int currentQueueSize) |
protected org.apache.pulsar.client.impl.HandlerState.State |
getAndUpdateState(UnaryOperator<org.apache.pulsar.client.impl.HandlerState.State> updater) |
PulsarClientImpl |
getClient() |
protected org.apache.pulsar.client.impl.HandlerState.State |
getState() |
protected Message<T> |
internalReceive() |
protected CompletableFuture<Message<T>> |
internalReceiveAsync() |
protected void |
setState(org.apache.pulsar.client.impl.HandlerState.State s) |
protected void |
triggerListener(int numMessages) |
closeAsync, completeOpBatchReceive, connectionFailed, connectionOpened, doAcknowledge, getAvailablePermits, getClientCnx, getConnectionHandler, getLastMessageIdAsync, getStats, getTopicNameWithoutPartition, getUnAckedMessageTracker, hashCode, hasMessageAvailable, hasMessageAvailableAsync, hasReachedEndOfTopic, internalBatchReceive, internalBatchReceiveAsync, internalReceive, isConnected, messageProcessed, negativeAcknowledge, numMessagesInQueue, pause, redeliverUnacknowledgedMessages, redeliverUnacknowledgedMessages, resume, seek, seek, seekAsync, seekAsync, trackMessage, unsubscribeAsyncacknowledge, acknowledge, acknowledge, acknowledgeAsync, acknowledgeAsync, acknowledgeAsync, acknowledgeAsync, acknowledgeCumulative, acknowledgeCumulative, acknowledgeCumulativeAsync, acknowledgeCumulativeAsync, acknowledgeCumulativeAsync, batchReceive, batchReceiveAsync, beforeConsume, close, doAcknowledgeWithTxn, enqueueMessageAndCheckBatchReceive, getConsumerName, getLastMessageId, getNewMessagesImpl, getSubscription, getSubType, getTopic, hasEnoughMessagesForBatchReceive, hasPendingBatchReceive, negativeAcknowledge, negativeAcknowledge, notifyPendingBatchReceivedCallBack, notifyPendingBatchReceivedCallBack, onAcknowledge, onAcknowledgeCumulative, onAckTimeoutSend, onNegativeAcksSend, receive, receive, receiveAsync, run, setMaxReceiverQueueSize, subscribeFuture, toString, unsubscribeprotected final PulsarClientImpl client
protected final String topic
public ZeroQueueConsumerImpl(PulsarClientImpl client, String topic, ConsumerConfigurationData<T> conf, ExecutorService listenerExecutor, int partitionIndex, boolean hasParentConsumer, CompletableFuture<Consumer<T>> subscribeFuture, org.apache.pulsar.client.impl.ConsumerImpl.SubscriptionMode subscriptionMode, MessageId startMessageId, Schema<T> schema, ConsumerInterceptors<T> interceptors, boolean createTopicIfDoesNotExist)
protected Message<T> internalReceive() throws PulsarClientException
internalReceive in class ConsumerImpl<T>PulsarClientExceptionprotected CompletableFuture<Message<T>> internalReceiveAsync()
internalReceiveAsync in class ConsumerImpl<T>protected void consumerIsReconnectedToBroker(ClientCnx cnx, int currentQueueSize)
consumerIsReconnectedToBroker in class ConsumerImpl<T>protected boolean canEnqueueMessage(Message<T> message)
canEnqueueMessage in class ConsumerBase<T>protected void triggerListener(int numMessages)
triggerListener in class ConsumerImpl<T>protected boolean changeToReadyState()
protected boolean changeToRegisteringSchemaState()
protected org.apache.pulsar.client.impl.HandlerState.State getState()
protected void setState(org.apache.pulsar.client.impl.HandlerState.State s)
protected org.apache.pulsar.client.impl.HandlerState.State getAndUpdateState(UnaryOperator<org.apache.pulsar.client.impl.HandlerState.State> updater)
public PulsarClientImpl getClient()
Copyright © 2017–2020 Apache Software Foundation. All rights reserved.