Наследование: Natol.PerformanceCounter2CloudWatch.PerformanceCounters.PerformanceCounterDescriptor
Пример #1
0
        private static CounterDescriptor CreateDescriptor(Site iisSite)
        {
            var pc = new PerformanceCounter("Web Service", "Total Method Requests/sec", iisSite.Name, true);

            pc.NextValue();

            var pcd = new TrafficPerformanceCounterDescriptor
            {
                Name          = iisSite.Name,
                SystemCounter = pc,
                Unit          = "Count/Second",
                MetricName    = "Method Requests"
            };

            pcd.Dimensions.Add("SiteName", iisSite.Name);

            return(pcd);
        }
        private static CounterDescriptor CreateDescriptor(Site iisSite)
        {
            var pc = new PerformanceCounter("Web Service", "Total Method Requests/sec", iisSite.Name, true);
            pc.NextValue();

            var pcd = new TrafficPerformanceCounterDescriptor
            {
                Name=iisSite.Name,
                SystemCounter=pc,
                Unit = "Count/Second",
                MetricName="Method Requests"
            };

            pcd.Dimensions.Add("SiteName",iisSite.Name);

            return pcd;
        }