-
Notifications
You must be signed in to change notification settings - Fork 387
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cluster-sharding: single listener per entity type key + Java DSL #1080
Conversation
That way if it is loaded multiple times only one actor is created. Also remove the method that takes in an actor system. We shouldn't allow an extension from one system to use another system
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
cluster-sharding/src/main/scala/akka/kafka/cluster/sharding/KafkaClusterSharding.scala
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some possibly contradicting comments.
LGTM.
} | ||
|
||
public static void example() { | ||
ActorSystem<Void> typedSystem = ActorSystem.create(Behaviors.empty(), "ClusterShardingExample"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should just be system
as in other examples.
import akka.actor.typed.scaladsl.Behaviors | ||
import akka.actor.typed.scaladsl.adapter._ | ||
import akka.actor.{ExtendedActorSystem, Extension, ExtensionId} | ||
import akka.actor.{ActorSystem, ClassicActorSystemProvider, ExtendedActorSystem, Extension, ExtensionId} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use the FCQN for ActorSystem
instead of importing it to make it more clear.
Travis wants you to |
Then I shall do what travis wants |
That way if it is loaded multiple times only one actor is created.
Also remove the method that takes in an actor system. We shouldn't allow
an extension from one system to use another system
Adds a Java API + docs