Open
Conversation
…ass backup engine Backport of upstream changes: - Extract hook logic into invokeRestoreDoneHook helper - Call the hook from both RestoreBackup (startup) and RestoreFromBackup (RPC) paths - Pass backup engine name to hook via TM_RESTORE_DATA_BACKUP_ENGINE env var - Return backup engine from restoreDataLocked Signed-off-by: Stas Maksimov <smaksimov@slack-corp.com> Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
The conflict resolution from the cherry-pick incorrectly changed startReplication to use context.Background(), which removes the deadline and causes TestRestoreUnreachablePrimary to hang. Signed-off-by: Stas Maksimov <smaksimov@slack-corp.com> Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## slack-22.0 #814 +/- ##
==============================================
+ Coverage 67.53% 69.80% +2.27%
==============================================
Files 1600 1606 +6
Lines 261782 214099 -47683
==============================================
- Hits 176786 149454 -27332
+ Misses 84996 64645 -20351 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Summary
invokeRestoreDoneHookhelper, called from bothRestoreBackup(startup) andRestoreFromBackup(RPC) pathsTM_RESTORE_DATA_BACKUP_ENGINEenv varrestoreDataLockedPreviously, restores triggered via
vtctldclient RestoreFromBackupnever fired thevttablet_restore_donehook.Backport of upstream vitessio#19405 + follow-up RPC path fix (posted today to vitessio#19592 as well).
Test plan
vtctldclient RestoreFromBackupon a staging tabletvttablet_restore_donehook is executed (visible in vttablet logs)TM_RESTORE_DATA_START_TS,TM_RESTORE_DATA_STOP_TS,TM_RESTORE_DATA_DURATION,TM_RESTORE_DATA_BACKUP_ENGINERelated Issue(s)
Checklist
Deployment Notes
AI Disclosure