-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Description
I am following the example/tutorial at http://getakka.net/articles/clustering/cluster-client.html#an-example, which recommends adding the line:
akka.extensions = ["Akka.Cluster.Tools.Client.ClusterClientReceptionist"]
to your HOCON. However, after doing this, I see errors during startup:
[ERROR][18/08/2017 08:43:05][Thread 0010][ActorSystem(Repro)] [Akka.Cluster.Tools.Client.ClusterClientReceptionist] is not an 'ExtensionId', skipping...
Cause: Unknown
I've had a look at the code which generates this error:
akka.net/src/core/Akka/Actor/Internal/ActorSystemImpl.cs
Lines 270 to 277 in a478c5e
{ | |
var extensions = new List<IExtensionId>(); | |
foreach(var extensionFqn in _settings.Config.GetStringList("akka.extensions")) | |
{ | |
var extensionType = Type.GetType(extensionFqn); | |
if(extensionType == null || !typeof(IExtensionId).IsAssignableFrom(extensionType) || extensionType.GetTypeInfo().IsAbstract || !extensionType.GetTypeInfo().IsClass) | |
{ | |
_log.Error("[{0}] is not an 'ExtensionId', skipping...", extensionFqn); |
This seems to take the strings in akka.extensions and look them up as types using Type.GetType. This part fails as there is no assembly name (change the configuration to akka.extensions = ["Akka.Cluster.Tools.Client.ClusterClientReceptionist, Akka.Cluster.Tools"]
and it can now find the type).
But then, a subsequent check fails; the type specified needs to implement Akka.Actor.IExtensionId, which Akka.Cluster.Tools.Client.ClusterClientReceptionist does not:
Am I doing something wrong?
Thanks.