Beispiel #1
0
 void Q_ErrorOccured(object sender, QueueItemEventArgs e)
 {
     if (AgentManager.Settings.EnablePerformanceCounter)
     {
         Task.Factory.StartNew(() => m_Perfmon.AddStateCounter(e.State));
     }
 }
Beispiel #2
0
 protected virtual void OnErrorOccured(QueueItemEventArgs e)
 {
     if (ErrorOccured != null)
     {
         ErrorOccured(this, e);
     }
 }
Beispiel #3
0
 protected virtual void OnTransEnd(QueueItemEventArgs e)
 {
     if (TransactionEnd != null)
     {
         TransactionEnd(this, e);
     }
 }
Beispiel #4
0
 protected virtual void OnTransBegin(QueueItemEventArgs e)
 {
     if (TransactionBegin != null)
     {
         TransactionBegin(this, e);
     }
 }
Beispiel #5
0
 protected virtual void OnMessageReceived(QueueItemEventArgs e)
 {
     if (MessageReceived != null)
     {
         MessageReceived(this, e);
     }
 }
Beispiel #6
0
 protected void OnMessageArrived(QueueItemEventArgs e)
 {
     if (MessageArrived != null)
     {
         MessageArrived(this, e);
     }
 }
Beispiel #7
0
 void Q_MessageTransEnd(object sender, QueueItemEventArgs e)
 {
     //TODO:FIX
     //if (e.State == ItemState.Wait)
     //{
     //    ReEnqueue(e.Item);
     //}
 }
Beispiel #8
0
 /// <summary>
 /// OnMessageReceived
 /// </summary>
 /// <param name="e"></param>
 void OnMessageReceived(QueueItemEventArgs e)
 {
     LogActionInfo("OnMessageReceived", e.Message);
     if (MessageReceived != null)
     {
         MessageReceived(this, e);
     }
 }
Beispiel #9
0
        void Q_MessageReceived(object sender, QueueItemEventArgs e)
        {
            //if (base.CoverMode > CoverMode.None)
            //{
            //    OnCoverQueueItem(e.Item, e.State);//IsTrans ? ItemState.Wait : ItemState.Dequeue);
            //}

            if (AgentManager.Settings.EnablePerformanceCounter)
            {
                Task.Factory.StartNew(() => m_Perfmon.AddDequeue(0));
            }

            OnMessageReceived(e);// OnDequeueMessage(e);
        }
Beispiel #10
0
        void Q_MessageArrived(object sender, QueueItemEventArgs e)
        {
            //if (base.CoverMode > CoverMode.None)
            //{
            //    //Console.WriteLine("OnEnqueueMessage");

            //    OnCoverQueueItem(e.Item, e.State);
            //    //AsyncQueueWorker(e.Item);
            //}

            //if (_Coverable)
            //{
            //    _QCover.Save(e.Item);
            //}

            if (AgentManager.Settings.EnablePerformanceCounter)
            {
                Task.Factory.StartNew(() => m_Perfmon.AddEnqueue(0));
            }

            OnMessageArraived(e);// OnEnqueueMessage(e); //normalQ.Dequeue();
        }
Beispiel #11
0
 protected override void OnMessageReceived(QueueItemEventArgs e)
 {
     base.OnMessageReceived(e);
     QLogger.Info("PriorityMemQueue OnMessageReceived : Host:{0}, Item:{1}", this.Name, e.Item.Print());
 }
Beispiel #12
0
 protected override void OnErrorOccured(QueueItemEventArgs e)
 {
     base.OnErrorOccured(e);
     QLogger.Info("PriorityMemQueue OnError : Host:{0}, message:{1}", this.Name, e.Message);
 }
Beispiel #13
0
 protected override void OnMessageArrived(QueueItemEventArgs e)
 {
     base.OnMessageArrived(e);
     QLogger.InfoFormat("PriorityPersistQueue OnMessageArrived : Host:{0}, Item:{1}", this.Name, e.Item.Print());
 }
Beispiel #14
0
 void Q_MessageTransBegin(object sender, QueueItemEventArgs e)
 {
     //TODO:FIX
     //TransBegin(e.Item);
     //base.TransBegin(e.Item);
 }
Beispiel #15
0
 protected override void OnErrorOccured(QueueItemEventArgs e)
 {
     base.OnErrorOccured(e);
     QLogger.InfoFormat("PriorityPersistQueue OnError : Host:{0}, message:{1}", this.Host, e.Message);
 }