You need to use SnapshotDeletionPolicy.
If you have an unreleased picture, the writer will have the right to delete files at his discretion. This will only happen with a flush / close, so you can leave with it most of the time, but it will not always work.
Note that the policy belongs to the writer, so if you try to somehow use one process for backup and another write process, this will not work.
Xodarap
source share