feat(client): gate native backends behind Cargo features#1338
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR refactors ironrdp-client to make protocol/native backends opt-in via Cargo features (no default features) and introduces a typed Config/ConfigBuilder API, while moving .rdp/CLI parsing responsibilities into the viewer frontend.
Changes:
- Add
Config,Features, andConfigBuilderinironrdp-client, including runtime feature gates (with_sound(bool),with_clipboard(bool), etc.). - Gate optional channel wiring (sound/clipboard/rdpdr/gateway/DVC integrations) behind Cargo features in the client engine.
- Update
ironrdp-viewerto parse inputs in two phases (parse_inputs+build_config) and wire clipboard backend factories into the new config.
Reviewed changes
Copilot reviewed 7 out of 8 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| crates/ironrdp-viewer/src/main.rs | Switch to new parsing/build flow and wire clipboard backend factory into Config. |
| crates/ironrdp-viewer/src/config.rs | Replace PartialConfig with ParsedInputs + build_config using ConfigBuilder. |
| crates/ironrdp-viewer/Cargo.toml | Enable new ironrdp-client feature matrix and add needed deps/features wiring. |
| crates/ironrdp-client/src/rdp.rs | Gate imports/channel wiring behind features; refactor connection setup and optional channels. |
| crates/ironrdp-client/src/lib.rs | Re-export PropertySet for consumers/frontends. |
| crates/ironrdp-client/src/config.rs | Introduce ConfigBuilder, runtime feature flags, and backend override slots. |
| crates/ironrdp-client/Cargo.toml | Remove default features; add feature matrix and optional deps. |
| Cargo.lock | Lockfile updates for new deps (whoami, ironrdp-propertyset, ironrdp-cfg, etc.). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
3652726 to
cf137d7
Compare
cf137d7 to
3c3058b
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 15 out of 16 changed files in this pull request and generated 1 comment.
Comments suppressed due to low confidence (1)
crates/ironrdp-viewer/src/lib.rs:14
pub mod clipboard;was removed, butsrc/clipboard.rsstill exists in the crate (and now duplicates the similarly named proxy that moved intoironrdp-client). Since the module is no longer referenced, the file is effectively dead code and can confuse future maintenance; consider deletingcrates/ironrdp-viewer/src/clipboard.rs(or re-adding the module if it’s still intended to be part of the viewer API).
#![allow(clippy::cast_sign_loss)]
pub mod app;
pub mod config;
Vladyslav Nikonov (vnikonov-devolutions)
approved these changes
Jun 29, 2026
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.
ironrdp (meta crate):
client-rdpdr, client-smartcard, client-gateway,
client-dvc-pipe-proxy, client-dvc-com-plugin, and
top-level rustls / native-tls (forwarded to ironrdp-client)
ironrdp-client:
dvc-pipe-proxy, dvc-com-plugin, all; optional
subsystem crates are pulled in only via these features
stay mutually exclusive (exactly one required), and
qoi / qoiz now point at ironrdp-connector / ironrdp-session
ironrdp-viewer:
qoi / qoiz features
ironrdp-client; pulls client + client-all from the meta crate