add boltdb benchmark

This commit is contained in:
holys 2014-08-04 14:35:52 +08:00
parent 959e8d1205
commit 4b7d9db929
3 changed files with 25 additions and 18 deletions

View File

@ -51,7 +51,8 @@
<p>Rich advanced data structure: KV, List, Hash, ZSet, Bitmap.</p> <p>Rich advanced data structure: KV, List, Hash, ZSet, Bitmap.</p>
<h3>Various Backend </h3> <h3>Various Backend </h3>
<p>Various backend databases to choose: LevelDB, goleveldb, LMDB, RocksDB.</p> <p>Various backend databases to choose: </p>
<p>LevelDB, goleveldb, LMDB, RocksDB & BoltDB</p>
<h3>Expiration & TTL</h3> <h3>Expiration & TTL</h3>
<p>Supports expiration and ttl in all kinds of data structures.</p> <p>Supports expiration and ttl in all kinds of data structures.</p>
@ -75,6 +76,10 @@
<h3>Useful Tools</h3> <h3>Useful Tools</h3>
<p>Supplies tools to load, dump, and repair database.</p> <p>Supplies tools to load, dump, and repair database.</p>
<h3>RESTful API</h3>
<p>HTTP interfaces, can be directly accessed by HTTP Clients</p>
</div> </div>
</div> </div>
@ -177,7 +182,7 @@ db.Get(key)
} }
}, },
series: [], series: [],
colors: ['#df4810', '#3d4c4e', '#45a797', "#89C4F4", "#fddd67", "#5fa727"] colors: ['#45a797', "#89C4F4", "#9B59B6", "#fddd67", "#5fa727",'#df4810', '#3d4c4e']
}; };
var options_ledis = { var options_ledis = {
@ -197,7 +202,7 @@ db.Get(key)
} }
}, },
series: [], series: [],
colors: ['#df4810', '#3d4c4e', '#45a797', "#89C4F4", "#fddd67", "#5fa727"] colors: ['#45a797', "#89C4F4", "#9B59B6", "#fddd67", "#5fa727",'#df4810', '#3d4c4e']
}; };
@ -213,6 +218,7 @@ db.Get(key)
function parse(data, options) { function parse(data, options) {
// Split the lines // Split the lines
var lines = data.split('\n'); var lines = data.split('\n');
console.log(lines.length);
$.each(lines, function(lineNo, line) { $.each(lines, function(lineNo, line) {
var items = line.split(','); var items = line.split(',');
@ -224,8 +230,7 @@ db.Get(key)
} }
// the rest of the lines contain data with their name in the first position // the rest of the lines contain data with their name in the first position
// #HACKS: lineNo < 7. The csv file contains empty line. Ignore the 7th line. else if (lineNo < lines.length - 1) {
else if (lineNo < 7) {
var series = { var series = {
data: [] data: []
}; };

View File

@ -1,7 +1,8 @@
DB,SET,INCR,GET,RPUSH,LRANGE_10,LRANGE_50,LRANGE_100,LPOP,HSET,HGET,HINCRBY,HDEL,ZADD,ZINCRBY,ZRANGE,ZRANGEBYSCORE,ZREVRANGE,ZREVRANGEBYSCORE,ZREM DB,SET,INCR,GET,RPUSH,LRANGE_10,LRANGE_50,LRANGE_100,LPOP,HSET,HGET,HINCRBY,HDEL,ZADD,ZINCRBY,ZRANGE,ZRANGEBYSCORE,ZREVRANGE,ZREVRANGEBYSCORE,ZREM
redis,27012.73,34305.81,31517.71,30526.88,29262.62,19338.99,11744.58,31329.47,28329.03,27937.09,30105.63,28547.79,29335.08,27166.90,31169.20,24487.11,28239.99,28556.51,30771.39 ledisdb_goleveldb,24143.09,25924.69,28356.55,24129.88,18876.66,8523.78,4821.31,22452.35,25732.27,25563.63,23457.92,21250.97,19222.70,21545.64,666.01,628.49,63.09,22.90,23324.34
ssdb,23921.63,23618.85,24696.15,25596.02,7171.08,1762.47,1002.22,25992.80,26805.23,23396.95,25858.99,25756.50,26697.49,20424.08,6129.14,5979.09,256.82,229.75,25855.00 ledisdb_leveldb,25670.67,26972.25,20356.61,26212.65,16392.43,8398.24,5059.10,24098.06,26435.01,19914.47,24545.21,22800.48,20124.14,20933.10,3356.76,3083.32,121.32,45.43,21198.36
ledisdb_goleveldb,25429.22,24246.74,27537.03,23023.43,17994.29,8379.71,4911.44,22619.82,24508.36,25552.39,22600.28,21110.74,18951.49,21061.80,671.16,632.90,59.08,20.38,22026.00 ledisdb_rocksdb,25445.18,27024.74,27854.57,25997.50,18839.88,8659.91,5167.70,23216.47,26075.90,28183.21,24291.93,21984.06,20445.58,22799.16,5769.69,5652.89,133.57,113.01,21606.00
ledisdb_leveldb,24077.37,24395.03,21779.10,22922.70,17567.00,8601.56,5115.64,22971.71,24242.79,26686.95,22310.29,22090.89,21119.30,21736.81,3222.83,3180.91,118.70,44.19,21997.11 ledisdb_lmdb,25949.01,26993.77,27270.71,26403.66,17132.23,8690.68,5070.16,23844.47,26296.16,26484.43,24700.65,24708.48,23173.40,25020.85,24993.24,24063.70,26075.47,23769.81,25144.48
ledisdb_rocksdb,25269.10,24289.25,27176.58,23541.83,18287.84,8381.75,5082.11,21977.15,24360.25,28050.94,23032.09,21171.07,19556.10,21915.17,5386.90,5199.97,127.89,115.12,21335.86 ledisdb_boltdb,2627.21,2565.72,27659.74,2067.23,19280.82,8702.46,4980.21,1621.86,2441.69,27605.53,2350.96,2419.91,2329.33,2367.86,27318.40,25946.14,26707.56,26017.10,2393.94
ledisdb_lmdb,23987.90,24791.43,25447.90,23869.03,17630.86,8507.26,5115.74,22000.95,23354.64,27072.38,24027.73,23240.89,21555.89,23618.73,25097.35,25103.04,24617.92,23822.57,23467.32 redis,29373.47,29878.24,29056.13,28837.36,27694.51,19949.59,14082.76,29694.82,29456.31,31020.73,29660.13,29504.82,29840.35,27501.18,31620.11,23824.60,30413.00,28600.65,32168.58
ssdb,25641.61,26682.50,24433.75,26884.05,7007.23,2009.80,984.30,25404.18,26525.97,23762.91,26346.00,25853.36,27018.46,21097.96,6128.86,6189.67,260.11,239.80,25401.04

1 DB SET INCR GET RPUSH LRANGE_10 LRANGE_50 LRANGE_100 LPOP HSET HGET HINCRBY HDEL ZADD ZINCRBY ZRANGE ZRANGEBYSCORE ZREVRANGE ZREVRANGEBYSCORE ZREM
2 redis ledisdb_goleveldb 27012.73 24143.09 34305.81 25924.69 31517.71 28356.55 30526.88 24129.88 29262.62 18876.66 19338.99 8523.78 11744.58 4821.31 31329.47 22452.35 28329.03 25732.27 27937.09 25563.63 30105.63 23457.92 28547.79 21250.97 29335.08 19222.70 27166.90 21545.64 31169.20 666.01 24487.11 628.49 28239.99 63.09 28556.51 22.90 30771.39 23324.34
3 ssdb ledisdb_leveldb 23921.63 25670.67 23618.85 26972.25 24696.15 20356.61 25596.02 26212.65 7171.08 16392.43 1762.47 8398.24 1002.22 5059.10 25992.80 24098.06 26805.23 26435.01 23396.95 19914.47 25858.99 24545.21 25756.50 22800.48 26697.49 20124.14 20424.08 20933.10 6129.14 3356.76 5979.09 3083.32 256.82 121.32 229.75 45.43 25855.00 21198.36
4 ledisdb_goleveldb ledisdb_rocksdb 25429.22 25445.18 24246.74 27024.74 27537.03 27854.57 23023.43 25997.50 17994.29 18839.88 8379.71 8659.91 4911.44 5167.70 22619.82 23216.47 24508.36 26075.90 25552.39 28183.21 22600.28 24291.93 21110.74 21984.06 18951.49 20445.58 21061.80 22799.16 671.16 5769.69 632.90 5652.89 59.08 133.57 20.38 113.01 22026.00 21606.00
5 ledisdb_leveldb ledisdb_lmdb 24077.37 25949.01 24395.03 26993.77 21779.10 27270.71 22922.70 26403.66 17567.00 17132.23 8601.56 8690.68 5115.64 5070.16 22971.71 23844.47 24242.79 26296.16 26686.95 26484.43 22310.29 24700.65 22090.89 24708.48 21119.30 23173.40 21736.81 25020.85 3222.83 24993.24 3180.91 24063.70 118.70 26075.47 44.19 23769.81 21997.11 25144.48
6 ledisdb_rocksdb ledisdb_boltdb 25269.10 2627.21 24289.25 2565.72 27176.58 27659.74 23541.83 2067.23 18287.84 19280.82 8381.75 8702.46 5082.11 4980.21 21977.15 1621.86 24360.25 2441.69 28050.94 27605.53 23032.09 2350.96 21171.07 2419.91 19556.10 2329.33 21915.17 2367.86 5386.90 27318.40 5199.97 25946.14 127.89 26707.56 115.12 26017.10 21335.86 2393.94
7 ledisdb_lmdb redis 23987.90 29373.47 24791.43 29878.24 25447.90 29056.13 23869.03 28837.36 17630.86 27694.51 8507.26 19949.59 5115.74 14082.76 22000.95 29694.82 23354.64 29456.31 27072.38 31020.73 24027.73 29660.13 23240.89 29504.82 21555.89 29840.35 23618.73 27501.18 25097.35 31620.11 25103.04 23824.60 24617.92 30413.00 23822.57 28600.65 23467.32 32168.58
8 ssdb 25641.61 26682.50 24433.75 26884.05 7007.23 2009.80 984.30 25404.18 26525.97 23762.91 26346.00 25853.36 27018.46 21097.96 6128.86 6189.67 260.11 239.80 25401.04

View File

@ -1,7 +1,8 @@
DB,GET,SET,INCR,LPUSH,LPOP,LPUSH,LRANGE_100,LRANGE_300,LRANGE_500,LRANGE_600,MSET DB,SET,GET,INCR,LPUSH,LPOP,LPUSH,LRANGE_100,LRANGE_300,LRANGE_500,LRANGE_600,MSET
redis,35790.98,38080.73,37341.30,30469.22,30138.64,33852.40,13123.36,6421.78,5177.06,4052.52,25680.53 ledisdb_goleveldb,28868.36,30156.82,28042.62,25176.23,18288.22,23052.10,6175.89,2640.61,1817.45,1331.38,14120.31
ssdb,28490.03,28264.55,27639.58,29342.72,27624.31,28851.70,935.94,356.72,244.56,181.29,20449.90 ledisdb_leveldb,27886.22,21413.28,25786.49,21691.97,20833.33,24026.91,7936.51,2677.95,2199.35,1629.99,20080.32
ledisdb_goleveldb,27307.48,29797.38,26867.28,22441.65,23212.63,24618.42,6460.78,2608.24,1881.54,1318.25,14351.32 ledisdb_rocksdb,27654.87,29550.83,28457.60,26497.09,25087.81,27027.03,7053.18,2935.48,2303.40,1686.74,15634.77
ledisdb_leveldb,27442.37,22094.56,18982.54,22624.43,20807.32,25601.64,7850.53,3296.20,2390.86,1849.25,19936.21 ledisdb_lmdb,28818.44,24497.80,20938.02,22026.43,23419.20,25575.45,8325.01,3686.23,2617.94,1889.29,20885.55
ledisdb_rocksdb,26638.25,30102.35,25113.01,19833.40,20424.84,21294.72,7336.76,2961.73,2227.87,1767.60,19455.25 ledisdb_boltdb,2609.60,25290.85,2549.46,1624.11,1239.56,1257.67,9889.24,4054.82,2812.31,2106.59,1777.15
ledisdb_lmdb,26852.85,29761.91,27027.03,26096.03,24084.78,24875.62,7399.73,3150.60,2514.84,1892.22,20764.12 redis,28785.26,30211.48,31826.86,32010.24,30978.94,30506.40,13793.10,6505.33,4856.25,3964.79,26852.85
ssdb,29832.94,28137.31,28851.70,29103.61,27901.79,29638.41,979.76,355.19,231.87,179.98,21729.68

1 DB SET GET INCR LPUSH LPOP LPUSH LRANGE_100 LRANGE_300 LRANGE_500 LRANGE_600 MSET
2 redis ledisdb_goleveldb 38080.73 28868.36 35790.98 30156.82 37341.30 28042.62 30469.22 25176.23 30138.64 18288.22 33852.40 23052.10 13123.36 6175.89 6421.78 2640.61 5177.06 1817.45 4052.52 1331.38 25680.53 14120.31
3 ssdb ledisdb_leveldb 28264.55 27886.22 28490.03 21413.28 27639.58 25786.49 29342.72 21691.97 27624.31 20833.33 28851.70 24026.91 935.94 7936.51 356.72 2677.95 244.56 2199.35 181.29 1629.99 20449.90 20080.32
4 ledisdb_goleveldb ledisdb_rocksdb 29797.38 27654.87 27307.48 29550.83 26867.28 28457.60 22441.65 26497.09 23212.63 25087.81 24618.42 27027.03 6460.78 7053.18 2608.24 2935.48 1881.54 2303.40 1318.25 1686.74 14351.32 15634.77
5 ledisdb_leveldb ledisdb_lmdb 22094.56 28818.44 27442.37 24497.80 18982.54 20938.02 22624.43 22026.43 20807.32 23419.20 25601.64 25575.45 7850.53 8325.01 3296.20 3686.23 2390.86 2617.94 1849.25 1889.29 19936.21 20885.55
6 ledisdb_rocksdb ledisdb_boltdb 30102.35 2609.60 26638.25 25290.85 25113.01 2549.46 19833.40 1624.11 20424.84 1239.56 21294.72 1257.67 7336.76 9889.24 2961.73 4054.82 2227.87 2812.31 1767.60 2106.59 19455.25 1777.15
7 ledisdb_lmdb redis 29761.91 28785.26 26852.85 30211.48 27027.03 31826.86 26096.03 32010.24 24084.78 30978.94 24875.62 30506.40 7399.73 13793.10 3150.60 6505.33 2514.84 4856.25 1892.22 3964.79 20764.12 26852.85
8 ssdb 29832.94 28137.31 28851.70 29103.61 27901.79 29638.41 979.76 355.19 231.87 179.98 21729.68