TimelyDataflow / TimelyDataflow/timely-dataflow
Consider marking streams as `MustUse`.
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 3.6k
- Forks
- 293
- Avg merge
- 14h 46m
- Merged PRs (30d)
- 4
Description
It is a bit of a smell to have unused timely dataflow streams. They are not harmful (data terminate at operators that are not used, rather than eagerly cloned for an unused stream), but it is odd to create one and not use it. We could mark them as MustUse which will at least warn if streams are created and then dropped without being used.
The main downside seems to be that it would introduce warning noise to all timely projects, as e.g. the pattern
mystream
.do_stuff()
.probe_with(&mut probe);
ends with a stream (probe_with outputs its input stream, after the probe has been updated). Perhaps we'd want a .cap() method to make it easy to remove the error. Putting a let _ = at the beginning of each of these pipelines might be annoying. Anyhow, food for thought.
cc: @benesch
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the stream-producing APIs and the probe_with pipeline pattern described in the issue. Determine the project-wide impact of marking streams MustUse and how unused returned streams should be handled. Done requires an agreed design that avoids warning noise while providing the proposed unused-stream warning.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- distributed-systems
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100