Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How many concurrent read call can Redis server handle?

Tags:

linux

redis

I am planning to build a poll server for simple lists in Redis. Hundred and thousands of devices will poll every second to the Redis server to find small bits of information. These are mostly read calls. My question is what is the maximum concurrent requests the Redis server can accept?

like image 822
App Work Avatar asked Sep 15 '13 13:09

App Work


People also ask

How many reads and writes can Redis handle?

Redis does serialize all operations because of its single-thread design. So at a given point in time, it can only handle one single operation (read or write).

How many requests can Redis handle a second?

On Redis, each CPU in your cluster can handle up to 200 new connections per second. Any additional connection attempts within the second will fail and users must try again.

How much can Redis handle?

Redis can handle up to 2^32 keys, and was tested in practice to handle at least 250 million keys per instance. Every hash, list, set, and sorted set, can hold 2^32 elements. In other words your limit is likely the available memory in your system.

How does Redis handle concurrency?

RediSearch has a thread pool for running concurrent search queries. When a search request arrives, it gets to the handler, gets parsed on the main thread, and a request object is passed to the thread pool via a queue. The thread pool runs a query processing function in its own thread.


1 Answers

Maximum number of clients In Redis 2.4 there was an hard-coded limit about the maximum number of clients that was possible to handle simultaneously.
In Redis 2.6 this limit is dynamic: by default is set to 10000 clients, unless otherwise stated by the maxmemory directive in Redis.conf. However Redis checks with the kernel what is the maximum number of file descriptors that we are able to open (the soft limit is checked), if the limit is smaller than the maximum number of clients we want to handle, plus 32 (that is the number of file descriptors Redis reserves for internal uses), then the number of maximum clients is modified by Redis to match the amount of clients we are really able to handle under the current operating system limit.

You can check more on http://redis.io/topics/clients

like image 115
linux_fanatic Avatar answered Sep 21 '22 02:09

linux_fanatic