Skip to content

Flowtable concurrent fuzz#1581

Draft
daniel-noland wants to merge 8 commits into
mainfrom
flowtable-concurrent-fuzz
Draft

Flowtable concurrent fuzz#1581
daniel-noland wants to merge 8 commits into
mainfrom
flowtable-concurrent-fuzz

Conversation

@daniel-noland
Copy link
Copy Markdown
Collaborator

This is a temp placeholder while I discuss with @sergeymatov. Ignore for now if you aren't @sergeymatov

sergeymatov and others added 7 commits June 1, 2026 16:31
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Signed-off-by: Sergey Matov <sergey.matov@githedgehog.com>
So bolero x model-checker suites can drive the same scheduler portfolio
and 4 MiB-stack config as #[concurrency::test] instead of hand-rolling a
Runner with shuttle's defaults.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
One source of truth for the stack size; the per-shape Runner was
silently using shuttle's ~60 KiB default.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
A single harness covers both the thread sanitizer and the shuttle
portfolio. Normalizing at generation keeps two threads inserting, so
PCT always sees real concurrency and no shape is skipped.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Only the fuzz harness ever called it, and it cannot run under shuttle
(DashMap::retain holds a real shard lock across a yield point). Also
switches two reshard-test asserts to assert_eq! for clippy.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
new_with_status delegates to new instead of duplicating fields; the
FlowStatus generator rejects out-of-range bytes rather than aliasing
them to Detached.
Exposes the TypeGenerator impls without each consumer opting in.
Comment thread net/src/flows/flow_info.rs Outdated
/// insert. Used by the bolero-driven concurrent-fuzz tests to seed flows in
/// any of the four legal states.
#[must_use]
pub fn new_with_status(flowkey: FlowKey, expires_at: Instant, status: FlowStatus) -> Self {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see you moved this code but seems it's not needed (not belong to fuzzer anymore)

/// a single direct run on the std backend (real OS threads — build with
/// `just test sanitize=thread`), or the full portfolio under shuttle.
#[test]
fn stress_test_concurrency_model() {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, I see. So we have a new abstraction on top that defines what runs, and how it's scheduled defines under the tests

/// Drain all stale (Expired / Cancelled / deadline-passed Active) entries from the table.
///
/// Returns the number of entries removed.
pub fn drain_stale(&self) -> usize {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for removing that

With new layout of fuzzer it's not needed anymore

Signed-off-by: Sergey Matov <sergey.matov@githedgehog.com>
@sergeymatov sergeymatov force-pushed the flowtable-concurrent-fuzz branch from 4f99e4c to 0ba4a4f Compare June 4, 2026 10:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants