akka / akka

Build highly concurrent, distributed, and resilient message-driven applications on the JVM
https://akka.io
Other
13.05k stars 3.59k forks source link

Add more examples for integrating with actors, in custom stage section of docs #22742

Open rrodseth opened 7 years ago

rrodseth commented 7 years ago

(As requested by Konrad on akka-user) https://groups.google.com/forum/#!topic/akka-user/AgVHHnl9ub4

Request for more examples here: http://doc.akka.io/docs/akka/2.5/scala/stream/stream-customize.html#Integration_with_actors

ktoso commented 7 years ago

Thanks for the ticket, posting your comment from that thread, it's good notes:

I don't know if this makes any sense, but I wonder if I'm looking for something like

1) pass an actor ref A to constructor of graph stage 2) get "replyTo" ref using getStageActorRef 3) send a message to A with replyTo as a property.

tunesmith commented 7 years ago

Here is a code sample I wrote with a possible usage of getStageActor (note that getStageActorRef has been changed to getStageActor):

https://github.com/Keenworks/SampleActorStage

ktoso commented 7 years ago

Cool, thanks for the example! Will have a look soon at it (team is a bit traveling and in meetings this week, so sorry for the delays).

I took liberty to fix the typo right away, thanks for pointing out the typo on akka-user 👍 PR here: https://github.com/akka/akka/pull/23097