Restore Service Fabric Backup to a partition with changed PartitionId

105 views Asked by At

I am using a uniform partitioning scheme for my stateful services and I am succesfully making backing up and restoring the state to/from Azure Blob Storage. The process depends on the partitionId to identify to container in which the backups for particular partition are stored.

The above works great assuming the cluster is always live and the partitionIds are never changed. Nevertheless I've been bumping my head how to be able to restore my state even if the whole cluster went down (which in turn leads to totally different partitionIds in the re-created cluster)

Any ideas... anyone :)?

Thanks in advance!

1

There are 1 answers

1
Robert On BEST ANSWER

You should make a name convention for the backup file, so that it contains the partition key, not it's service fabric id. For ex, if I have 10 partitions made with modulo ten on the ID (int), then I would backup with the names zero to nine.