openvmm/ttrpc/repl: Extend ttrpc interface and repl command list to support bind/unbind requests for consommé #3566
Open
damanm24 wants to merge 8 commits into
Open
openvmm/ttrpc/repl: Extend ttrpc interface and repl command list to support bind/unbind requests for consommé #3566damanm24 wants to merge 8 commits into
damanm24 wants to merge 8 commits into
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Extends the Consomme networking backend to support runtime port-forward bind/unbind requests (via a mesh channel), and wires this capability into OpenVMM’s ttrpc VMService API and the interactive REPL so ports can be managed after VM creation.
Changes:
- Add a cross-proc Consomme port request channel (
ConsommeRequest) and plumb it throughConsommeHandleto the net_consomme endpoint. - Update net_consomme to handle initial port forwards plus runtime bind/unbind requests (creating/binding host sockets on demand).
- Extend the ttrpc proto and OpenVMM REPL command set to expose bind/unbind operations.
Reviewed changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| vm/devices/net/net_consomme/src/resolver.rs | Switch Consomme endpoint construction to optionally enable runtime port request handling via an injected receiver. |
| vm/devices/net/net_consomme/src/lib.rs | Replace pre-bound socket forwarding with on-demand socket binding; add runtime bind/unbind request processing path. |
| vm/devices/net/net_backend_resources/src/lib.rs | Introduce ConsommeRequest and add an optional runtime request receiver to ConsommeHandle. |
| petri/src/vm/openvmm/modify.rs | Update ConsommeHandle construction to include the new recv field (set to None). |
| openvmm/openvmm_ttrpc_vmservice/src/vmservice.proto | Add port-forwarding types (IpProtocol, PortConfig) and extend ConsommeBackend with ports. |
| openvmm/openvmm_entry/src/ttrpc/mod.rs | Add a Consomme port request sender to VM state and implement ModifyResource-based bind/unbind operations. |
| openvmm/openvmm_entry/src/repl.rs | Add bind-port / unbind-port REPL commands that send Consomme bind/unbind requests. |
| openvmm/openvmm_entry/src/lib.rs | Create and retain a Consomme port request sender for REPL-driven runtime port operations (CLI path). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR builds on top of the work done in #3364 by extending OpenVMM's ttrpc interface to include port-forwarding commands. I also ended up adding the bind/unbind port commands to OpenVMM's REPL command list when testing the changes.