public void NotifyEventCommitted(VerificationEvent @event) { _eventsForVerification.Enqueue(@event); var com = Interlocked.Increment(ref _totalWritten); if (com % NotificationStep == 0) { var table = new ConsoleTable("WORKER", "COMMITTED"); table.AppendRow("WRITER", com.ToString()); Log.Info(table.CreateIndentedTable()); } }
public void NotifyEventVerified(VerificationEvent @event) { var ver = Interlocked.Increment(ref _totalVerified); if (ver % NotificationStep == 0) { var table = new ConsoleTable("WORKER", "VERIFIED"); table.AppendRow("VERIFIER", ver.ToString()); Log.Info(table.CreateIndentedTable()); } var committed = _totalWritten; if (committed == _totalEvents) { _doneEvent.Set(); } }
public void NotifyEventVerified(VerificationEvent @event) { var ver = Interlocked.Increment(ref _totalVerified); if (ver % NotificationStep == 0) { var table = new ConsoleTable("WORKER", "VERIFIED"); table.AppendRow("VERIFIER", ver.ToString()); Log.Info(table.CreateIndentedTable()); } var committed = _totalWritten; if (committed == _totalEvents) _doneEvent.Set(); }
public bool TryGetEventToVerify(out VerificationEvent evnt) { return _eventsForVerification.TryDequeue(out evnt); }
public bool TryGetEventToWrite(out VerificationEvent evnt) { return _eventsForWriting.TryDequeue(out evnt); }
public WriteTask(VerificationEvent @event) { Ensure.NotNull(@event, "event"); _event = @event; }
public bool TryGetEventToVerify(out VerificationEvent evnt) { return(_eventsForVerification.TryDequeue(out evnt)); }
public bool TryGetEventToWrite(out VerificationEvent evnt) { return(_eventsForWriting.TryDequeue(out evnt)); }