As an FYI (you probably already know), you can also call the context's stop method. This is the same as PoisonPill with the difference being that other messages in the mailbox are discarded. It may be worth clarifying the difference in the documentation here.

        context.stop(myWebSocketActorRef)