public void StartRestoringArchive(string eTag) { var version = new DashboardVersion { Version = CurrentDashboardVersion, UpgradeState = DashboardUpgradeState.RestoringArchive }; TryCreateOrUpdateVersion(version, eTag); }
public void StartDeletingOldData(string eTag) { var version = new DashboardVersion { Version = CurrentDashboardVersion, UpgradeState = DashboardUpgradeState.DeletingOldData }; TryCreateOrUpdateVersion(version, eTag); }
private void TryCreateOrUpdateVersion(DashboardVersion version, string eTag) { if (!String.IsNullOrEmpty(eTag)) { _store.TryUpdate(DashboardBlobNames.Version, eTag, version); } else { _store.TryCreate(DashboardBlobNames.Version, version); } }
public void FinishUpgrade(string eTag) { // Set the new version and the upgrade state var version = new DashboardVersion { Version = CurrentDashboardVersion, UpgradeState = DashboardUpgradeState.Finished }; TryCreateOrUpdateVersion(version, eTag); }