net, stuntime, std: VM stuntime measurement during live migration#4056
net, stuntime, std: VM stuntime measurement during live migration#4056Anatw wants to merge 1 commit intoRedHatQE:mainfrom
Conversation
Introduce the STD for VM stuntime measurement during live migration on Linux bridge and OVN localnet secondary networks. These tests provide baseline measurements and a framework for regression detection. Baseline and Threshold: - Per-scenario threshold - setting the threshold to the minimum of (max_observed × 4) and 5 seconds — i.e. 4× the worst observed value for that scenario, capped at 5 seconds. - Thresholds will be hardcoded based on 10-run baselines per-scenario, on a BM cluster. - A per-scenario approach is used instead of a global threshold to prevent slow-path scenarios from masking regressions in faster ones. Measurement Methodology: - Ping command: ICMP ping at 100ms intervals with UNIX timestamps (`ping -D -O -i 0.1`). - Stuntime calculation: Stuntime is the largest gap between any two consecutive successful replies in the ping log - i.e., the maximum time difference between timestamps of successive successful packets. The boundaries (last success before loss, first success after recovery) are the pair of packets that define that gap. Stuntime = (Timestamp of first success after) - (Timestamp of last success before) - Alternatives rejected: tcping (introducing a new dependency), iperf3 (unnecessary complexity), and curl (unnecessary complexity - requires an active web server inside the VM). Both VMs start on the same node to align with the first scenario logic: migrating from the same node to a different node (static_to_different). Signed-off-by: Anat Wax <awax@redhat.com> Assisted by: Cursor
📝 WalkthroughWalkthroughA new test module is introduced with two test classes ( Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes 🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Report bugs in Issues Welcome! 🎉This pull request will be automatically processed with the following features: 🔄 Automatic Actions
📋 Available CommandsPR Status Management
Review & Approval
Testing & Validation
Container Operations
Cherry-pick Operations
Label Management
✅ Merge RequirementsThis PR will be automatically approved when the following conditions are met:
📊 Review ProcessApprovers and ReviewersApprovers:
Reviewers:
Available Labels
💡 Tips
For more information, please refer to the project documentation or contact the maintainers. |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@tests/network/stuntime/test_stuntime_measurement.py`:
- Around line 14-75: Add the suggested tier classification by marking the
stuntime tests with a tier3 pytest marker: update the
TestStuntimeLinuxBridge.test_stuntime and TestStuntimeOvnLocalnet.test_stuntime
(or their containing classes) to include `@pytest.mark.tier3` in addition to
existing markers so the live-migration/timing-heavy tests can be opt-in; ensure
the marker name is exactly tier3 to match repository conventions and keep the
existing polarion and other markers intact.
- Around line 49-75: The test function test_stuntime needs three edits: add the
`@pytest.mark.ipv4` decorator above def test_stuntime to match the docstring
marker; change the unicode multiplication sign "×" in the Expected threshold
description to a plain "x" (so use "min(max x 4, 5s)" wording); and remove the
test_stuntime.__test__ = False line and instead annotate the function with
`@pytest.mark.skip`(reason="placeholder/test disabled - add valid Polarion ID to
enable") to skip until a real Polarion ID is provided; also replace the
placeholder Polarion ID "CNV-00000" with the correct ID before removing the
skip.
|
D/S test |
| - ipv4 | ||
|
|
||
| Parametrize: | ||
| - migration_path: [static_to_different, different_to_static, between_different] |
There was a problem hiding this comment.
If I wasn't already familiar with the STP, I wouldn't understand what is said here.
Please add a short explanation so the path will be clear. Thanks
Short description:
Introduce the STD for VM stuntime measurement during live migration on Linux bridge and OVN localnet secondary networks. These tests provide baseline measurements and a framework for regression detection.
Special notes for reviewer:
Baseline and Threshold:
Measurement Methodology:
ping -D -O -i 0.1).Both VMs start on the same node to align with the first scenario logic: migrating from the same node to a different node (static_to_different).
Assisted by: Cursor
jira-ticket:
https://issues.redhat.com/browse/CNV-78677
Summary by CodeRabbit