Dispatcher() public abstract method

Returns a Dispatcher instance. Whether or not this MessageDispatcherConfigurator returns a new instance or returns a reference to an existing instance is an implementation detail of the underlying implementation.
public abstract Dispatcher ( ) : MessageDispatcher
return MessageDispatcher
Ejemplo n.º 1
0
        public override MessageDispatcher Dispatcher()
        {
            var dispatcher = _configurator.Dispatcher();

            dispatcher.Id                     = Id;
            dispatcher.Throughput             = Throughput;
            dispatcher.ThroughputDeadlineTime = ThroughputDeadlineTime > 0 ? ThroughputDeadlineTime : null;
            return(dispatcher);
        }
Ejemplo n.º 2
0
 public void Setup(BenchmarkContext context)
 {
     _configurator = Configurator();
     _dispatcher = _configurator.Dispatcher();
     _dispatcherCounter = context.GetCounter(DispatcherCounterName);
     ScheduledWork = () =>
     {
         _dispatcherCounter.Increment();
         if (Interlocked.Increment(ref _messagesSeen) == ScheduleCount)
         {
             EventBlock.Set();
         }
     };
     Warmup(_dispatcher);
 }
 public void Setup(BenchmarkContext context)
 {
     Sys = ActorSystem.Create("Sys");
     Prereqs = new DefaultDispatcherPrerequisites(Sys.EventStream, Sys.Scheduler, Sys.Settings, Sys.Mailboxes);
     _configurator = Configurator();
     _dispatcher = _configurator.Dispatcher();
     _dispatcherCounter = context.GetCounter(DispatcherCounterName);
     ScheduledWork = () =>
     {
         _dispatcherCounter.Increment();
         if (Interlocked.Increment(ref _messagesSeen) == ScheduleCount)
         {
             EventBlock.Set();
         }
     };
     Warmup(_dispatcher);
 }