Skip to content

Hyper-V API: Plan9 shares feature#4723

Draft
xmkg wants to merge 314 commits intofeature/hyperv-api-backend-virtual-machinefrom
feature/hyperv-api-plan9-shares
Draft

Hyper-V API: Plan9 shares feature#4723
xmkg wants to merge 314 commits intofeature/hyperv-api-backend-virtual-machinefrom
feature/hyperv-api-plan9-shares

Conversation

@xmkg
Copy link
Member

@xmkg xmkg commented Mar 11, 2026

xmkg added 30 commits March 11, 2026 10:57
also add a couple non-std::error_code overloads. mark some of the
std::error_code overloads noexcept.

updated the test code.
Also, simplify boilerplate code by wrapping MockFuncion with StrictMock
which allows us to eliminate the need for EXPECT_NO_CALL stubs.
[hyperv_test_utils] improve make_tempfile_path
- move GUID formatter to the platform_win.h header
- update unit test usages
- Introduce two new types, HcsScsiDevice & HcsScsiDeviceType
- Provide proper formatting for the HcsScsiDevice
- Remove vhdx_path & cloudinit_iso_path variables from create params
- Introduce scsi_devices paraneter to create params
- Update the code that refers to the vhdx_path & cloudinit_iso_path
- replace "endpoints" with "network_adapters" in create params
- Introduce new HcsNetworkAdapter type
- Implement proper JSON formatter for HcsNetworkAdapter
- Update relevant references in code
- add_endpoint function now takes compute system name as the rest of
  the API does
- Updated code references
to simplify the interaction between the smart pointers and the C API
a lean out_ptr type is implemented based on P1132R6 paper, which is
already accepted into the C++23 standard.

- open_host_compute_system and create_host_compute system now uses the
  out_ptr to avoid creating a temporary raw pointer for the API calls.
- update one more location that has been missed
modify_compute_system is the generic function for doing runtime CS
modification.
xmkg added 25 commits March 11, 2026 10:58
- Use c++20 designated initializers to avoid IILEs
- removed redundant instance_guid filed from HcsNetworkAdapter
- Add ASSERT_THROW for suspend failure test as it throws now on pause fail.
It'll be introduced later in a separate branch.
These two functions allow querying info about HCN networks. Filtering
networks through win32 API is a bit guesswork so let's do it in the
intended way.
Also added integration tests for the query_network and enumerate_networks
Now the networks() call return vSwitches and links populated properly
the prepare_networking() function works as intended and the custom net
setup code is no longer necessary.
It'll be introduced in a separate branch.
@xmkg xmkg changed the title Revert "[hyperv-hcs] Remove Plan9 code" Hyper-V API: Plan9 shares feature Mar 11, 2026
@codecov
Copy link

codecov bot commented Mar 11, 2026

Codecov Report

❌ Patch coverage is 92.30769% with 1 line in your changes missing coverage. Please review.
⚠️ Please upload report for BASE (feature/hyperv-api-backend-virtual-machine@d07c2bb). Learn more about missing BASE report.

Files with missing lines Patch % Lines
...rc/platform/backends/qemu/qemu_virtual_machine.cpp 75.00% 1 Missing ⚠️
Additional details and impacted files
@@                              Coverage Diff                              @@
##             feature/hyperv-api-backend-virtual-machine    #4723   +/-   ##
=============================================================================
  Coverage                                              ?   87.67%           
=============================================================================
  Files                                                 ?      256           
  Lines                                                 ?    14113           
  Branches                                              ?        0           
=============================================================================
  Hits                                                  ?    12372           
  Misses                                                ?     1741           
  Partials                                              ?        0           

☔ 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.

@xmkg xmkg force-pushed the feature/hyperv-api-backend-virtual-machine branch 3 times, most recently from 4642fa0 to 3de21e5 Compare March 23, 2026 14:00
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.

1 participant