VTgate service etcd service pod pod VTctld VTctld service Admin pod batch job VTgate pod Shard 1 Shard 2 tablet tablet Master Replica Ronly Master Replica Ronly
declare i int; set i = 0; set i = i + 1; INSERT INTO messages (page, time_created_ns, message) VALUES ( i, i+cast(now() as datetime) , SUBSTRING(MD5(RAND()), 1, 10)); end while; end ; call insert_messages(1000000); • 複数のShardにヒットするクエ リー(Scatter Query) select * from messages where message like '%abc%'; +----+-------------+----------+------------+------+---------------+------+---------+------+--------+----------+------- | id | select_type | table | partitions | type | possible_keys | key | key_len | ref | rows | filtered | Extra | +----+-------------+----------+------------+------+---------------+------+---------+------+--------+----------+------- | 1 | SIMPLE | messages | NULL | ALL | NULL | NULL | NULL | NULL | 227016 | 11.11 | Using +----+-------------+----------+------------+------+---------------+------+---------+------+--------+----------+------- 1 row in set (0.70 sec)