refactor(fuse): generate mount CLI overrides from FuseConf (#1619) - #1624
Merged
Conversation
szbr00
reviewed
Aug 26, 2026
szbr00
reviewed
Aug 26, 2026
lzjqsdd
force-pushed
the
unified-conf-p4
branch
3 times, most recently
from
August 26, 2026 06:33
6312bc0 to
4312939
Compare
lzjqsdd
force-pushed
the
unified-conf-p3
branch
from
August 26, 2026 06:37
7123817 to
c52cd9a
Compare
lzjqsdd
force-pushed
the
unified-conf-p4
branch
from
August 26, 2026 08:50
4312939 to
e48339b
Compare
lzjqsdd
force-pushed
the
unified-conf-p3
branch
from
August 26, 2026 08:51
c52cd9a to
6e0baa2
Compare
lzjqsdd
force-pushed
the
unified-conf-p4
branch
from
August 26, 2026 09:28
e48339b to
2288ee0
Compare
lzjqsdd
force-pushed
the
unified-conf-p3
branch
from
August 26, 2026 09:28
6e0baa2 to
b674bb4
Compare
lzjqsdd
force-pushed
the
unified-conf-p4
branch
from
August 26, 2026 10:22
2288ee0 to
43b982b
Compare
lzjqsdd
force-pushed
the
unified-conf-p3
branch
from
August 26, 2026 10:22
b674bb4 to
06d78c5
Compare
lzjqsdd
force-pushed
the
unified-conf-p4
branch
from
August 26, 2026 11:22
43b982b to
c374e41
Compare
lzjqsdd
force-pushed
the
unified-conf-p3
branch
from
August 26, 2026 11:22
06d78c5 to
3484c72
Compare
lzjqsdd
force-pushed
the
unified-conf-p4
branch
from
August 28, 2026 03:25
1f61f18 to
3e72102
Compare
lzjqsdd
force-pushed
the
unified-conf-p4
branch
from
August 28, 2026 09:51
3e72102 to
669d850
Compare
Contributor
There was a problem hiding this comment.
Pull request overview
This PR refactors curvine-fuse mount to generate most [fuse] CLI override flags directly from FuseConf via the existing ClientCliArgs derive (opt-in), reducing manual override branches and keeping the CLI surface aligned with the config struct. It also extends the derive macro to support clap alias for deprecated flag spellings.
Changes:
- Add
aliassupport to theClientCliArgsderive so generated clap args can keep deprecated flag names working. - Annotate historically tunable
FuseConffields (opt-in) and exportFuseConfCliOverridesfromcurvine-config. - Replace ~30 hand-written FUSE override branches in
mount_argswith a single generatedapply_tocall; update CLI tests to accessargs.mount.fuse.*.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
curvine-fuse/src/cli/mount_args.rs |
Flatten generated FuseConfCliOverrides into mount args and apply overrides via one apply_to call; adjust tests accordingly. |
curvine-fuse/src/cli/fuse_cli.rs |
Update CLI tests to reference generated mount overrides under args.mount.fuse.*. |
crates/common/curvine-macros/src/lib.rs |
Document new #[client_cli(alias = \"...\")] field attribute. |
crates/common/curvine-macros/src/client_cli.rs |
Implement alias parsing and emit #[arg(alias = ...)] on generated clap fields. |
crates/common/curvine-config/src/lib.rs |
Re-export FuseConfCliOverrides alongside FuseConf. |
crates/common/curvine-config/src/fuse_conf.rs |
Derive ClientCliArgs (opt-in) and annotate fields to generate FuseConfCliOverrides; preserve legacy flag alias mappings. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
szbr00
approved these changes
Aug 31, 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.
Summary
Fourth PR of the stacked series for #1619 (4/7). Generates the
curvine-fuse mountCLI overrides fromFuseConfvia the existingClientCliArgsderive (opt-in mode), replacing ~30 hand-writtenif let Some(...)branches so the CLI surface cannot drift from the config struct.Issue Describe / Design
Related to #1619 (partial). Depends on the stack #1620 -> #1622 -> #1623.
aliasoption.[fuse]fields annotated once;FuseConfCliOverridesis generated.--debug/--readonly(SetTrue),--optionslist,--master-addrs.--mnt-per-taskspelling preserved as a clap alias;--meta-cache-ttlmaps tometa_cache_timeout.Changes
crates/common/curvine-macros/src/client_cli.rsaliassupport to generated#[arg]scrates/common/curvine-config/src/fuse_conf.rsFuseConfCliOverridescurvine-fuse/src/cli/mount_args.rsapply_tocallcurvine-fuse/src/cli/fuse_cli.rsargs.mount.fuse.*)Test verified
cargo test -p curvine-fuse --lib clicargo test -p curvine-macrosDependencies