Skip to content

Conversation

danlaine
Copy link
Collaborator

@danlaine danlaine commented May 29, 2025

Adds metrics to the io_uring

@danlaine danlaine self-assigned this May 29, 2025
}

#[tokio::test(flavor = "multi_thread", worker_threads = 2)]
async fn test_force_poll_enabled() {
Copy link
Contributor

Choose a reason for hiding this comment

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

I think we should keep both tests and either:

  1. add a sleep between submitting recv/write (the retained test isn't guaranteed to test the timeout for the same reason the removed one is flaking)
  2. add a metric for outstanding work in iouring and poll on that being non-zero before submitting the next op (failing if it exceeds the timeout, which should never happen).

@danlaine danlaine force-pushed the danlaine/iouring-remove-racy-test branch from fcf20b2 to fa0d08a Compare May 30, 2025 16:44
@danlaine danlaine changed the title [runtime] remove racy test [runtime] add io_uring metrics; make test less flaky May 30, 2025
storage_directory: self.cfg.storage_directory.clone(),
ring_config: Default::default(),
}),
}, runtime_registry),
Copy link
Contributor

Choose a reason for hiding this comment

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

wonder if we should prefix with iouring-*?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

prefixed with "io_uring_storage". If you want something else lmk.

@danlaine danlaine requested a review from patrick-ogrady May 30, 2025 21:28
if #[cfg(feature = "iouring-network")] {
let network = MeteredNetwork::new(
IoUringNetwork::start(crate::iouring::Config::default()).unwrap(),
IoUringNetwork::start(crate::iouring::Config::default(),runtime_registry).unwrap(),
Copy link
Contributor

Choose a reason for hiding this comment

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

we should also prefix this with iouring_network

@patrick-ogrady patrick-ogrady merged commit 44a0087 into main May 30, 2025
13 checks passed
@patrick-ogrady patrick-ogrady deleted the danlaine/iouring-remove-racy-test branch May 30, 2025 22:04
Copy link

codecov bot commented May 30, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 90.97%. Comparing base (b4bb2dd) to head (798157f).
Report is 5 commits behind head on main.

@@            Coverage Diff             @@
##             main    #1023      +/-   ##
==========================================
+ Coverage   90.95%   90.97%   +0.02%     
==========================================
  Files         191      192       +1     
  Lines       53777    54094     +317     
==========================================
+ Hits        48912    49212     +300     
- Misses       4865     4882      +17     
Files with missing lines Coverage Δ
runtime/src/tokio/runtime.rs 83.47% <100.00%> (+0.09%) ⬆️

... and 9 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b4bb2dd...798157f. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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