-
Notifications
You must be signed in to change notification settings - Fork 43
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Reader set to MessageId.latest and inclusive start message does not work #193
Comments
The |
That seems incredibly unintuitive. If I say to someone "Hey, get me the latest message" I'd expect them to give me the latest message, not the first message produced after I asked. Be that as it may, how should I go about consuming the last message in a topic with the python client then? Right now I'm seeking to a day in the past and just reading everything until the final message, which is incredibly wasteful. |
@RobertIndie That doesn't seem right. The Go client explicitly handles the case where |
Yeah looks like the Java client also checks to see if its latest and inclusive, and then seeks explicitly to the last message: https://github.com/apache/pulsar/blob/176bdeacd309e8c1e49358987a1946abd30ba34a/pulsar-client/src/main/java/org/apache/pulsar/client/impl/ConsumerImpl.java#L2362 |
Thanks for all your information.
That makes sense to me. |
This issue is related to this C++ client issue: apache/pulsar-client-cpp#385. I have pushed a PR to fix it: apache/pulsar-client-cpp#386. Hopefully it will be released in the next feature release of the Python client. |
Fixes apache#199 Fixes apache#193 Upgraded the pulsar-client-cpp dependency to 3.5.0, which has the fixes for them. Then add relevant unit tests.
Hi team,
When using
start_message_id_inclusive
, we expect the message seeked to be returned. This is the case for thepulsar.MessageId.earliest
, but does not work withpulsar.MessageId.latest
.Reproduction
First, run a pulsar standalone instance:
Then, run this code:
The behaviour of the earliest reader is as expected. But the latest reader should not time out.
The text was updated successfully, but these errors were encountered: