You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@pekko.apache.org by "jxnu-liguobin (via GitHub)" <gi...@apache.org> on 2024/02/01 05:46:46 UTC

Re: [PR] feat: Add AutoCloseable shortcut on mapWithResource [incubator-pekko]

jxnu-liguobin commented on code in PR #1053:
URL: https://github.com/apache/incubator-pekko/pull/1053#discussion_r1473824002


##########
stream/src/main/scala/org/apache/pekko/stream/javadsl/Source.scala:
##########
@@ -2541,6 +2541,45 @@ final class Source[Out, Mat](delegate: scaladsl.Source[Out, Mat]) extends Graph[
         (resource, out) => f(resource, out),
         resource => close.apply(resource).toScala))
 
+  /**
+   * Transform each stream element with the help of a [[AutoCloseable]] resource and close it when the stream finishes or fails.

Review Comment:
   an



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@pekko.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@pekko.apache.org
For additional commands, e-mail: notifications-help@pekko.apache.org