Deprecation of ExtensionKey #22208
This commit is contained in:
parent
8f9b4f203a
commit
cf6d5a4e8a
7 changed files with 78 additions and 14 deletions
|
|
@ -74,7 +74,14 @@ akka.persistence.snapshot-store.plugin = "akka.persistence.no-snapshot-store"
|
|||
}
|
||||
}
|
||||
|
||||
object JournalPuppet extends ExtensionKey[JournalProbe]
|
||||
object JournalPuppet extends ExtensionId[JournalProbe] with ExtensionIdProvider {
|
||||
override def lookup()= JournalPuppet
|
||||
|
||||
override def createExtension(system: ExtendedActorSystem): JournalProbe =
|
||||
new JournalProbe()(system)
|
||||
|
||||
override def get(system: ActorSystem): JournalProbe = super.get(system)
|
||||
}
|
||||
class JournalProbe(implicit private val system: ExtendedActorSystem) extends Extension {
|
||||
val probe = TestProbe()
|
||||
val ref = probe.ref
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue