My use case is similar. Each day I snapshot the previous five days and push them to S3. The plan was to overwrite existing snapshots and fill in any gaps left by failures to ensure a continuous backup. Unfortunately the random naming scheme seemingly makes this impossible.
Perhaps I should be doing it more programmatically?
The only way to set and get names for snapshots is via the snapshot API. The file names do not correlate at all.
You also can't "overwrite" existing snapshots. You must understand that a snapshot is actually pointer metadata and segment files. When you initiate a snapshot, you're setting up a sequence of events (roughly this):
Identify all segments used by the indices selected for the snapshot
Stop background segment merges of identified segments
Check the remote repository to see if any of those segments have already been copied
Copy only new segments to the repository
Update the snapshot metadata so that segments in use have a pointer reference.
Report snapshot completion (if successful)
Enable background segment merges of identified segments
This is why a snapshot isn't copying things to a particular file on the remote file system. It's also why you can't "overwrite" a snapshot. The snapshot is technically metadata, and segment files are the actual data.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.