Пример #1
0
 public CollectTaskAccessProxy(
     ICollectTaskRepository taskRepository,
     ICollectContentRepository contentRepository)
 {
     this._taskRepository    = taskRepository;
     this._contentRepository = contentRepository;
 }
Пример #2
0
 public CollectTaskRuntime(
     ICollectRepository collectDal,
     ICollectTaskRepository collectTaskDal,
     ILogger logger,
     IConfiguration config)
 {
     this._config         = config;
     this._collectDal     = collectDal;
     this._collectTaskDal = collectTaskDal;
     this._logger         = logger;
     this._sh             = new Semaphore(int.Parse(this._config["task:parallelTasks"]), int.Parse(this._config["task:parallelTasks"]));
     this._invokers       = new Queue <CollectTaskInvoker>();
     this._lock           = new ReaderWriterLockSlim();
     this._retry          = int.Parse(this._config["task:errorRepeat"]);
     this.State           = new CollectTaskState();
 }