Deleting data up to a specific version

Hi,

is there a way to instruct FDB to perform a clearrange but only up to a certain version, that is only delete an entry if it was committed with a version less than a cut off version?

If that is not possible, is there a way to “expire” data in the storage servers, pretty much like HBase would do it with its TTLs?

If you can encode the version as part of the key for every keys, then the answer is yes. To do this, you may use the VersionStamp feature, which needs 10 bytes, as the key prefix. Then you can delete all keys whose commit versions are less than a version (converted to a versionstamp prefix).

A versionstamp is a 10 byte, unique, monotonically (but not sequentially) increasing value for each committed transaction. The first 8 bytes are the committed version of the database (serialized in big-endian order). The last 2 bytes are monotonic in the serialization order for transactions (serialized in big-endian order).