Page MenuHomePhabricator

Make `bin/storage dump` insert CREATE DATABASE and USE statements
ClosedPublic

Authored by epriestley on Oct 13 2017, 8:53 PM.
Tags
None
Referenced Files
F17852942: D18707.diff
Sun, Jul 27, 1:13 PM
F17799933: D18707.diff
Fri, Jul 25, 5:41 AM
F17759956: D18707.diff
Tue, Jul 22, 7:02 PM
F17648932: D18707.diff
Sat, Jul 12, 3:05 AM
Unknown Object (File)
Jun 29 2025, 8:08 PM
Unknown Object (File)
May 19 2025, 9:04 AM
Unknown Object (File)
May 5 2025, 7:10 PM
Unknown Object (File)
May 2 2025, 2:09 PM
Subscribers
None

Details

Summary

Ref T13000. The new approach for dumping database-by-database means that we don't get CREATE DATABASE or USE statements, which makes importing the dump again inconvenient.

Manually stitch these into the dump.

Test Plan
  • Used bin/storage dump --namespace ... to dump a smaller local instance.
  • Used bin/storage destroy --namespace ..., to destroy the namespace, then inported the dump cleanly.
  • Verified that each CREATE DATABASE statement appears only once.
  • Verified that bin/storage renamespace --live can correctly process this file.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable