好的想法是十分钱一打,真正无价的是能够实现这些想法的人。

bulk 性能测试

匿名 | 发布于2017年07月05日 | 阅读数:6184

 表 
CREATE TABLE `xdual` (
`ID` int(11) NOT NULL AUTO_INCREMENT,
`X` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
`a` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
`b` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
`c` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
`d` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
`e` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
`f` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
`g` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
`h` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY (`ID`)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 ;

10个字段 bulk入库约10000 条/s
CREATE TABLE `xdual` (
`ID` int(11) NOT NULL AUTO_INCREMENT,
`X` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY (`ID`)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 ;
两个字段 bulk入库约20000 条/s
 
 单机默认配置 16G内存 单个线程 index bulk   预先从mysql读取 100000条数据 ,分一次性 bulk以及2000,1000条一次分开提交

这个数据怎么样
 
 10字段QPS: 10000条/s 
 20字段QPS: 7k-8k条/s  bytes length 550/doc
44字段QPS: 4k-5k 条/s
 
 
 测试了下esrally的geoname数据,格式如下 bulk约12000 doc/s
{"name": "Costa de Xurius", "geonameid": 3038814, "feature_class": "T", "longitude": 1.48333, "timezone": "Europe/Andorra", "feature_code": "SLP", "dem": "1434", "country_code": "AD", "admin1_code": "00", "latitude": 42.5, "asciiname": "Costa de Xurius", "population": 0}
{"name": "Font de la Xona", "geonameid": 3038815, "feature_class": "H", "longitude": 1.44986, "timezone": "Europe/Andorra", "feature_code": "SPNG", "dem": "1976", "country_code": "AD", "admin1_code": "04", "latitude": 42.55003, "asciiname": "Font de la Xona", "population": 0}
{"name": "Xixerella", "geonameid": 3038816, "feature_class": "P", "longitude": 1.48736, "timezone": "Europe/Andorra", "feature_code": "PPL", "dem": "1417", "country_code": "AD", "admin1_code": "04", "latitude": 42.55327, "asciiname": "Xixerella", "population": 0}
已邀请:

要回复问题请先登录注册