mirror of
https://github.com/scylladb/scylladb.git
synced 2026-06-03 21:47:10 +00:00
Now the nonforwardable reader unconditionally produces a partition_end, even if the input reader was empty. This is strange in itself, but it also hinders to properly fix its next_partition() method, which is our ultimate goal. So we are going to change this and produce partition_end only if there were some data in the stream. However, this makes a problem: now we pop partition_start from the underlying reader in autoupdating_underlying_reader::move_to_next_partition and manually push it back to downstream readers bypassing nonforwardable reader. This means if we change the logic in nonforwardable reader as described we will end up with partition_start without partition_end in the downstream readers. This patch rectifies this by making sure that nonforwardable will see the initial partition_start. We inject this partition_start just before the nonforwardable reader, into delegating_reader. This also makes the result type of range_populating_reader::operator() a bit simpler, we don't need to pass partition_start anymore.
57 KiB
57 KiB