TimelyDataflow / differential-dataflow

An implementation of differential dataflow using timely dataflow on Rust.
MIT License
2.58k stars 184 forks source link

trace: let set_{logical,physical}_compaction take arguments equal to … #339

Closed ruchirK closed 3 years ago

ruchirK commented 3 years ago

…or beyond current frontier.

This commit changes the requirements set_{logical,physical}_compaction methods to match those of Capability::downgrade. Now, these methods all accept arguments equal to or beyond the most recent argument passed, or initial value if the function was never called before.

Also added a debug assert to make sure the logical compaction only advances.

ruchirK commented 3 years ago

cc: @frankmcsherry this is the thing we discussed on Monday. I looked through the code for callers of set_logical_compaction / set_physical_compaction -- I didn't find anything that enforced the old strictly greater than invariant.

frankmcsherry commented 3 years ago

Ah, this might come down to "beyond" being underspecified. It was introduced when folks didn't like "in advance of" and was meant to mean "greater than or equal to" but .. looks like it was just as confusing in a different way.