Esempio n. 1
0
        public AggregationSynopsisBase(ProcessMetricEvent outputEventCallback, AggregationSettings settings)
        {
            this.outputEventCallback = outputEventCallback;
            this.timeWindowQueueMap  = new Dictionary <AggregateGroupKey, TQueue>();
            this.OutputEventQueue    = new Queue <MetricEvent>();
            this.Settings            = settings;
            this.ThisLock            = new object();

            if (this.Settings.EnableExpirationClock)
            {
                this.clockGenerator = new ClockEventGenerator(settings.ExtraExpirationWaitTime);
                this.clockGenerator.ClockNotfication += new EventHandler(this.ClockNotfication);
            }
        }
Esempio n. 2
0
        void Dispose(bool disposing)
        {
            if (!this.disposed)
            {
                if (disposing)
                {
                    if (this.clockGenerator != null)
                    {
                        this.clockGenerator.Dispose();
                        this.clockGenerator = null;
                    }
                }

                this.disposed = true;
            }
        }