Exemple #1
0
        public PooledCouchConveyor(IDispatcherFactory <CouchConveyEntry <T> > factory, int workers = 1, int capacity = 0)
            : base(factory, workers, capacity)
        {
            if (factory == null)
            {
                throw new ArgumentNullException("factory");
            }

            // TODO: Extract this if we need to customize MyCouch
            this.MyCouchClientBootstrapper = new MyCouchClientBootstrapper();
            this.Serializer = this.MyCouchClientBootstrapper.SerializerFn();
        }
Exemple #2
0
 public PooledDispatcherManager(IDispatcherFactory <T> factory, int workers = 1, int capacity = 0)
 {
     _dispatcher_factory = factory;
     _working_queue      = new ConcurrentWorkingQueue <T>(capacity);
     this.Workers        = workers;
 }