Open meteorgan opened 1 month ago
There is a problem in https://github.com/apache/opendal/pull/5106. when performing a simple DELETE
in S3
, a delete marker is inserted as the current version. In the response from ListObjectVersions
, the delete markers are placed in DeleteMarker
container, while other versions of the object are in the Version
container. so currently, the List_with(path).version(true)
will return all object versions excluding delete marker
.
Hi, I believe listing deleted objects is an orthogonal feature compared to listing versioned objects. Some services that don't enable versioning can still have features like "soft delete," such as Azure Blob Soft Delete.
So all the following cases are possible:
list_with(path)
list_with(path).version(true)
list_with(path).deleted(true)
list_with(path).version(true).deleted(true)
.Hi, I believe listing deleted objects is an orthogonal feature compared to listing versioned objects. Some services that don't enable versioning can still have features like "soft delete," such as Azure Blob Soft Delete.
So all the following cases are possible:
- List active files:
list_with(path)
- List active files along with non-current files:
list_with(path).version(true)
- List active files along with deleted files:
list_with(path).deleted(true)
- List all files (active, non-current, deleted):
list_with(path).version(true).deleted(true)
.
Understood. I'll revise this issue accordingly.
Feature Description
When performing a
List
request, list all object versions, including the deleted ones.Problem and Solution
Add a
deleted
parameter to theList
operation, when set to true, return all active objects along with deleted objectsAdditional Context
In
S3
, whenversioning
is enabled, a simpleDELETE
cannot permanently remove an object. We can still retrieve the object using theversion
parameter. Therefore, it's useful if aList
request can return all object versions.Are you willing to contribute to the development of this feature?