public OngoingCapture(IExecutionTimer executionTimer, IMessageBroker messageBroker, string eventName, string eventSubText, TimelineCategoryItem category, ITimelineMessage message) { Offset = executionTimer.Start(); ExecutionTimer = executionTimer; Message = message.AsTimelineMessage(eventName, category, eventSubText); MessageBroker = messageBroker; }
protected void WriteTimelineMessageCore(ITimelineMessage timelineMessage) { var timerResult = _timer.Stop(_offset); var message = timelineMessage .AsTimelineMessage(EventName, CategoryItem) .AsTimedMessage(timerResult); _messageBroker.Publish(message); }
protected void WriteTimelineMessageCore(ITimelineMessage timelineMessage) { var timerResult = _timer.Stop(_offset); var message = timelineMessage .AsTimelineMessage(EventName, CategoryItem) .AsTimedMessage(timerResult); _messageBroker.Publish(message); }
internal static void CaptureMoment(string eventName, string eventSubText, TimelineCategoryItem category, ITimelineMessage message) { if (string.IsNullOrEmpty(eventName)) { throw new ArgumentNullException("eventName"); } #pragma warning disable 618 var executionTimer = GlimpseConfiguration.GetConfiguredTimerStrategy()(); var messageBroker = GlimpseConfiguration.GetConfiguredMessageBroker(); #pragma warning restore 618 if (executionTimer == null || messageBroker == null) { return; } message .AsTimelineMessage(eventName, category, eventSubText) .AsTimedMessage(executionTimer.Point()); messageBroker.Publish(message); }
internal static void CaptureMoment(string eventName, string eventSubText, TimelineCategoryItem category, ITimelineMessage message) { if (string.IsNullOrEmpty(eventName)) { throw new ArgumentNullException("eventName"); } #pragma warning disable 618 var executionTimer = GlimpseConfiguration.GetConfiguredTimerStrategy()(); var messageBroker = GlimpseConfiguration.GetConfiguredMessageBroker(); #pragma warning restore 618 if (executionTimer == null || messageBroker == null) { return; } message .AsTimelineMessage(eventName, category, eventSubText) .AsTimedMessage(executionTimer.Point()); messageBroker.Publish(message); }
public OngoingCapture(IExecutionTimer executionTimer, IMessageBroker messageBroker, string eventName, string eventSubText, TimelineCategoryItem category, ITimelineMessage message) { Offset = executionTimer.Start(); ExecutionTimer = executionTimer; Message = message.AsTimelineMessage(eventName, category, eventSubText); MessageBroker = messageBroker; }