private void OnGetServices(SvcDiscovery.GetServices msg) { Log.Info("{@Event}", msg); var response = new SvcDiscovery.SetServices(); Services.ForEach(x => response.Services.Add(x)); Sender.Tell(response, Self); }
private void OnServices(SvcDiscovery.SetServices msg) { Log.Info("{@Event}", msg); initialized = true; msg.Services.ForEach(x => { if (!Services.Any(svc => svc.ClusterAddress.Equals(x.ClusterAddress))) { Services.Add(x); } }); DecrementAck(); }