Commit 0262e1e
committed
fuse: Update fuser dependency 0.15.1 → 0.17.0
fuser 0.17 is needed to support multithreaded FUSE sessions: the new
API requires `Filesystem: Send + Sync + 'static`, which forces proper
Arc-based ownership of the filesystem state and makes it possible to
safely hand the implementation to multiple worker threads.
The breaking API changes and how they are addressed:
- `&self` instead of `&mut self` on all trait methods: the only mutable
state (open file handles) is now protected by a Mutex.
- New newtypes (INodeNo, FileHandle, LockOwner, Generation) and bitflags
(OpenFlags, FopenFlags) — updated at call sites.
- readdir/read offsets changed from i64 to u64.
- Session::from_fd now takes SessionACL + Config separately.
- Session::run() is no longer public; replaced by spawn().join().
- reply.error() takes fuser::Errno instead of raw i32.
To satisfy the `'static` bound, serve_tree_fuse() now takes
`Arc<FileSystem>` and `Arc<Repository>`. A pre-built flat Vec<InodeData>
(indexed by ino-1) replaces the old HashMap<Ino, InodeRef<'a>>, removing
the lifetime that was incompatible with `'static`. An InodeLookup index
(path→ino for dirs, LeafId→ino for leaves) handles child ino resolution
without raw pointers.
Assisted-by: OpenCode (claude-sonnet-4-6)
Signed-off-by: Colin Walters <walters@verbum.org>1 parent 4c3e68f commit 0262e1e
2 files changed
Lines changed: 507 additions & 309 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
| 16 | + | |
17 | 17 | | |
18 | 18 | | |
0 commit comments