public OverlayHost NewHost(OverlayHostName hostName, OverlayHost.ProcessorAssigner messageProcessor, MemoryStream extraHandshakeInfo, TimeSpan inactivityPeriod) { MyAssert.Assert(!hosts.ContainsKey(hostName)); OverlayHost host = new OverlayHost(hostName, MyAddress, processQueue, messageProcessor, extraHandshakeInfo, tt, inactivityPeriod); hosts.Add(hostName, host); Log.EntryConsole(log, "New host: " + hostName); return(host); }
public OverlayHost(OverlayHostName hostName, IPEndPoint address, ActionSyncronizerProxy processQueue, ProcessorAssigner messageProcessorAssigner, MemoryStream extraHandshakeInfo, TimerThread tt, TimeSpan inactivityPeriod) { this.inactivityPeriod = inactivityPeriod; this.hostName = hostName; this.IpAddress = address; this.processQueue = processQueue; this.processorAssigner = messageProcessorAssigner; this.extraHandshakeInfo = extraHandshakeInfo; log = MasterLog.GetFileLog("network", hostName.ToString() + ".log"); tt.AddAction(this.DisconnectInactiveNodes); }
public void BroadcastGroup(OverlayHostName name, NetworkMessage nm) { BroadcastGroup((n) => n.info.remote.hostname == name, nm); }
public OverlayEndpoint(IPEndPoint addr_, OverlayHostName host_) { addr = addr_; hostname = host_; }