public void Publish(string subject, T data) { // init data.TransactionInfo.TransactionId = AddTransaction(subject, data); // update AddPayloadAndHistory(subject, data, data.TransactionInfo.TransactionId); _obs.Publish(subject, data); }
public void Publish(string subject, T data) { try { _log.Trace(new { direction = "Publisher", subject = subject, data = data }); _obs.Publish(subject, data); } catch (Exception e) { _log.Error(e, e.Message, data); // To need for writ log System.Threading.Thread.Sleep(2000); throw; } }