Replace reference to deprecated API (#29381)

Updated stream-composition.md to use Flow.fromSinkAndSourceCoupledMat or Flow.fromSinkAndSourceCoupled rather than the deprecated CoupledTerminationFlow.fromSinkAndSource.
This commit is contained in:
davidlzs 2020-07-14 00:48:33 -06:00 committed by GitHub
parent 68fa87c58c
commit 9739e6f44d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -54,8 +54,8 @@ parameters.
Please note that when combining a `Flow` using that method, the termination signals are not carried
"through" as the `Sink` and `Source` are assumed to be fully independent. If however you want to construct
a `Flow` like this but need the termination events to trigger "the other side" of the composite flow, you can use
`CoupledTerminationFlow.fromSinkAndSource` which does just that. For example the cancelation of the composite flows
source-side will then lead to completion of its sink-side. Read `CoupledTerminationFlow`'s scaladoc for a
`Flow.fromSinkAndSourceCoupled` or `Flow.fromSinkAndSourceCoupledMat` which does just that. For example the cancelation of the composite flows
source-side will then lead to completion of its sink-side. Read @apidoc[Flow]'s API documentation for a
detailed explanation how this works.
The example `BidiFlow` demonstrates that internally a module can be of arbitrary complexity, and the exposed