/// <summary>
        /// Invoked when bet stop message is received
        /// </summary>
        /// <param name="sender">The instance raising the event</param>
        /// <param name="e">The event arguments</param>
        protected virtual void OnBetStopReceived(object sender, BetStopEventArgs <ISportEvent> e)
        {
            var betStop = e.GetBetStop();

            FeedMessages.Add(new FMessage(betStop.Timestamps.Created, betStop.Event, "BetStop"));
            WriteMessageData((IOddsFeedSession)sender, e.GetBetStop(), DateTime.Now);
        }
        /// <summary>
        /// Invoked when bet stop message is received
        /// </summary>
        /// <param name="sender">The instance raising the event</param>
        /// <param name="e">The event arguments</param>
        protected virtual void OnBetStopReceived(object sender, BetStopEventArgs <T> e)
        {
            var betstop = e.GetBetStop();

            _log.LogInformation($"BetStop received. EventId:{betstop.Event.Id} Producer:{betstop.Producer}, Tag:{betstop.Groups}, RequestId:{betstop.RequestId}");
            _sportEntityWriter?.WriteData(betstop.Event);
        }
Example #3
0
        /// <summary>
        /// Invoked when bet stop message is received
        /// </summary>
        /// <param name="sender">The instance raising the event</param>
        /// <param name="e">The event arguments</param>
        protected virtual void OnBetStopReceived(object sender, BetStopEventArgs <T> e)
        {
            Guard.Argument(e, nameof(e)).NotNull();

            using var t = SdkMetricsFactory.MetricsRoot.Measure.Timer.Time(_timerOnBetStopReceived, $"{e.GetBetStop().Event.Id}");
            var betStop = e.GetBetStop();

            _log.LogInformation($"BetStop received. EventId:{betStop.Event.Id} Producer:{betStop.Producer.Name}, Groups:{betStop.Groups}, RequestId:{betStop.RequestId}");
            _sportEntityWriter?.WriteData(betStop.Event);
            _log.LogInformation($"BetStop received. EventId:{betStop.Event.Id}. Processing took {t.Elapsed.TotalMilliseconds}ms.");
        }
Example #4
0
        private void SessionLowOnBetStop(object sender, BetStopEventArgs <ISportEvent> betStopEventArgs)
        {
            var baseEntity = betStopEventArgs.GetBetStop();

            WriteLowSportEntity(baseEntity.GetType().Name, baseEntity.Event);
        }
Example #5
0
        private void SessionOnBetStop(object sender, BetStopEventArgs <ISportEvent> betStopEventArgs)
        {
            var baseEntity = betStopEventArgs.GetBetStop();

            WriteSportEntity(baseEntity.GetType().Name, baseEntity.Event, baseEntity.Timestamps.Created);
        }