Skip to content
Discussion options

You must be logged in to vote

In practice yes: the only caller is juicefs mount (cmd/mount.go#L689), and pkg/vfs keeps more process-wide state than internalNodes, like the package-level op metrics that vfs.InitMetrics registers once and the /tmp/state<ppid>.json handle file that every NewVFS call loads and renames. Everything that may open several volumes in one process, such as the Java SDK's jfs_init, goes through fs.NewFileSystem instead, which builds its own reader, writer and metrics per instance and never touches those globals. So for more than one instance pkg/fs is the route the code already supports. Making NewVFS itself repeatable would mean moving the internal node table onto VFS, and pkg/fs reads that tabl…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by myangitzh
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants