feat(consistent symlink): changes for CreateSymlink flow for updated representation#4424
feat(consistent symlink): changes for CreateSymlink flow for updated representation#4424anushka567 merged 4 commits intomasterfrom
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #4424 +/- ##
===========================================
+ Coverage 0 83.30% +83.30%
===========================================
Files 0 163 +163
Lines 0 19997 +19997
===========================================
+ Hits 0 16659 +16659
- Misses 0 2718 +2718
- Partials 0 620 +620
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
0b8f1cd to
4287bf6
Compare
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request introduces a significant enhancement to how GCSFuse handles symlink creation, moving towards a standardized representation that is compatible with other Google Cloud Storage clients. The change allows symlink targets to be stored directly in the object content and marked with a specific metadata key, improving interoperability and consistency across GCS services. This new behavior is opt-in via a configuration flag, ensuring backward compatibility while enabling future-proof symlink management. Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request introduces support for creating symlinks using the standard GCS representation, controlled by the experimental-enable-standard-symlinks flag. The changes correctly modify the CreateChildSymlink flow to store the symlink target in the object's content and set the goog-reserved-file-is-symlink: true metadata key. The changes are logical and include a new unit test to verify the creation logic.
However, a critical piece of functionality is missing: the logic to read and identify these new symlinks is not implemented. Specifically, inode.IsSymlink and inode.NewSymlinkInode are not updated to handle the new format. This means that while gcsfuse can create these symlinks, it cannot recognize them when they are read back from GCS (e.g., during a directory listing or file lookup on a cold cache). They will be incorrectly treated as regular files.
I've added a comment to the new unit test suggesting an extension that would expose this issue. Addressing this is crucial for the feature to be complete and usable.
4287bf6 to
ee858ec
Compare
Description
This PR implements the creation phase of the updated GCS symlink representation in GCSFuse to align with the standard used by other GCS clients like Storage Transfer Service (STS) . When enabled via a flag, new symlinks will be created as GCS objects where the target path is stored in the object content and marked with the standard metadata key
goog-reserved-file-is-symlink: true.Context: go/sts-consistent-symlink-handling-in-gcsfuse
Link to the issue in case of a bug fix.
b/488952518
Testing details
Any backward incompatible change? If so, please explain.
No.