yangzhg
d3d835844f
[Performance] Improve performance of unique table read (#3974)
Implements #3971
the test table as list:
```
mysql> desc test;
+------------+---------+------+-------+---------+---------+
| Field | Type | Null | Key | Default | Extra |
+------------+---------+------+-------+---------+---------+
| rid | BIGINT | No | true | 0 | |
| qid | BIGINT | No | true | 0 | |
| qidDeleted | TINYINT | No | false | 0 | REPLACE |
| type | TINYINT | No | false | 0 | REPLACE |
| uid | BIGINT | No | false | 0 | REPLACE |
| toUid | BIGINT | No | false | 0 | REPLACE |
| status | INT | No | false | 0 | REPLACE |
| createTime | INT | No | false | 0 | REPLACE |
| source | INT | No | false | 0 | REPLACE |
| misFlag | INT | No | false | 0 | REPLACE |
| anonymous | TINYINT | No | false | 0 | REPLACE |
| uv | TINYINT | No | false | 1 | REPLACE |
+------------+---------+------+-------+---------+---------+
12 rows in set (0.00 sec)
mysql> select count(*) from test;
+----------+
| count(*) |
+----------+
| 1093760 |
+----------+
1 row in set (1.00 sec)
```
There is 29 versions at present

I run the query `select sum(uv) from test` for 10 times,
the average ScanTime reduced from `9s277ms` to `8s206ms`
2020-07-02 13:56:08 +08:00
..
2020-07-02 13:56:08 +08:00
2020-07-01 09:22:33 +08:00
2020-06-23 13:43:08 +08:00