From ec7be4922f38c06ed69fa14929d18a5c335bdddc Mon Sep 17 00:00:00 2001 From: Helena Edelson Date: Wed, 20 Nov 2019 02:56:35 -0800 Subject: [PATCH] Mention no implicit sender in coexistence.md #28074 (#28173) * Mention no implicit sender in coexistence.md #28074 --- akka-docs/src/main/paradox/typed/coexisting.md | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/akka-docs/src/main/paradox/typed/coexisting.md b/akka-docs/src/main/paradox/typed/coexisting.md index 68ead3642e..3922313bfe 100644 --- a/akka-docs/src/main/paradox/typed/coexisting.md +++ b/akka-docs/src/main/paradox/typed/coexisting.md @@ -116,13 +116,20 @@ Scala Java : @@snip [TypedWatchingClassicTest.java](/akka-actor-typed-tests/src/test/java/jdocs/akka/typed/coexistence/TypedWatchingClassicTest.java) { #typed } +@@@ div { .group-scala } + +Note that when sending from a typed actor to a classic `ActorRef` there is no sender in scope as in classic. +The typed sender should use its own `ActorContext[T].self` explicitly, as shown in the snippet. + +@@@ + @@@ Note One important difference when having a typed system and a typed user guardian actor and combining that with classic actors is that even if you can turn the typed `ActorSystem` to a classic one it is no longer possible to spawn user level actors, trying to do this will throw an exception, such usage must instead be replaced with bootstrap directly in the guardian actor, or commands telling the guardian to spawn children. - + @@@ ## Supervision