You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pekko.apache.org by he...@apache.org on 2024/02/29 05:11:16 UTC
(incubator-pekko) branch main updated: chore: Remove the deprecation of statefulMapConcat operator. (#1147)
This is an automated email from the ASF dual-hosted git repository.
hepin pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-pekko.git
The following commit(s) were added to refs/heads/main by this push:
new c8a99aa590 chore: Remove the deprecation of statefulMapConcat operator. (#1147)
c8a99aa590 is described below
commit c8a99aa590e0c0a718397c3d707068960167b678
Author: He-Pin(kerr) <he...@gmail.com>
AuthorDate: Thu Feb 29 13:11:11 2024 +0800
chore: Remove the deprecation of statefulMapConcat operator. (#1147)
---
.../main/paradox/stream/operators/Source-or-Flow/statefulMapConcat.md | 2 +-
stream/src/main/scala/org/apache/pekko/stream/javadsl/Flow.scala | 1 -
stream/src/main/scala/org/apache/pekko/stream/javadsl/Source.scala | 1 -
stream/src/main/scala/org/apache/pekko/stream/javadsl/SubFlow.scala | 1 -
stream/src/main/scala/org/apache/pekko/stream/javadsl/SubSource.scala | 1 -
stream/src/main/scala/org/apache/pekko/stream/scaladsl/Flow.scala | 1 -
6 files changed, 1 insertion(+), 6 deletions(-)
diff --git a/docs/src/main/paradox/stream/operators/Source-or-Flow/statefulMapConcat.md b/docs/src/main/paradox/stream/operators/Source-or-Flow/statefulMapConcat.md
index 3315fe9d5a..20185d480c 100644
--- a/docs/src/main/paradox/stream/operators/Source-or-Flow/statefulMapConcat.md
+++ b/docs/src/main/paradox/stream/operators/Source-or-Flow/statefulMapConcat.md
@@ -6,7 +6,7 @@ Transform each element into zero or more elements that are individually passed d
@@@ warning
-The `statefulMapConcat` operator has been deprecated.
+The `statefulMapConcat` operator doesn't handle upstream's completion signal since the state kept in the closure can be lost.
- for stateful mapping, use @ref:[statefulMap](./statefulMap.md)
- for stateful map concat, use @ref:[statefulMap](./statefulMap.md) with @ref:[mapConcat](./mapConcat.md).
diff --git a/stream/src/main/scala/org/apache/pekko/stream/javadsl/Flow.scala b/stream/src/main/scala/org/apache/pekko/stream/javadsl/Flow.scala
index 3ed9bdf150..e4bb2eb476 100755
--- a/stream/src/main/scala/org/apache/pekko/stream/javadsl/Flow.scala
+++ b/stream/src/main/scala/org/apache/pekko/stream/javadsl/Flow.scala
@@ -896,7 +896,6 @@ final class Flow[In, Out, Mat](delegate: scaladsl.Flow[In, Out, Mat]) extends Gr
*
* '''Cancels when''' downstream cancels
*/
- @deprecated("Use `statefulMap` with `mapConcat` instead.", "1.0.2")
def statefulMapConcat[T](
f: function.Creator[function.Function[Out, java.lang.Iterable[T]]]): javadsl.Flow[In, T, Mat] =
new Flow(delegate.statefulMapConcat { () =>
diff --git a/stream/src/main/scala/org/apache/pekko/stream/javadsl/Source.scala b/stream/src/main/scala/org/apache/pekko/stream/javadsl/Source.scala
index b8d521a420..c4b44f6c1b 100755
--- a/stream/src/main/scala/org/apache/pekko/stream/javadsl/Source.scala
+++ b/stream/src/main/scala/org/apache/pekko/stream/javadsl/Source.scala
@@ -2609,7 +2609,6 @@ final class Source[Out, Mat](delegate: scaladsl.Source[Out, Mat]) extends Graph[
*
* '''Cancels when''' downstream cancels
*/
- @deprecated("Use `statefulMap` with `mapConcat` instead.", "1.0.2")
def statefulMapConcat[T](f: function.Creator[function.Function[Out, java.lang.Iterable[T]]]): javadsl.Source[T, Mat] =
new Source(delegate.statefulMapConcat { () =>
val fun = f.create()
diff --git a/stream/src/main/scala/org/apache/pekko/stream/javadsl/SubFlow.scala b/stream/src/main/scala/org/apache/pekko/stream/javadsl/SubFlow.scala
index fc258e512b..ea339fc70f 100755
--- a/stream/src/main/scala/org/apache/pekko/stream/javadsl/SubFlow.scala
+++ b/stream/src/main/scala/org/apache/pekko/stream/javadsl/SubFlow.scala
@@ -353,7 +353,6 @@ class SubFlow[In, Out, Mat](
*
* '''Cancels when''' downstream cancels
*/
- @deprecated("Use `statefulMap` with `mapConcat` instead.", "1.0.2")
def statefulMapConcat[T](f: function.Creator[function.Function[Out, java.lang.Iterable[T]]]): SubFlow[In, T, Mat] =
new SubFlow(delegate.statefulMapConcat { () =>
val fun = f.create()
diff --git a/stream/src/main/scala/org/apache/pekko/stream/javadsl/SubSource.scala b/stream/src/main/scala/org/apache/pekko/stream/javadsl/SubSource.scala
index 340ea3063c..a3b39c391d 100755
--- a/stream/src/main/scala/org/apache/pekko/stream/javadsl/SubSource.scala
+++ b/stream/src/main/scala/org/apache/pekko/stream/javadsl/SubSource.scala
@@ -344,7 +344,6 @@ class SubSource[Out, Mat](
*
* '''Cancels when''' downstream cancels
*/
- @deprecated("Use `statefulMap` with `mapConcat` instead.", "1.0.2")
def statefulMapConcat[T](f: function.Creator[function.Function[Out, java.lang.Iterable[T]]]): SubSource[T, Mat] =
new SubSource(delegate.statefulMapConcat { () =>
val fun = f.create()
diff --git a/stream/src/main/scala/org/apache/pekko/stream/scaladsl/Flow.scala b/stream/src/main/scala/org/apache/pekko/stream/scaladsl/Flow.scala
index 0b73b0b90a..7918a7edf5 100755
--- a/stream/src/main/scala/org/apache/pekko/stream/scaladsl/Flow.scala
+++ b/stream/src/main/scala/org/apache/pekko/stream/scaladsl/Flow.scala
@@ -1206,7 +1206,6 @@ trait FlowOps[+Out, +Mat] {
*
* See also [[FlowOps.mapConcat]]
*/
- @deprecated("Use `statefulMap` with `mapConcat` instead.", "1.0.2")
def statefulMapConcat[T](f: () => Out => IterableOnce[T]): Repr[T] =
via(new StatefulMapConcat(f))
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pekko.apache.org
For additional commands, e-mail: commits-help@pekko.apache.org