T - Type of data requestedpublic class AsyncBufferingSubscriber<T> extends Object implements org.reactivestreams.Subscriber<T>
Subscriber that execute the provided function for every event and limits the number of concurrent
function execution to the given maxConcurrentRequests| Constructor and Description |
|---|
AsyncBufferingSubscriber(Function<T,CompletableFuture<?>> consumer,
CompletableFuture<Void> returnFuture,
int maxConcurrentExecutions) |
| Modifier and Type | Method and Description |
|---|---|
int |
numRequestsInFlight() |
void |
onComplete() |
void |
onError(Throwable t) |
void |
onNext(T item) |
void |
onSubscribe(org.reactivestreams.Subscription subscription) |
public AsyncBufferingSubscriber(Function<T,CompletableFuture<?>> consumer, CompletableFuture<Void> returnFuture, int maxConcurrentExecutions)
public void onSubscribe(org.reactivestreams.Subscription subscription)
onSubscribe in interface org.reactivestreams.Subscriber<T>public void onNext(T item)
onNext in interface org.reactivestreams.Subscriber<T>public void onError(Throwable t)
onError in interface org.reactivestreams.Subscriber<T>public void onComplete()
onComplete in interface org.reactivestreams.Subscriber<T>public int numRequestsInFlight()
Copyright © 2023. All rights reserved.