1.压测工具

MySQL 压测与结果分析_数据库压测报告

thds: 30 tps: 1145.99 qps: 22943.36 (r/w/o: 16063.50/4585.07/2294.79) lat (ms,95%): 29.72 err/s: 0.00 reconn/s: 0.00

2.代码压测

DROP TABLE IF EXISTS `user_info`;
CREATE TABLE `user_info`  (
  `id` bigint(20) NOT NULL AUTO_INCREMENT,
  `name` varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
  `sex` tinyint(4) NULL DEFAULT NULL,
  `img` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
  PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 17256225 CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = Dynamic;

SET FOREIGN_KEY_CHECKS = 1;

polardb 4核8G ,插入数据,qps 18000, CPU到100%