Created
May 27, 2021 21:30
-
-
Save dasl-/4e8e5a91fcf7d2b1daf0ee553655ba64 to your computer and use it in GitHub Desktop.
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
vtctl MoveTables -cells=etsy_cells -workflow=ks2to3_workflow ks2 ks3 'ks2to3_test' | |
vtctl SwitchReads -tablet_type=rdonly ks3.ks2to3_workflow | |
vtctl SwitchReads -tablet_type=replica ks3.ks2to3_workflow | |
vtctl SwitchWrites ks3.ks2to3_workflow | |
vtctl SwitchReads -tablet_type=rdonly ks2.ks2to3_workflow_reverse | |
vtctl SwitchReads -tablet_type=replica ks2.ks2to3_workflow_reverse | |
vtctl_etsy SwitchWrites ks2.ks2to3_workflow_reverse | |
# after executing the previous command, i *think* that `select * from _vt.vreplication\G` might show non-fully qualified vindex names in the in_keyrange clause... |
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
CREATE TABLE `ks1_test` ( | |
`k` bigint(20) NOT NULL, | |
`v` bigint(20) NOT NULL, | |
PRIMARY KEY (`k`, `v`) | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=8; |
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
{ | |
"sharded": true, | |
"vindexes": { | |
"hash": { | |
"type": "hash" | |
} | |
}, | |
"tables": { | |
"ks1_test": { "column_vindexes": [ { "name": "hash", "column": "k" } ] } | |
} | |
} |
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
CREATE TABLE `ks2to3_test` ( | |
`k` bigint(20) NOT NULL, | |
`v` bigint(20) NOT NULL, | |
PRIMARY KEY (`k`, `v`) | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=8; |
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
CREATE TABLE `ks2to3_test` ( | |
`k` bigint(20) NOT NULL, | |
`v` bigint(20) NOT NULL, | |
PRIMARY KEY (`k`, `v`) | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=8; |
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
{ | |
"sharded": true, | |
"vindexes": { | |
"hash": { | |
"type": "hash" | |
} | |
}, | |
"tables": { | |
"ks2to3_test": { "column_vindexes": [ { "name": "hash", "column": "k" } ] } | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment