public static Task publishToReadModel(ResolvedEvent eS_Event) { EventFromES normal = NormalizeESEvent(eS_Event); EventDistributor.Publish(normal); return(Task.FromResult(0)); }
public static void Queue(EventModel theEvent) { publishingQueue.Add(theEvent); while (publishingQueue.Count > 0) { EventDistributor.Publish(publishingQueue[0]); if (publishingQueue.Count > 0) { publishingQueue.RemoveAt(0); } } }
private static void distrbuteSavedEvents(List <ResolvedEvent> nonStatEvents) { List <object> aslk = new List <object>(); foreach (var savedEvent in nonStatEvents) { string StringyfiedBytes = System.Text.Encoding.UTF8.GetString(savedEvent.Event.Data); try { var eventFromES = NormalizeESEvent(savedEvent); EventDistributor.Publish(eventFromES); } catch (Exception e) { Console.Write(e); } } }
public static void Register() { EventDistributor.Publish(new EventFromES { }); }