!str #19005 make groupBy et al return a SubFlow
A SubFlow (or SubSource) is not a Graph, it is an unfinished builder that accepts transformations. This allows us to capture the substreams’ transformations before materializing the flow, which will be very helpful in fully fusing all operators. Another change is that groupBy now requires a maxSubstreams parameter in order to bound its resource usage. In exchange the matching merge can be unbounded. This trades silent deadlock for explicit stream failure. This commit also changes all uses of Predef.identity to use `conforms` and removes the HTTP impl.util.identityFunc.
This commit is contained in:
parent
654fa41443
commit
1500d1f36d
56 changed files with 3484 additions and 720 deletions
|
|
@ -42,7 +42,7 @@ object TestPublisher {
|
|||
}
|
||||
|
||||
/**
|
||||
* Publisher that signals error to subscribers immediately, before handing out subscription.
|
||||
* Publisher that signals error to subscribers immediately after handing out subscription.
|
||||
*/
|
||||
def error[T](cause: Throwable): Publisher[T] = ErrorPublisher(cause, "error").asInstanceOf[Publisher[T]]
|
||||
|
||||
|
|
@ -251,7 +251,10 @@ object TestSubscriber {
|
|||
/**
|
||||
* Expect and return a stream element.
|
||||
*/
|
||||
def expectNext(): I = probe.expectMsgType[OnNext[I]].element
|
||||
def expectNext(): I = probe.receiveOne(probe.remaining) match {
|
||||
case OnNext(elem) ⇒ elem.asInstanceOf[I]
|
||||
case other ⇒ throw new AssertionError("expected OnNext, found " + other)
|
||||
}
|
||||
|
||||
/**
|
||||
* Fluent DSL
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue