Skip to main content

Delete markers

Delete markers are special versions that S3-compatible APIs use to mark an object as deleted in a versioned bucket. When you delete the latest version of an object in a versioned bucket, instead of removing the object and its versions, the system creates a delete marker that becomes the current version of the object.

Delete markers are used to maintain version history in a versioned bucket while allowing objects to appear deleted in normal operations. They help preserve the complete history of objects while providing a way to "delete" objects without actually removing their previous versions.

info

For more information on delete markers, please refer to the S3 Delete markers documentation.

Version deletion

Deleting a version of an object throught the versions drawer will permanently delete the version, and thus a delete marker will not be created.

Prerequisites

To understand and work with delete markers, you will need:

  1. A bucket with versioning enabled - see Bucket versioning
  2. Understanding of object versioning - see Objects versioning

Creating a delete marker

To create a delete marker you first need a versioned bucket with at least one version object.

Let's take the PDF file from the Objects versioning example, sample-1.pdf, and delete it.

Delete the Sample-1.pdf object

After confirming the deletion, the object will not be visible anymore, much like a normal deletion. However, by using the menu button next to the bucket name title, you can enable the Show deleted objects option to see the delete marker.

Show deleted objects

The menu item will now be shown with the red color, indicating that the delete markers are now visible. This preference is persisted for each bucket.

Show deleted objects

Now you can see the delete marker for the sample-1.pdf object, shown in the red color.

Deleted sample-1.pdf object

caution

From the S3-compatible API standards, a delete marker will only be created when you delete the latest version of an object. If you delete a previous version, no delete marker will be created, and the version will be permanently deleted as normal.

Recovering a deleted object

There are multiple ways to recover a deleted object, depending on the context.

Recovering a deleted object from the versions drawer

By clicking on the delete object's name, you will now have access to the versions drawer, instead of the file preview feature.

Versions drawer

From the versions drawer, you can now see the delete marker for the sample-1.pdf object, shown in the red color and stated as deleted.

The drawer gives you the option to recover the object from it's main bottom button, or by using the menu of the deleted revision and choosing the Recover option.

Recover deleted object

Recovering a deleted object by uploading a new revision with the same name

You can also recover the object by uploading a new revision with the same name. This will add a new version of the object, and the delete marker will no longer be the latest version, making the object visible again in the normal objects listing.

This new version will be the latest version of the object, which means that the delete marker is still visible in the versions drawer, but it is not the latest version anymore.

Upload new revision

Cautions and limitations

As of the current state of the Explorer, deleting a folder will not create a delete marker, for the folder or for any underlying objects. All objects and versions will be permanently deleted.