コード例 #1
0
        public void Handle(MonitoringMessage.InternalStatsRequest message)
        {
            var indexStats = _readIndex.GetStatistics();

            var stats = new Dictionary <string, object>
            {
                { "es-readIndex-failedReadCount", indexStats.FailedReadCount },
                { "es-readIndex-succReadCount", indexStats.SuccReadCount }
            };

            message.Envelope.ReplyWith(new MonitoringMessage.InternalStatsRequestResponse(stats));
        }
コード例 #2
0
        void IHandle <MonitoringMessage.InternalStatsRequest> .Handle(MonitoringMessage.InternalStatsRequest message)
        {
            var s     = _readIndex.GetStatistics();
            var stats = new Dictionary <string, object> {
                { "es-readIndex-cachedRecord", s.CachedRecordReads },
                { "es-readIndex-notCachedRecord", s.NotCachedRecordReads },
                { "es-readIndex-cachedStreamInfo", s.CachedStreamInfoReads },
                { "es-readIndex-notCachedStreamInfo", s.NotCachedStreamInfoReads },
                { "es-readIndex-cachedTransInfo", s.CachedTransInfoReads },
                { "es-readIndex-notCachedTransInfo", s.NotCachedTransInfoReads },
            };

            message.Envelope.ReplyWith(new MonitoringMessage.InternalStatsRequestResponse(stats));
        }
コード例 #3
0
 public ReadIndexStats GetStatistics() => _readIndex.GetStatistics();