How much faster is Redis than mongoDB?

前端 未结 7 1112
既然无缘
既然无缘 2020-12-07 06:34

It\'s widely mentioned that Redis is \"Blazing Fast\" and mongoDB is fast too. But, I\'m having trouble finding actual numbers comparing the results of the two. Given simila

7条回答
  •  [愿得一人]
    2020-12-07 07:24

    Good and simple benchmark

    I tried to recalculate the results again using the current versions of redis(2.6.16) and mongo(2.4.8) and here's the result

    Completed mongo_set: 100000 ops in 5.23 seconds : 19134.6 ops/sec
    Completed mongo_get: 100000 ops in 36.98 seconds : 2703.9 ops/sec
    Completed redis_set: 100000 ops in 6.50 seconds : 15389.4 ops/sec
    Completed redis_get: 100000 ops in 5.59 seconds : 17896.3 ops/sec
    

    Also this blog post compares both of them but using node.js. It shows the effect of increasing number of entries in the database along with time.

提交回复
热议问题