Skip to content

How gcsfuse identifies if a GCS object is file or directory? #2267

Answered by raj-prince
raj-prince asked this question in Q&A
Discussion options

You must be logged in to vote

Let's first understand the important terminologies:

(a) Explicit Directory - GCSFuse treats an object with trailing delimiter (/) as explicit directory. If you create a directory via GCSFuse it creates an object in GCS with trailing delimiter (/). E.g. - a/b/c/

(b) File - GCSFuse treats an object without trailing delimiter (/) as a file. E.g. - a/b/c/d.txt

(c) Implicit Directory - GCSFuse infers the existence of implicit directory if there are objects within a "path" that share a common prefix. E.g. If a bucket contains only one object a/b/c/d.txt, GCSFuse treats a/, a/b, and a/b/c/ as implicit directories.

GCSFuse only understand the concept of implicit directory when bucket is mounted with

Replies: 1 comment

Comment options

raj-prince
Aug 2, 2024
Maintainer Author

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