yugabyte/yugabyte-db

[DocDB] If restore_snapshot doesn't have any snapshot to restore, it should give meaningful message instead of giving restoration uuid

Open

#13,437 创建于 2022年7月26日

在 GitHub 查看
 (1 评论) (0 反应) (1 负责人)C (1,003 fork)batch import
area/docdbgood first issuekind/enhancementpriority/medium

仓库指标

Star
 (8,229 star)
PR 合并指标
 (平均合并 17天 21小时) (30 天内合并 92 个 PR)

描述

Jira Link: DB-3058

Description

Let’s say you create snapshot schedule and it is taking snapshots at every interval of t1.

timestamp1 ------> timestamp2 ------> timestamp3 ..............

interval between timestamp1 and timestamp2 is t1

Let's say there was deletion of some table at a 'time' which is greater than timestamp3. The latest snapshot available is at timestamp3 (as timestamp4 is not yet reached)

If we try to restore to a point by giving it to restore to a point 'time' either by absolute of relative, it doesn't have snapshot to restore to that particular point. Latest available would be timestamp3.

Observation:

Restoration UUID is seen in response. And if we try to see the status of restoration UUID, it says RESTORED.

Suggestion:

Since no snapshot was taken and it is not restored to that particular point, it is better to show a better message saying:

Last snapshot available is at with <snapshot_id>.

Reason:

It gives a false info saying it is restored, but the state is as it is. Hence a better user experience can be targeted to achieve.

贡献者指南