跳到正文
DEV Community· Layergrove·· 6 小時前AI 評分49

資料庫已還原,客戶仍能預訂嗎?

Your database restored. Can customers still book?

AI 導讀

資料庫還原演練應分開記錄資料庫可查詢時間與客戶工作流程通過時間;預訂未能在重新載入後維持可見,就不能算作流程成功。虛構演練中,資料庫於18分鐘後可查詢,測試預訂則在31分鐘後才通過重新載入驗證;演練不包括偵測事故或切換正式流量所需時間。

正文

Layergrove

Imagine your database restore finishes in 18 minutes. When you open the app, older bookings show up, but a new booking disappears after you reload. Which time goes in your recovery report?

Record database ready and customer workflow passed separately. If the workflow never passes, log that as a failure, not as an 18-minute recovery.

Run the reload test

  1. Pick one workflow and define a pass. For a booking app: an expected booking from before the recovery point is visible, a new test booking saves, and the same booking ID is still visible after reload.
  2. Restore to an isolated environment. Point a test app at the restored database. Use test accounts and sandbox integrations so the drill can’t charge real cards or notify customers.
  3. Test through the app. Check the known booking, create a new one, and reload in a fresh session. Check that the booking ID and status match. If the workflow relies on a background job, verify its expected result too.
  4. Log what you actually verified. Record the restore point and the pre-restore records you found. One recovered booking proves that booking survived, not that every booking did.

Copy this drill log

Workload / environment:
Drill started (UTC):
Requested recovery point (UTC):
Database query succeeded (UTC):
Expected pre-restore record / found?:
New test record / still visible after reload?:
Workflow passed (UTC), or failed:
Evidence / blocker:
Next fix / owner:

In a fictional drill starting at 09:00, the database answered at 09:18 and the test booking only passed after reload at 09:31. That’s 18 minutes to a queryable database and 31 minutes to verify this workflow. The drill didn’t measure how long it would take to detect an incident or switch production traffic.

For more on testing recovered data against recovery targets, see the AWS Well-Architected guide to periodic recovery testing.

What’s the first customer workflow you verify after a restore?

AI disclosure: This article was drafted with AI assistance.

來源:DEV Community · dev.to