226 references to PerformanceCounters
System.ServiceModel (226)
System\ServiceModel\Administration\AppDomainInstanceProvider.cs (1)
64instance.SetProperty(AdministrationStrings.PerformanceCounters, PerformanceCounters.Scope.ToString());
System\ServiceModel\Administration\EndpointInstanceProvider.cs (2)
123instance.SetProperty(AdministrationStrings.CounterInstanceName, PerformanceCounters.PerformanceCountersEnabled ? EndpointPerformanceCounters.GetFriendlyInstanceName(endpoint.ServiceName, endpoint.Contract.Name, endpoint.Address.AbsoluteUri.ToUpperInvariant()) : String.Empty); 669if (PerformanceCounters.PerformanceCountersEnabled && null != endpointInfo)
System\ServiceModel\Administration\ServiceInstanceProvider.cs (1)
135instance.SetProperty(AdministrationStrings.CounterInstanceName, PerformanceCounters.PerformanceCountersEnabled ? ServicePerformanceCounters.GetFriendlyInstanceName(info.Service) : String.Empty);
System\ServiceModel\Channels\MsmqDiagnostics.cs (7)
267if (PerformanceCounters.PerformanceCountersEnabled) 271PerformanceCounters.MsmqRejectedMessage(uri); 275PerformanceCounters.MsmqDroppedMessage(uri); 334if (poisonQueue && PerformanceCounters.PerformanceCountersEnabled) 336PerformanceCounters.MsmqPoisonMessage(uri); 352if (PerformanceCounters.PerformanceCountersEnabled) 354PerformanceCounters.MsmqPoisonMessage(uri);
System\ServiceModel\Channels\ReliableDuplexSessionChannel.cs (5)
1777if (PerformanceCounters.PerformanceCountersEnabled) 1864if (PerformanceCounters.PerformanceCountersEnabled) 1865PerformanceCounters.SessionFaulted(this.perfCounterId); 1870if (PerformanceCounters.PerformanceCountersEnabled) 1871PerformanceCounters.MessageDropped(this.perfCounterId);
System\ServiceModel\Channels\ReliableInputSessionChannel.cs (19)
48if (PerformanceCounters.PerformanceCountersEnabled) 347if (PerformanceCounters.PerformanceCountersEnabled) 348PerformanceCounters.SessionFaulted(this.perfCounterId); 647if (PerformanceCounters.PerformanceCountersEnabled) 648PerformanceCounters.MessageDropped(this.perfCounterId); 653if (PerformanceCounters.PerformanceCountersEnabled) 654PerformanceCounters.MessageDropped(this.perfCounterId); 682if (PerformanceCounters.PerformanceCountersEnabled) 683PerformanceCounters.MessageDropped(this.perfCounterId); 709if (PerformanceCounters.PerformanceCountersEnabled) 710PerformanceCounters.MessageDropped(this.perfCounterId); 1062if (PerformanceCounters.PerformanceCountersEnabled) 1063PerformanceCounters.MessageDropped(this.perfCounterId); 1068if (PerformanceCounters.PerformanceCountersEnabled) 1069PerformanceCounters.MessageDropped(this.perfCounterId); 1089if (PerformanceCounters.PerformanceCountersEnabled) 1090PerformanceCounters.MessageDropped(this.perfCounterId); 1107if (PerformanceCounters.PerformanceCountersEnabled) 1108PerformanceCounters.MessageDropped(this.perfCounterId);
System\ServiceModel\Channels\ReliableReplySessionChannel.cs (11)
69if (PerformanceCounters.PerformanceCountersEnabled) 535if (PerformanceCounters.PerformanceCountersEnabled) 536PerformanceCounters.SessionFaulted(this.perfCounterId); 1066if (PerformanceCounters.PerformanceCountersEnabled) 1067PerformanceCounters.MessageDropped(this.perfCounterId); 1072if (PerformanceCounters.PerformanceCountersEnabled) 1073PerformanceCounters.MessageDropped(this.perfCounterId); 1096if (PerformanceCounters.PerformanceCountersEnabled) 1097PerformanceCounters.MessageDropped(this.perfCounterId); 1126if (PerformanceCounters.PerformanceCountersEnabled) 1127PerformanceCounters.MessageDropped(this.perfCounterId);
System\ServiceModel\Description\DispatcherBuilder.cs (7)
580if (PerformanceCounters.PerformanceCountersEnabled) 589else if (PerformanceCounters.MinimalPerformanceCountersEnabled) 785if (PerformanceCounters.PerformanceCountersEnabled || PerformanceCounters.MinimalPerformanceCountersEnabled) 787PerformanceCounters.AddPerformanceCountersForEndpoint(serviceHost, endpoint.Contract, dispatcher); 792if ((PerformanceCounters.PerformanceCountersEnabled || PerformanceCounters.MinimalPerformanceCountersEnabled) && ServiceModelAppSettings.EnsureUniquePerformanceCounterInstanceNames)
System\ServiceModel\Diagnostics\DefaultPerformanceCounters.cs (3)
78PerformanceCounter counter = PerformanceCounters.GetDefaultPerformanceCounter(this.perfCounterNames[i], this.instanceName); 116if (PerformanceCounters.PerformanceCountersEnabled) 125PerformanceCounters.ReleasePerformanceCounter(ref counter);
System\ServiceModel\Diagnostics\EndpointPerformanceCounters.cs (3)
21PerformanceCounter counter = PerformanceCounters.GetEndpointPerformanceCounter(perfCounterNames[i], this.instanceName); 141if (PerformanceCounters.PerformanceCountersEnabled) 150PerformanceCounters.ReleasePerformanceCounter(ref counter);
System\ServiceModel\Diagnostics\EndpointPerformanceCountersV2.cs (1)
173if (disposing && PerformanceCounters.PerformanceCountersEnabled && this.endpointCounterSetInstance != null)
System\ServiceModel\Diagnostics\OperationPerformanceCounters.cs (3)
20PerformanceCounter counter = PerformanceCounters.GetOperationPerformanceCounter(perfCounterNames[i], this.instanceName); 128if (PerformanceCounters.PerformanceCountersEnabled) 137PerformanceCounters.ReleasePerformanceCounter(ref counter);
System\ServiceModel\Diagnostics\OperationPerformanceCountersV2.cs (1)
158if (disposing && PerformanceCounters.PerformanceCountersEnabled && this.operationCounterSetInstance != null)
System\ServiceModel\Diagnostics\PerformanceCounters.cs (105)
44return PerformanceCounters.scope; 48PerformanceCounters.scope = value; 56return (PerformanceCounters.scope != PerformanceCounterScope.Off) && 57(PerformanceCounters.scope != PerformanceCounterScope.Default); 65return (PerformanceCounters.scope == PerformanceCounterScope.Default); 80PerformanceCounters.scope = scope; 85PerformanceCounters.scope = PerformanceCounterScope.Off; 99PerformanceCounters.scope = PerformanceCounterScope.Off; 113return PerformanceCounters.GetPerformanceCounter( 122return PerformanceCounters.GetPerformanceCounter( 131return PerformanceCounters.GetPerformanceCounter( 140return PerformanceCounters.GetPerformanceCounter( 150if (PerformanceCounters.PerformanceCountersEnabled || PerformanceCounters.MinimalPerformanceCountersEnabled) 152counter = PerformanceCounters.GetPerformanceCounterInternal(categoryName, perfCounterName, instanceName, instanceLifetime); 188PerformanceCounters.scope = PerformanceCounterScope.Off; 281if (PerformanceCounters.performanceCounters == null) 283lock (PerformanceCounters.perfCounterDictionarySyncObject) 285if (PerformanceCounters.performanceCounters == null) 287PerformanceCounters.performanceCounters = new Dictionary<string, ServiceModelPerformanceCounters>(); 291return PerformanceCounters.performanceCounters; 299if (PerformanceCounters.performanceCountersList == null) 301lock (PerformanceCounters.perfCounterDictionarySyncObject) 303if (PerformanceCounters.performanceCountersList == null) 305PerformanceCounters.performanceCountersList = new List<ServiceModelPerformanceCounters>(); 309return PerformanceCounters.performanceCountersList; 317if (PerformanceCounters.performanceCountersBaseUri == null) 319lock (PerformanceCounters.perfCounterDictionarySyncObject) 321if (PerformanceCounters.performanceCountersBaseUri == null) 323PerformanceCounters.performanceCountersBaseUri = new Dictionary<string, ServiceModelPerformanceCountersEntry>(); 327return PerformanceCounters.performanceCountersBaseUri; 341bool performanceCountersEnabled = PerformanceCounters.PerformanceCountersEnabled; 342bool minimalPerformanceCountersEnabled = PerformanceCounters.MinimalPerformanceCountersEnabled; 349lock (PerformanceCounters.perfCounterDictionarySyncObject) 351if (!PerformanceCounters.PerformanceCountersForEndpoint.TryGetValue(endpointDispatcher.PerfCounterId, out counters)) 356PerformanceCounters.PerformanceCountersForEndpoint.Add(endpointDispatcher.PerfCounterId, counters); 358int index = PerformanceCounters.PerformanceCountersForEndpointList.FindIndex(c => c == null); 361PerformanceCounters.PerformanceCountersForEndpointList[index] = counters; 365PerformanceCounters.PerformanceCountersForEndpointList.Add(counters); 366index = PerformanceCounters.PerformanceCountersForEndpointList.Count - 1; 378lock (PerformanceCounters.perfCounterDictionarySyncObject) 380if (!PerformanceCounters.PerformanceCountersForBaseUri.TryGetValue(endpointDispatcher.PerfCounterBaseId, out countersEntry)) 390PerformanceCounters.PerformanceCountersForBaseUri.Add(endpointDispatcher.PerfCounterBaseId, countersEntry); 400if (PerformanceCounters.PerformanceCountersEnabled) 402lock (PerformanceCounters.perfCounterDictionarySyncObject) 407if (PerformanceCounters.PerformanceCountersForEndpoint.TryGetValue(id, out counters)) 409PerformanceCounters.PerformanceCountersForEndpoint.Remove(id); 410int index = PerformanceCounters.PerformanceCountersForEndpointList.IndexOf(counters); 411PerformanceCounters.PerformanceCountersForEndpointList[index] = null; 416PerformanceCounters.PerformanceCountersForBaseUri.Remove(baseId); 446ServicePerformanceCountersBase sCounters = PerformanceCounters.GetServicePerformanceCounters(el.PerfCounterInstanceId); 452if (PerformanceCounters.Scope == PerformanceCounterScope.All) 454OperationPerformanceCountersBase oCounters = PerformanceCounters.GetOperationPerformanceCounters(el.PerfCounterInstanceId, operation); 460EndpointPerformanceCountersBase eCounters = PerformanceCounters.GetEndpointPerformanceCounters(el.PerfCounterInstanceId); 471if (PerformanceCounters.PerformanceCountersEnabled) 475ServicePerformanceCountersBase sCounters = PerformanceCounters.GetServicePerformanceCounters(el.PerfCounterInstanceId); 486if (PerformanceCounters.PerformanceCountersEnabled) 490ServicePerformanceCountersBase sCounters = PerformanceCounters.GetServicePerformanceCounters(el.PerfCounterInstanceId); 502if (PerformanceCounters.PerformanceCountersEnabled) 506ServicePerformanceCountersBase sCounters = PerformanceCounters.GetServicePerformanceCounters(el.PerfCounterInstanceId); 521if (PerformanceCounters.Scope == PerformanceCounterScope.All) 524OperationPerformanceCountersBase opCounters = PerformanceCounters.GetOperationPerformanceCounters(el.PerfCounterInstanceId, operationName); 529EndpointPerformanceCountersBase eCounters = PerformanceCounters.GetEndpointPerformanceCounters(el.PerfCounterInstanceId); 535ServicePerformanceCountersBase sCounters = PerformanceCounters.GetServicePerformanceCounters(el.PerfCounterInstanceId); 545PerformanceCounters.MethodReturnedSuccess(operationName, -1); 553if (PerformanceCounters.Scope == PerformanceCounterScope.All) 556OperationPerformanceCountersBase counters = PerformanceCounters.GetOperationPerformanceCounters(el.PerfCounterInstanceId, operationName); 565EndpointPerformanceCountersBase eCounters = PerformanceCounters.GetEndpointPerformanceCounters(el.PerfCounterInstanceId); 575ServicePerformanceCountersBase sCounters = PerformanceCounters.GetServicePerformanceCounters(el.PerfCounterInstanceId); 589PerformanceCounters.MethodReturnedFault(operationName, -1); 597if (PerformanceCounters.Scope == PerformanceCounterScope.All) 600OperationPerformanceCountersBase counters = PerformanceCounters.GetOperationPerformanceCounters(el.PerfCounterInstanceId, operationName); 609EndpointPerformanceCountersBase eCounters = PerformanceCounters.GetEndpointPerformanceCounters(el.PerfCounterInstanceId); 619ServicePerformanceCountersBase sCounters = PerformanceCounters.GetServicePerformanceCounters(el.PerfCounterInstanceId); 633PerformanceCounters.MethodReturnedError(operationName, -1); 641if (PerformanceCounters.Scope == PerformanceCounterScope.All) 644OperationPerformanceCountersBase counters = PerformanceCounters.GetOperationPerformanceCounters(el.PerfCounterInstanceId, operationName); 653EndpointPerformanceCountersBase eCounters = PerformanceCounters.GetEndpointPerformanceCounters(el.PerfCounterInstanceId); 663ServicePerformanceCountersBase sCounters = PerformanceCounters.GetServicePerformanceCounters(el.PerfCounterInstanceId); 691ServiceModelPerformanceCountersEntry counters = PerformanceCounters.GetServiceModelPerformanceCountersBaseUri(uri); 695PerformanceCounters.InvokeMethod(counters.ServicePerformanceCounters, methodName); 697if (PerformanceCounters.Scope == PerformanceCounterScope.All) 704PerformanceCounters.InvokeMethod(sCounters.EndpointPerformanceCounters, methodName); 712PerformanceCounters.InvokeMethod(oCounters, methodName); 723PerformanceCounters.CallOnAllCounters("AuthenticationFailed", message, listenUri, true); 732if (PerformanceCounters.Scope == PerformanceCounterScope.All) 734OperationPerformanceCountersBase counters = PerformanceCounters.GetOperationPerformanceCounters(el.PerfCounterInstanceId, operationName); 740EndpointPerformanceCountersBase eCounters = PerformanceCounters.GetEndpointPerformanceCounters(el.PerfCounterInstanceId); 747ServicePerformanceCountersBase sCounters = PerformanceCounters.GetServicePerformanceCounters(el.PerfCounterInstanceId); 757ServiceModelPerformanceCountersEntry counters = PerformanceCounters.GetServiceModelPerformanceCountersBaseUri(uri); 761if (PerformanceCounters.Scope == PerformanceCounterScope.All) 777ServiceModelPerformanceCountersEntry counters = PerformanceCounters.GetServiceModelPerformanceCountersBaseUri(uri); 781if (PerformanceCounters.Scope == PerformanceCounterScope.All) 797if (PerformanceCounters.Scope == PerformanceCounterScope.All) 799ServiceModelPerformanceCountersEntry counters = PerformanceCounters.GetServiceModelPerformanceCountersBaseUri(uri); 809if (PerformanceCounters.Scope == PerformanceCounterScope.All) 811ServiceModelPerformanceCountersEntry counters = PerformanceCounters.GetServiceModelPerformanceCountersBaseUri(uri); 821if (PerformanceCounters.Scope == PerformanceCounterScope.All) 823ServiceModelPerformanceCountersEntry counters = PerformanceCounters.GetServiceModelPerformanceCountersBaseUri(uri); 845if (PerformanceCounters.PerformanceCountersForEndpointList.Count == 0) 849return PerformanceCounters.PerformanceCountersForEndpointList[perfCounterInstanceId]; 857PerformanceCounters.PerformanceCountersForBaseUri.TryGetValue(uri, out counters); 864ServiceModelPerformanceCounters counters = PerformanceCounters.GetServiceModelPerformanceCounters(perfCounterInstanceId); 874ServiceModelPerformanceCounters counters = PerformanceCounters.GetServiceModelPerformanceCounters(perfCounterInstanceId); 884ServiceModelPerformanceCounters counters = PerformanceCounters.GetServiceModelPerformanceCounters(perfCounterInstanceId);
System\ServiceModel\Diagnostics\PerformanceCountersFactory.cs (4)
41PerformanceCounters.Scope = PerformanceCounterScope.Off; 76PerformanceCounters.Scope = PerformanceCounterScope.Off; 111PerformanceCounters.Scope = PerformanceCounterScope.Off; 136PerformanceCounters.Scope = PerformanceCounterScope.Off;
System\ServiceModel\Diagnostics\ServiceModelPerformanceCounters.cs (4)
34if (PerformanceCounters.Scope == PerformanceCounterScope.All) 74if (PerformanceCounters.PerformanceCountersEnabled) 78if (PerformanceCounters.MinimalPerformanceCountersEnabled) 104Fx.Assert(PerformanceCounters.Scope == PerformanceCounterScope.All, "Only call GetOparationPerformanceCounters when performance counter scope is All");
System\ServiceModel\Diagnostics\ServicePerformanceCounters.cs (3)
22PerformanceCounter counter = PerformanceCounters.GetServicePerformanceCounter(perfCounterNames[i], this.InstanceName); 208if (PerformanceCounters.PerformanceCountersEnabled) 217PerformanceCounters.ReleasePerformanceCounter(ref counter);
System\ServiceModel\Diagnostics\ServicePerformanceCountersV2.cs (1)
251if (disposing && PerformanceCounters.PerformanceCountersEnabled && this.serviceCounterSetInstance != null)
System\ServiceModel\Diagnostics\SystemDiagnosticsPerformanceCountersExtension.cs (8)
30PerformanceCounters.TracePerformanceCounterUpdateFailure(thisPtr.InstanceName, thisPtr.CounterNames[counterIndex]); 34PerformanceCounters.ReleasePerformanceCounter(ref counter); 57PerformanceCounters.TracePerformanceCounterUpdateFailure(thisPtr.InstanceName, thisPtr.CounterNames[counterIndex]); 61PerformanceCounters.ReleasePerformanceCounter(ref counter); 84PerformanceCounters.TracePerformanceCounterUpdateFailure(thisPtr.InstanceName, thisPtr.CounterNames[counterIndex]); 86PerformanceCounters.ReleasePerformanceCounter(ref counter); 108PerformanceCounters.TracePerformanceCounterUpdateFailure(thisPtr.InstanceName, thisPtr.CounterNames[counterIndex]); 112PerformanceCounters.ReleasePerformanceCounter(ref counter);
System\ServiceModel\Dispatcher\AsyncMethodInvoker.cs (6)
309if (PerformanceCounters.PerformanceCountersEnabled) 311PerformanceCounters.MethodCalled(methodName); 317if (PerformanceCounters.PerformanceCountersEnabled) 321PerformanceCounters.MethodReturnedError(methodName); 325PerformanceCounters.MethodReturnedFault(methodName); 329PerformanceCounters.MethodReturnedSuccess(methodName);
System\ServiceModel\Dispatcher\AuthenticationBehavior.cs (2)
69if (PerformanceCounters.PerformanceCountersEnabled) 71PerformanceCounters.AuthenticationFailed(rpc.Request, rpc.Channel.ListenUri);
System\ServiceModel\Dispatcher\AuthorizationBehavior.cs (2)
73if (PerformanceCounters.PerformanceCountersEnabled) 75PerformanceCounters.AuthorizationFailed(rpc.Operation.Name);
System\ServiceModel\Dispatcher\ChannelDispatcher.cs (1)
471if (PerformanceCounters.PerformanceCountersEnabled)
System\ServiceModel\Dispatcher\EndpointDispatcher.cs (3)
83if (PerformanceCounters.PerformanceCountersEnabled) 295if (PerformanceCounters.PerformanceCountersEnabled) 297PerformanceCounters.ReleasePerformanceCountersForEndpoint(this.perfCounterId, this.perfCounterBaseId);
System\ServiceModel\Dispatcher\SyncMethodInvoker.cs (6)
102if (PerformanceCounters.PerformanceCountersEnabled) 104PerformanceCounters.MethodCalled(this.MethodName); 188if (PerformanceCounters.PerformanceCountersEnabled) 198PerformanceCounters.MethodReturnedSuccess(this.MethodName, elapsedTime); 202PerformanceCounters.MethodReturnedFault(this.MethodName, elapsedTime); 206PerformanceCounters.MethodReturnedError(this.MethodName, elapsedTime);
System\ServiceModel\Dispatcher\TransactionBehavior.cs (13)
242if (PerformanceCounters.PerformanceCountersEnabled) 244PerformanceCounters.TxFlowed(PerformanceCounters.GetEndpointDispatcher(), rpc.Operation.Name); 994if (PerformanceCounters.PerformanceCountersEnabled) 996this.endpointDispatcher = PerformanceCounters.GetEndpointDispatcher(); 1023if (PerformanceCounters.PerformanceCountersEnabled) 1025PerformanceCounters.TxCommitted(this.endpointDispatcher, CallCount); 1033if (PerformanceCounters.PerformanceCountersEnabled) 1035PerformanceCounters.TxCommitted(this.endpointDispatcher, CallCount); 1042if (PerformanceCounters.PerformanceCountersEnabled) 1044PerformanceCounters.TxAborted(this.endpointDispatcher, CallCount); 1060if (PerformanceCounters.PerformanceCountersEnabled) 1062PerformanceCounters.TxInDoubt(this.endpointDispatcher, CallCount);
System\ServiceModel\Security\NegotiationTokenAuthenticator.cs (2)
835if (PerformanceCounters.PerformanceCountersEnabled && null != this.ListenUri) 837PerformanceCounters.AuthenticationFailed(request, this.ListenUri);
System\ServiceModel\Security\SecurityProtocol.cs (2)
820if (PerformanceCounters.PerformanceCountersEnabled && null != this.factory.ListenUri) //service side 825PerformanceCounters.AuthenticationFailed(message, this.factory.ListenUri);