Skip to content

chore(unit tests): failing disk_v2 bug demonstrations#25525

Draft
blt wants to merge 1 commit into
blt/antithesis-researchfrom
blt/antithesis-bug-demonstration-tests
Draft

chore(unit tests): failing disk_v2 bug demonstrations#25525
blt wants to merge 1 commit into
blt/antithesis-researchfrom
blt/antithesis-bug-demonstration-tests

Conversation

@blt
Copy link
Copy Markdown
Contributor

@blt blt commented May 29, 2026

Summary

Seven vector-buffers tests that assert the correct invariant and therefore
fail against current Vector, each reproducing a real disk buffer v2 data-loss
or accounting defect. The failures are the demonstration — CI on this PR is
expected to be red on these tests until the underlying bugs are fixed.

Test Bug
drop_newest_drops_should_increment_component_discarded_metric_issue_24606 #24606 — drops never hit component_discarded_events_total
ledger_total_buffer_size_decrement_should_saturate_not_underflow_issue_21683 #21683 — unsaturated decrement wraps → writer deadlock
get_total_records_should_be_zero_on_drained_buffer_issue_21683_metrics get_total_records 0-1 underflow on a drained buffer
writer_drop_without_flush_should_not_lose_buffered_events_issue_24948 #24948 — writer Drop without flush loses buffered events
rejected_delivery_should_not_advance_acks_finalizer_status_discard finalizer discards BatchStatus; a rejected delivery still advances acks
file_id_rollover_compare_should_be_wrap_aware_reader_932 reader.rs:932 file-id comparison not wrap-aware
delete_completed_data_file_size_delta_should_saturate_reader_524 reader.rs:524 metadata.len() - bytes_read underflow

Stack (Antithesis-driven disk buffer v2 data-loss investigation):

How did you test this PR?

cargo nextest run -p vector-buffers → exactly these 7 fail (78 pass), each for the
documented reason. Independent of the rest of the stack (no Antithesis deps needed).

Change Type

  • Bug fix
  • New feature
  • Dependencies
  • Non-functional (chore, refactoring, docs) — tests only
  • Performance

Is this a breaking change?

  • Yes
  • No

Does this PR include user facing changes?

  • Yes.
  • No. A maintainer will apply the no-changelog label to this PR.

References

Copy link
Copy Markdown
Contributor Author

blt commented May 29, 2026

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

This stack of pull requests is managed by Graphite. Learn more about stacking.

@blt blt added the no-changelog Changes in this PR do not need user-facing explanations in the release changelog label May 29, 2026
@blt blt force-pushed the blt/antithesis-research branch from 1ceda6a to b0a9285 Compare May 29, 2026 17:44
@blt blt force-pushed the blt/antithesis-bug-demonstration-tests branch from 579bdea to 3bb6d14 Compare May 29, 2026 17:44
@blt blt changed the title test(vector-buffers): failing disk_v2 bug demonstrations chore(unit tests): failing disk_v2 bug demonstrations May 29, 2026
@datadog-vectordotdev
Copy link
Copy Markdown

datadog-vectordotdev Bot commented May 29, 2026

Tests

Fix all issues with Cursor

⚠️ Warnings

🧪 7 Tests failed

buffer_usage_data::tests::drop_newest_drops_should_increment_component_discarded_metric_issue_24606 from vector-buffers   View in Datadog   (Fix with Cursor)
Test has failed
variants::disk_v2::tests::acknowledgements::rejected_delivery_should_not_advance_acks_finalizer_status_discard from vector-buffers   View in Datadog   (Fix with Cursor)
Test has failed
variants::disk_v2::tests::invariants::delete_completed_data_file_size_delta_should_saturate_reader_524 from vector-buffers   View in Datadog   (Fix with Cursor)
Test has failed
View all

ℹ️ Info

No other issues found (see more)

❄️ No new flaky tests detected

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 84f01cb | Docs | Give us feedback!

@blt blt force-pushed the blt/antithesis-bug-demonstration-tests branch from 3bb6d14 to 7ce6082 Compare May 29, 2026 18:29
@blt blt force-pushed the blt/antithesis-research branch from b0a9285 to 340ba97 Compare May 29, 2026 18:29
Seven tests that assert the CORRECT invariant and therefore FAIL against current
Vector, each reproducing a real disk_v2 data-loss / accounting bug: #24606
(component drop metric), #21683 (total_buffer_size decrement underflow),
get_total_records 0-1 underflow, #24948 (writer drop loses buffered events),
finalizer status-discard (rejected delivery acked), reader.rs:932 file-id rollover,
reader.rs:524 size-delta underflow. Runnable with plain cargo test -p vector-buffers.
@blt blt force-pushed the blt/antithesis-bug-demonstration-tests branch from 7ce6082 to 84f01cb Compare May 29, 2026 18:39
@blt blt force-pushed the blt/antithesis-research branch from 340ba97 to 7c97a68 Compare May 29, 2026 18:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no-changelog Changes in this PR do not need user-facing explanations in the release changelog

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant