@Test public void doNotTimeoutUsingFlux() { given(timeLimiter.getTimeLimiterConfig()) .willReturn(toConfig(Duration.ofMinutes(1))); Flux<?> flux = Flux.interval(Duration.ofMillis(1)) .take(2) .transformDeferred(TimeLimiterOperator.of(timeLimiter)); StepVerifier.create(flux) .expectNextCount(2) .verifyComplete(); then(timeLimiter).should(times(3)) .onSuccess(); }
public static <T> TimeLimiterOperator<T> of(TimeLimiter timeLimiter) { return new TimeLimiterOperator<>(timeLimiter); }
TimeLimiterOperator implements UnaryOperator<Publisher<T>> { public static <T> TimeLimiterOperator<T> of(TimeLimiter timeLimiter) { return new TimeLimiterOperator<>(timeLimiter); } }
TimeLimiterOperator implements UnaryOperator<Publisher<T>> { public static <T> TimeLimiterOperator<T> of(TimeLimiter timeLimiter) { return new TimeLimiterOperator<>(timeLimiter); } private  TimeLimiterOperator(TimeLimiter timeLimiter); }
TimeLimiterOperator implements UnaryOperator<Publisher<T>> { public static <T> TimeLimiterOperator<T> of(TimeLimiter timeLimiter) { return new TimeLimiterOperator<>(timeLimiter); } private  TimeLimiterOperator(TimeLimiter timeLimiter); static TimeLimiterOperator<T> of(TimeLimiter timeLimiter); @Override Publisher<T> apply(Publisher<T> publisher); }
TimeLimiterOperator implements UnaryOperator<Publisher<T>> { public static <T> TimeLimiterOperator<T> of(TimeLimiter timeLimiter) { return new TimeLimiterOperator<>(timeLimiter); } private  TimeLimiterOperator(TimeLimiter timeLimiter); static TimeLimiterOperator<T> of(TimeLimiter timeLimiter); @Override Publisher<T> apply(Publisher<T> publisher);  }