Minor entityId sample code clarification in docs.
This commit is contained in:
parent
1b44348425
commit
a7fc6f824e
1 changed files with 3 additions and 1 deletions
|
|
@ -70,7 +70,9 @@ Scala
|
|||
Java
|
||||
: @@snip [ShardingCompileOnlyTest.java](/akka-cluster-sharding-typed/src/test/java/jdocs/akka/cluster/sharding/typed/ShardingCompileOnlyTest.java) { #counter }
|
||||
|
||||
Each Entity type has a key that is then used to retrieve an EntityRef for a given entity identifier.
|
||||
Each Entity type has a key that is then used to retrieve an EntityRef for a given entity identifier.
|
||||
Note in the sample's @scala[`Counter.apply`]@java[`Counter.create`] function that the `entityId` parameter is not
|
||||
called, it is included to demonstrate how one can pass it to an entity. Another way to do this is by sending the `entityId` as part of the message if needed.
|
||||
|
||||
Scala
|
||||
: @@snip [ShardingCompileOnlySpec.scala](/akka-cluster-sharding-typed/src/test/scala/docs/akka/cluster/sharding/typed/ShardingCompileOnlySpec.scala) { #init }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue