/// <summary> /// Initializes this instance. /// </summary> public virtual void Init() { RootPath = new RootActorPath(Address); TempNode = RootPath / "temp"; RootCell = new ActorCell(System, "", new ConcurrentQueueMailbox()); DeadLetters = new DeadLetterActorRef(this, RootPath / "deadLetters", System.EventStream); Guardian = (LocalActorRef)RootCell.ActorOf <GuardianActor>("user"); SystemGuardian = (LocalActorRef)RootCell.ActorOf <GuardianActor>("system"); TempContainer = new VirtualPathContainer(this, TempNode, null); }
public void Init(ActorSystemImpl system) { _system = system; //The following are the lazy val statements in Akka var defaultDispatcher = system.Dispatchers.DefaultGlobalDispatcher; _defaultMailbox = () => new ConcurrentQueueMailbox(); //TODO:system.Mailboxes.FromConfig(Mailboxes.DefaultMailboxId) _rootGuardian = CreateRootGuardian(system); _tempContainer = new VirtualPathContainer(system.Provider, _tempNode, _rootGuardian, _log); _rootGuardian.SetTempContainer(_tempContainer); _userGuardian = CreateUserGuardian(_rootGuardian, "user"); _systemGuardian = CreateSystemGuardian(_rootGuardian, "system", _userGuardian); //End of lazy val _rootGuardian.Start(); // chain death watchers so that killing guardian stops the application _systemGuardian.Tell(new Watch(_userGuardian, _systemGuardian)); //Should be SendSystemMessage _rootGuardian.Tell(new Watch(_systemGuardian, _rootGuardian)); //Should be SendSystemMessage _eventStream.StartDefaultLoggers(_system); }
/// <summary> /// Initializes this instance. /// </summary> public virtual void Init() { RootPath = new RootActorPath(Address); TempNode = RootPath / "temp"; RootCell = new ActorCell(System, "", new ConcurrentQueueMailbox()); DeadLetters = new DeadLetterActorRef(this, RootPath / "deadLetters", System.EventStream); Guardian = (LocalActorRef)RootCell.ActorOf<GuardianActor>("user"); SystemGuardian = (LocalActorRef)RootCell.ActorOf<GuardianActor>("system"); TempContainer = new VirtualPathContainer(this, TempNode, null); }
public void Init(ActorSystemImpl system) { _system = system; //The following are the lazy val statements in Akka var defaultDispatcher = system.Dispatchers.DefaultGlobalDispatcher; _defaultMailbox = () => new ConcurrentQueueMailbox(); //TODO:system.Mailboxes.FromConfig(Mailboxes.DefaultMailboxId) _rootGuardian = CreateRootGuardian(system); _tempContainer = new VirtualPathContainer(system.Provider, _tempNode, _rootGuardian, _log); _rootGuardian.SetTempContainer(_tempContainer); _userGuardian = CreateUserGuardian(_rootGuardian, "user"); _systemGuardian = CreateSystemGuardian(_rootGuardian, "system", _userGuardian); //End of lazy val _rootGuardian.Start(); // chain death watchers so that killing guardian stops the application _systemGuardian.SendSystemMessage(new Watch(_userGuardian, _systemGuardian)); _rootGuardian.SendSystemMessage(new Watch(_systemGuardian, _rootGuardian)); _eventStream.StartDefaultLoggers(_system); }