They are all solutions for Redis distributed clusters. I just saw an article pushed by InfoQ through WeChat at noon - "Best Practices for Efficient Operation and Maintenance (03): Redis Cluster Technology and Codis Practice", which is quite detailed. Targetedly, it improves the "heavy" nature of Redis Cluster and also points out the shortcomings of twemproxy. Unfortunately, this article was not found on the InfoQ website. I don’t know if it was not updated in time, so I cannot post the link. You can follow it.
Let’s talk about a few problems with twemproxy, and you will know the advantages of redis cluster
(1) Fully asynchronous implementation, more complicated to understand (2) The cheating auto_eject_hosts (3) Dynamic addition of server is not supported (4) mget will be automatically split, affecting performance
Redis cluster updates the client's node routing rules through communication between the client and the server, and between the server and the server, ensuring that the client's requests are always sent to the correct server node. In most cases, the client to the server only needs One communication.
And Twemproxy acts as a proxy to distribute requests to nodes, with an additional layer of communication in the middle.
Theoretically speaking, redis cluster performance is efficient. Of course, the implementation is much more complicated and needs to be tested in practice.
Personally, I think the redis cluster method will be the mainstream in the future.
They are all solutions for Redis distributed clusters. I just saw an article pushed by InfoQ through WeChat at noon - "Best Practices for Efficient Operation and Maintenance (03): Redis Cluster Technology and Codis Practice", which is quite detailed. Targetedly, it improves the "heavy" nature of Redis Cluster and also points out the shortcomings of twemproxy. Unfortunately, this article was not found on the InfoQ website. I don’t know if it was not updated in time, so I cannot post the link. You can follow it.
Let’s talk about a few problems with twemproxy, and you will know the advantages of redis cluster
(1) Fully asynchronous implementation, more complicated to understand
(2) The cheating auto_eject_hosts
(3) Dynamic addition of server is not supported
(4) mget will be automatically split, affecting performance
Redis cluster updates the client's node routing rules through communication between the client and the server, and between the server and the server, ensuring that the client's requests are always sent to the correct server node. In most cases, the client to the server only needs One communication.
And Twemproxy acts as a proxy to distribute requests to nodes, with an additional layer of communication in the middle.
Theoretically speaking, redis cluster performance is efficient.
Of course, the implementation is much more complicated and needs to be tested in practice.
Personally, I think the redis cluster method will be the mainstream in the future.