internal void EndServiceCall(string methodName, ServiceMetricStatusEnum status, TimeSpan processTime, DateTime timestamp, string callingIPAddress, string callingHostName) { // Update Counters lock (WebMethodMetricsList) { WebMethodAggregateData serviceMetricData = WebMethodMetricsList.FirstOrDefault(m => m.WebMethodName.Equals(methodName)); serviceMetricData.EndServiceCall(status, processTime, timestamp, callingIPAddress, callingHostName); } }
internal void StartServiceCall(string webMethodName) { // Initialize Counter for Method lock (WebMethodMetricsList) { WebMethodAggregateData serviceMetricData = WebMethodMetricsList.FirstOrDefault(m => m.WebMethodName.Equals(webMethodName)); if (serviceMetricData == null) { serviceMetricData = new WebMethodAggregateData(webMethodName); WebMethodMetricsList.Add(serviceMetricData); } serviceMetricData.StartServiceCall(); } }