[PR #2653] [MERGED] A case of HEAD response for mp is different on compatible storage #2687

Closed
opened 2026-03-04 02:06:47 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/s3fs-fuse/s3fs-fuse/pull/2653
Author: @ggtakec
Created: 4/2/2025
Status: Merged
Merged: 4/3/2025
Merged by: @gaul

Base: masterHead: fix/mp_head_req


📝 Commits (1)

  • 96ce4da A case of HEAD response for mp is different on compatible storage

📊 Changes

1 file changed (+22 additions, -3 deletions)

View changed files

📝 src/s3fs.cpp (+22 -3)

📄 Description

Relevant Issue (if applicable)

#2246 #2304 #2423 #1964

Details

Using S3 compatible providers, it seems that in some cases a HEAD request to a mount point will return a 200 error instead of a 404 error, even though the "/" object(path = "//") doesn't exist.
In this case, the expected key name(ex. x-amz-meta-*) doesn't exist in the response header, but other keys exist and the response header is not empty.
With the current code, it works under the assumption that a 404 error or an empty response header will be returned, so the file listing commands(ex, ls) is failed by the mount point is not a directory.
To avoid this, I have changed the code to handle cases where the expected key name(e.g. x-amz-meta-*) doesn't exist in the response header in the same way as a 404 error.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/s3fs-fuse/s3fs-fuse/pull/2653 **Author:** [@ggtakec](https://github.com/ggtakec) **Created:** 4/2/2025 **Status:** ✅ Merged **Merged:** 4/3/2025 **Merged by:** [@gaul](https://github.com/gaul) **Base:** `master` ← **Head:** `fix/mp_head_req` --- ### 📝 Commits (1) - [`96ce4da`](https://github.com/s3fs-fuse/s3fs-fuse/commit/96ce4da9948a8c70b779a5a0bc900d53b8cca381) A case of HEAD response for mp is different on compatible storage ### 📊 Changes **1 file changed** (+22 additions, -3 deletions) <details> <summary>View changed files</summary> 📝 `src/s3fs.cpp` (+22 -3) </details> ### 📄 Description ### Relevant Issue (if applicable) #2246 #2304 #2423 #1964 ### Details Using S3 compatible providers, it seems that in some cases a HEAD request to a mount point will return a `200` error instead of a `404` error, even though the `"/"` object(path = `"//"`) doesn't exist. In this case, the expected key name(ex. `x-amz-meta-*`) doesn't exist in the response header, but other keys exist and the response header is not empty. With the current code, it works under the assumption that a `404` error or an empty response header will be returned, so the file listing commands(ex, `ls`) is failed by the mount point is not a directory. To avoid this, I have changed the code to handle cases where the expected key name(e.g. `x-amz-meta-*`) doesn't exist in the response header in the same way as a `404` error. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-04 02:06:47 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/s3fs-fuse#2687
No description provided.