예제 #1
0
        private void UpdateReplicationPerformance(SqlReplicationConfig replicationConfig, DateTime startTime, TimeSpan elapsed, int batchSize)
        {
            var performance = new SqlReplicationPerformanceStats
            {
                BatchSize = batchSize,
                Duration  = elapsed,
                Started   = startTime
            };

            var sqlReplicationMetricsCounters = GetSqlReplicationMetricsManager(replicationConfig);

            sqlReplicationMetricsCounters.ReplicationPerformanceStats.Enqueue(performance);
            while (sqlReplicationMetricsCounters.ReplicationPerformanceStats.Count() > 25)
            {
                SqlReplicationPerformanceStats _;
                sqlReplicationMetricsCounters.ReplicationPerformanceStats.TryDequeue(out _);
            }
        }
예제 #2
0
 protected bool Equals(SqlReplicationPerformanceStats other)
 {
     return(BatchSize == other.BatchSize && Duration.Equals(other.Duration) && Started.Equals(other.Started));
 }
예제 #3
0
		private void UpdateReplicationPerformance(SqlReplicationConfig replicationConfig, DateTime startTime, TimeSpan elapsed, int batchSize)
		{
			var performance = new SqlReplicationPerformanceStats
			{
				BatchSize = batchSize,
				Duration = elapsed,
				Started = startTime
			};

			var sqlReplicationMetricsCounters = GetSqlReplicationMetricsManager(replicationConfig);
			sqlReplicationMetricsCounters.ReplicationPerformanceStats.Enqueue(performance);
			while (sqlReplicationMetricsCounters.ReplicationPerformanceStats.Count() > 25)
			{
				SqlReplicationPerformanceStats _;
				sqlReplicationMetricsCounters.ReplicationPerformanceStats.TryDequeue(out _);
			}
		}
 protected bool Equals(SqlReplicationPerformanceStats other)
 {
     return BatchSize == other.BatchSize && Duration.Equals(other.Duration) && Started.Equals(other.Started);
 }