Skip to content

Controlling request demand with subscriber #1058

Answered by jponge
cottoncammy asked this question in Q&A
Discussion options

You must be logged in to vote

You can easily create your own subscriber implementation.
I do not recomment using AssertSubscriber outside tests.

onSubscribe will be called when a subscription is given to you, and from here you will be able to request elements when it's appropriate to do so.

You might look at an example like https://github.com/smallrye/smallrye-mutiny-zero/blob/main/mutiny-zero-vertx-publishers/src/test/java/docsamples/UrbanObservatoryHttpClient.java

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@cottoncammy
Comment options

Answer selected by cottoncammy
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants