Beispiel #1
0
 internal OverflowQueue(SharedRingBufferMailbox parent)
 {
     backoff     = new Backoff();
     messages    = new Queue <IMessage>();
     open        = false;
     this.parent = parent;
 }
Beispiel #2
0
 internal RingBufferDispatcher(int mailboxSize, long fixedBackoff, int throttlingCount)
 {
     closed  = new AtomicBoolean(false);
     backoff = fixedBackoff == 0L ? new Backoff() : new Backoff(fixedBackoff);
     RequiresExecutionNotification = fixedBackoff == 0L;
     Mailbox = new SharedRingBufferMailbox(this, mailboxSize);
     this.throttlingCount = throttlingCount;
 }
Beispiel #3
0
 internal RingBufferDispatcher(int mailboxSize, long fixedBackoff, bool notifyOnSend, int throttlingCount)
 {
     _closed  = new AtomicBoolean(false);
     _backoff = fixedBackoff == 0L ? new Backoff() : new Backoff(fixedBackoff);
     RequiresExecutionNotification = fixedBackoff == 0L;
     Mailbox                = new SharedRingBufferMailbox(this, mailboxSize, notifyOnSend);
     _throttlingCount       = throttlingCount;
     _dispatcherTokenSource = new CancellationTokenSource();
     _backoffTokenSource    = CancellationTokenSource.CreateLinkedTokenSource(_dispatcherTokenSource.Token);
 }