segunda-feira, 20 de outubro de 2014

Redis performance with JEDIS

Hi,
this test shows some run performance on my machine (normal dev machine), using a Jedis Java interface.

1. CPU info
processor    : 1
vendor_id    : GenuineIntel
cpu family    : 6
model        : 42
model name    : Intel(R) Core(TM) i5-2450M CPU @ 2.50GHz

2. redis bench
redis-benchmark -t set,lpush -n 1000000 -q
SET: 141582.89 requests per second
LPUSH: 137722.08 requests per second


3. redis bench pipeline
redis-benchmark -n 1000000 -t set,get -P 16 -q
SET: 665778.94 requests per second
GET: 813669.62 requests per second


4. jedis pool not piped

Write / ReadNumber ThreadsTotal OpsOps per threadTime msOp/sec
x / o10100010001029803.921569
o / x10100010007114084.50704
x / x10100010001148771.929825
x / o105000001000736367907.10308
o / x105000001000674474139.97628
x / x1050000010001376436326.64923
x / o10100000010001457968591.81014
o / x10100000010001340574599.03021
x / x10100000010002803135674.78863






x / o20100010002638461.53846
o / x20100010002737037.03704
x / x20100010004920408.16327
x / o205000001000732868231.44105
o / x205000001000693772077.26683
x / x2050000010001393735875.72648
x / o20100000010001440569420.34016
o / x20100000010001364773276.17791
x / x20100000010002863934917.4203


5. jedis pool piped

Write / ReadNumber ThreadsTotal OpsOps per threadTime msOp/sec
x / o10100010007712987.01299
o / x10100010002050000
x / x10100010005219230.76923
x / o1050000010001314380517.5038
o / x105000001000778642673.5219
x / x1050000010001718291036.0885
x / o10100000010002121471475.719
o / x10100000010001597626174.0764
x / x10100000010003448290023.2019






x / o20100010002500000
o / x20100010002500000
x / x20100010004250000
x / o2050000010001017491642.0846
o / x205000001000819610500.6105
x / x2050000010001705293255.132
x / o20100000010001936516528.9256
o / x20100000010001663601322.9104
x / x20100000010003838260552.371






Conclusions
a) pipeline makes a great difference; reads logic stays more complex
b) with a 4x core i was not able to get 100% cpu (yet)
c) on reads i was able to get 626k Ops
d) on writes performance was 471 kops
e) number pool threads / ops per thread influences the benchmark time

Java Obfuscate Properties

Hi there how many times we have fuckin stupid commentaries of , hey the code has a password... bullshit you can always get the password... ...