reactor-core: DirectProcessor using ParallelFlux crashes with error "Queue is full?!"

Expected behavior

DirectProcessor using ParallelFlux should help us support high throughput and reliability. (We cannot require restart on fail).

Actual behavior

I’m getting the following exception after a while and i’m not sure what to do:

reactor.core.Exceptions$OverflowException: Queue is full?! at reactor.core.Exceptions.failWithOverflow(Exceptions.java:152) ~[reactor-core-3.0.7.RELEASE.jar:3.0.7.RELEASE] at reactor.core.publisher.ParallelSource$ParallelSourceMain.onNext(ParallelSource.java:231) ~[reactor-core-3.0.7.RELEASE.jar:3.0.7.RELEASE] at reactor.core.publisher.FluxFilter$FilterSubscriber.onNext(FluxFilter.java:96) ~[reactor-core-3.0.7.RELEASE.jar:3.0.7.RELEASE] at reactor.core.publisher.DirectProcessor$DirectInner.onNext(DirectProcessor.java:304) ~[reactor-core-3.0.7.RELEASE.jar:3.0

do i need to ‘release’ the queue at some point? what might be the cause for it to be full?

Steps to reproduce

Just tried to create several events (onNext) and i have 16 subscribers with filter. For example:

public void subscribe(eventRoute, Request flow) {
ParallelFlux<Request> parallelFlux = directProcessor.filter(flow -> flow.getPayload().getEventRoute().equals(eventRoute))
					.parallel()
					.log()
					.runOn(Schedulers.fromExecutor(excuterService));
parallelFlux.subcribe(() -> {do something with try and catch}
}

//In events call directProcessor.onNext(req);

This is super important for us, this happened in production environment right now…

Reactor Core version

3.0.7.RELEASE

JVM version (e.g. java -version)

1.8.0_121

OS version (e.g. uname -a)

MINGW64_NT-10.0 ADAMB-DELL 2.6.1(0.306/5/3) 2017-01-20 15:23 x86_64 Msys

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Comments: 20 (10 by maintainers)

Most upvoted comments

what @osi said 😄