You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2018/01/15 12:45:07 UTC

[GitHub] zhaijack opened a new pull request #1066: Issue 937: add CommandGetLastMessageId to make reader know the end of topic

zhaijack opened a new pull request #1066: Issue 937: add CommandGetLastMessageId to make reader know the end of topic
URL: https://github.com/apache/incubator-pulsar/pull/1066
 
 
   This is the first version to collect suggestion to achieve it.
   ### Motivation
   We have recently introduced the concept of topic "Reader" as an alternative to the traditional pub-sub consumer abstraction.
   
   A common followup request has been to have a way to identify when the reader has reached the last published entry on the topic.
   
   There is no currently direct way to achieve that and using readNext(timeout) doesn't help because in case the client is not connected to broker, it doesn't mean that there are no more messages to read.
   
   There are a few workaround that are not easy or desirable (eg: terminating the topic, or using HTTP admin API to check the backlog on the reader).
   Since this is a common theme, we should have a good way to handle this.
   
   ### Modifications
   - add CommandGetLastMessageId in PulsarApi.proto;
   - implementation CommandGetLastMessageId;
   - add a testcase in TopicReaderTest
   
   ### Result
   A new command CommandGetLastMessageId  added in binary protocol

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services