public static Create ( ActorSystem system ) : |
||
system | ActorSystem | |
return |
public static ClusterReceptionistSettings Create(ActorSystem system)
{
var config = system.Settings.Config.GetConfig("akka.cluster.client.receptionist");
if (config == null)
throw new ArgumentException(string.Format("Actor system [{0}] doesn't have `akka.cluster.client.receptionist` config set up", system.Name));
return Create(config);
}
ClusterReceptionistSettings::Create ( |
private IActorRef CreateReceptionist(Config config) { if (IsTerminated) { return(_system.DeadLetters); } else { var name = config.GetString("name"); var dispatcher = config.GetString("use-dispatcher"); if (string.IsNullOrEmpty(dispatcher)) { dispatcher = Dispatchers.DefaultDispatcherId; } // important to use val mediator here to activate it outside of ClusterReceptionist constructor var mediator = PubSubMediator; return(_system.SystemActorOf(ClusterReceptionist.Props(mediator, ClusterReceptionistSettings.Create(config)).WithDispatcher(dispatcher), name)); } }