Fix MathFlux operators with lifting and context propagation
Removed an inaccurate Fuseable marker from sum, average, min, and max operators whose shared subscriber already negotiates non-fused operation.
reactor/reactor-addons · #426
Reactive runtime fix
MathFlux aggregation no longer throws a ClassCastException when operator lifting and automatic context propagation are combined.
Problem
With tracing-style operator lifting and automatic context propagation enabled, downstream fuseable operators expected a QueueSubscription across a context-restoring wrapper that did not provide one. The reported Spring WebFlux endpoint returned HTTP 500.
Approach
Removes the marker from all affected math operators without changing MathFlux signatures or aggregation behavior. Because the shared MonoSubscriber already returns Fuseable.NONE, the change does not remove an active fusion optimization.
Impact and scope
- Restores MathFlux interoperability with common tracing and context-propagation instrumentation patterns.
- Covers sum, average, minimum, and maximum variants rather than repairing only the originally reported sumInt path.
- Preserves API signatures, aggregation semantics, demand, cancellation, and empty/error behavior.
Validation
- Regression coverage spans all 12 math families with selective lifting, downstream map/filter, deferred demand, empty/error sources, and cancellation.
- The original WebFlux reproducer changed from HTTP 500 to HTTP 200 with the expected result.
- Java 21 check and Javadoc plus Java 8 offline check passed with 305 tests; one existing SWT test remained disabled. GitHub checks, CodeQL, and DCO passed, and the verified merge commit credits Goutam Adwant.