public ActorRequestContext( ActorSystem system, ActorItem self, ProcessId sender, ActorItem parent, object currentMsg, ActorRequest currentRequest, ProcessFlags processFlags, ProcessOpTransaction ops, SessionVector session ) { Self = self; Sender = sender; Parent = parent; CurrentMsg = currentMsg; CurrentRequest = currentRequest; ProcessFlags = processFlags; Ops = ops; System = system; Session = session; }
public static Unit StartSystem(SystemName system, Option<ICluster> cluster, AppProfile appProfile, ProcessSystemConfig config) { lock (sync) { if (systems.ContainsKey(system)) { throw new InvalidOperationException($"Process-system ({system}) already started"); } var asystem = new ActorSystem(system, cluster, appProfile, config); systems.AddOrUpdate(system, asystem, (_, __) => asystem); try { asystem.Initialise(); // Set the default system if the 'default: yes' setting is in the ProcessSystemConfig defaultSystem = defaultSystem.IsValid ? (from c in config.Cluster where c.Default select system) .IfNone(defaultSystem) : system; } catch { systems.TryRemove(system, out asystem); try { asystem.Dispose(); } catch { } throw; } return unit; } }
public static Unit SetSystem(ActorSystem system) { context = system.SystemName; return unit; }