public static void Increment(string counterName) { if (!RepositoryConfiguration.PerformanceCountersEnabled) return; var counter = CounterManager.Current.GetCounter(counterName); if (counter != null) counter.Increment(); }