Actually the core part of LMAX's implementation is the Sequencer
and its Sequence
s. And so the ringBuffer
implement those. The gatingSequences
that you are referring to act as a cursor to each Sequencer
that is "Subscribed" to the targeted ringBuffer
(or other Sequencer
). So that's how a Sequencer
can have multiple cursors for its connected Sequencers
(and let them touch the next sequence
by just calling tryNext()
).
Cheers!