Skip to content

Conversation

@22aronl
Copy link

@22aronl 22aronl commented Dec 8, 2025

Changes

Replaced Error with warn logging to the decode of BalloonStats if unknown tag is introduced. Additionally, updated integration test of BalloonStats to fail if this warn occurs.

The Result type from the update method is removed and corresponding update metrics have been removed as it is no longer tracked.

Reason

Attempting to resolve Issue 5542

License Acceptance

By submitting this pull request, I confirm that my contribution is made under
the terms of the Apache 2.0 license. For more information on following Developer
Certificate of Origin and signing off your commits, please check
CONTRIBUTING.md.

PR Checklist

  • I have read and understand CONTRIBUTING.md.
  • I have run tools/devtool checkbuild --all to verify that the PR passes
    build checks on all supported architectures.
  • I have run tools/devtool checkstyle to verify that the PR passes the
    automated style checks.
  • I have described what is done in these changes, why they are needed, and
    how they are solving the problem in a clear and encompassing way.
  • I have updated any relevant documentation (both in code and in the docs)
    in the PR.
  • I have mentioned all user-facing changes in CHANGELOG.md.
  • If a specific issue led to this PR, this PR closes the issue.
  • When making API changes, I have followed the
    Runbook for Firecracker API changes.
  • I have tested all new and changed functionalities in unit tests and/or
    integration tests.
  • I have linked an issue to every new TODO.

  • This functionality cannot be added in rust-vmm.

@codecov
Copy link

codecov bot commented Dec 9, 2025

Codecov Report

❌ Patch coverage is 0% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 83.23%. Comparing base (d130c7d) to head (5cd0e68).
⚠️ Report is 2 commits behind head on main.

⚠️ Current head 5cd0e68 differs from pull request most recent head 7c8a9a4

Please upload reports for the commit 7c8a9a4 to get more accurate results.

Files with missing lines Patch % Lines
src/vmm/src/devices/virtio/balloon/device.rs 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5572      +/-   ##
==========================================
- Coverage   83.24%   83.23%   -0.01%     
==========================================
  Files         277      277              
  Lines       29263    29265       +2     
==========================================
  Hits        24359    24359              
- Misses       4904     4906       +2     
Flag Coverage Δ
5.10-m5n.metal 83.56% <0.00%> (-0.02%) ⬇️
5.10-m6a.metal 82.91% <0.00%> (-0.01%) ⬇️
5.10-m6g.metal 80.18% <0.00%> (-0.01%) ⬇️
5.10-m6i.metal 83.57% <0.00%> (-0.01%) ⬇️
5.10-m7a.metal-48xl 82.90% <0.00%> (-0.01%) ⬇️
5.10-m7g.metal 80.18% <0.00%> (-0.01%) ⬇️
5.10-m7i.metal-24xl 83.54% <0.00%> (-0.02%) ⬇️
5.10-m7i.metal-48xl 83.54% <0.00%> (-0.02%) ⬇️
5.10-m8g.metal-24xl 80.18% <0.00%> (-0.02%) ⬇️
5.10-m8g.metal-48xl 80.18% <0.00%> (-0.01%) ⬇️
6.1-m5n.metal 83.60% <0.00%> (-0.01%) ⬇️
6.1-m6a.metal 82.94% <0.00%> (-0.02%) ⬇️
6.1-m6g.metal 80.18% <0.00%> (-0.01%) ⬇️
6.1-m6i.metal 83.60% <0.00%> (-0.01%) ⬇️
6.1-m7a.metal-48xl 82.92% <0.00%> (-0.01%) ⬇️
6.1-m7g.metal 80.18% <0.00%> (-0.02%) ⬇️
6.1-m7i.metal-24xl 83.61% <0.00%> (-0.01%) ⬇️
6.1-m7i.metal-48xl 83.61% <0.00%> (-0.02%) ⬇️
6.1-m8g.metal-24xl 80.18% <0.00%> (-0.01%) ⬇️
6.1-m8g.metal-48xl 80.18% <0.00%> (-0.02%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

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

@JackThomson2
Copy link
Contributor

Thank you for your contribution looks good. Just a couple of minor comments

@22aronl 22aronl force-pushed the balloon-stat-warn branch 2 times, most recently from 68f2864 to 5cd0e68 Compare December 9, 2025 19:39
@22aronl
Copy link
Author

22aronl commented Dec 9, 2025

Thank you @JackThomson2 for the review!

I have addressed your comments. Please take another look when you have time!

JackThomson2
JackThomson2 previously approved these changes Dec 10, 2025
@JackThomson2 JackThomson2 added the Status: Awaiting review Indicates that a pull request is ready to be reviewed label Dec 10, 2025
@JackThomson2 JackThomson2 enabled auto-merge (rebase) December 10, 2025 14:18
@JackThomson2 JackThomson2 self-requested a review December 10, 2025 14:24
Added warn logging to the decode of BalloonStats if unknown tag is
introduced. Additionally, updated integration test of BalloonStats to
fail if this warn occurs.

The Result type from the update method is removed and corresponding
update metrics have been removed as it is no longer tracked.

Signed-off-by: Aaron Lo <aaronlo0929@gmail.com>
@22aronl
Copy link
Author

22aronl commented Dec 11, 2025

Thank you for the comments!

I dropped the Result type from update_with_stat. This has resulted in the removal of tracking fields of failed stats update in 2 metric files (as they are no longer being used). An alternate solution could be moving the stats_update_fails for BalloonDeviceMetrics into the update_with_stat method. Let me know if that or the current solution is fine (or another). Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Status: Awaiting review Indicates that a pull request is ready to be reviewed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants