GrapheStage implementation for actorRef source (#25324) (#26054)

* Adds internal access to materializer before initialization (#25324)

* Implements new actorRef source based on graph stage  (#25324)

* Removes obsolete actorRef source (#25324)

* Improves backwards compatibility with old implementation (#25324)

* Removes dedicated new subclass for materializer access again  (#25324)

* Improves implementation (#25324)

* Finalizes implementation (#25324)

* Small improvements to API and documentation (#25324)

* Completion strategy as a replacement for poison pill (#25324)

* Adding more tests and updating the documentation (#25324)
This commit is contained in:
Nicolas Vollmar 2019-03-27 14:16:38 +01:00 committed by Patrik Nordwall
parent 39c06c7c34
commit c9b3f1de6d
15 changed files with 328 additions and 201 deletions

View file

@ -9,6 +9,7 @@ package jdocs.stream.operators;
import akka.NotUsed;
import akka.actor.ActorSystem;
import akka.stream.ActorMaterializer;
import akka.stream.CompletionStrategy;
import akka.stream.Materializer;
import akka.stream.javadsl.Source;
// #range-imports
@ -81,7 +82,7 @@ public class SourceDocExamples {
actorRef.tell("hello", ActorRef.noSender());
// The stream completes successfully with the following message
actorRef.tell(new Success("completes stream"), ActorRef.noSender());
actorRef.tell(new Success(CompletionStrategy.draining()), ActorRef.noSender());
// #actor-ref
}
}