Skip to content
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

Document ReactiveMessageSenderBuilder#maxInflight details #38

Open
lhotari opened this issue Nov 28, 2022 · 0 comments
Open

Document ReactiveMessageSenderBuilder#maxInflight details #38

lhotari opened this issue Nov 28, 2022 · 0 comments

Comments

@lhotari
Copy link
Member

lhotari commented Nov 28, 2022

Related to https://github.com/apache/pulsar-client-reactive/pull/28/files#r1033276692

The way the backpressure solution works is that InflightLimiter will never create more demand with ReactiveStreams subscription requests than the configured limit.

This is a bit hard to understand in practice because of the way how ReactiveStreams model works. It's a pull-push model where the "pull" is created with subscription requests. The backpressure is handled by limiting the amount of upstream requests. Subscribing to upstream publishers that are creating messages to send will also be postponed when limits are exceeded.

Adding unit tests and documentation to the underlying InflightLimiter would clarify the details and ensure that there aren't uncovered gaps in the solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant