Exemple #1
0
        private readonly int _nodeThrottling = NodeSettings.Instance.Throttling; //todo

        public TaskProcessingPipeline(ILogger logger, ITaskExecutorsPool taskRepository) : base(new TaskHandler(taskRepository))
        {
            var throttlingFilter = new TasksThrottlingFilter(_nodeThrottling, logger);

            RegisterFeatureDecorator(throttlingFilter);
            if (_nodeThrottling <= 0)
            {
                throttlingFilter.Disable();
            }
        }
Exemple #2
0
 public TaskHandler(ITaskExecutorsPool taskExecutorsPool)
 {
     _taskExecutorsPool = taskExecutorsPool;
 }