public OneToOneSequencedLongArrayThroughputTest()
 {
     _ringBuffer = RingBuffer<long[]>.CreateSingleProducer(() => new long[_arraySize], _bufferSize, new YieldingWaitStrategy());
     var sequenceBarrier = _ringBuffer.NewBarrier();
     _handler = new LongArrayEventHandler();
     _batchEventProcessor = new BatchEventProcessor<long[]>(_ringBuffer, sequenceBarrier, _handler);
     _ringBuffer.AddGatingSequences(_batchEventProcessor.Sequence);
 }
Exemple #2
0
        public OneToOneSequencedLongArrayThroughputTest()
        {
            _ringBuffer = RingBuffer <long[]> .CreateSingleProducer(() => new long[_arraySize], _bufferSize, new YieldingWaitStrategy());

            var sequenceBarrier = _ringBuffer.NewBarrier();

            _handler             = new LongArrayEventHandler();
            _batchEventProcessor = BatchEventProcessorFactory.Create(_ringBuffer, sequenceBarrier, _handler);
            _ringBuffer.AddGatingSequences(_batchEventProcessor.Sequence);
        }