search

Home  >  Q&A  >  body text

Redis message queue problem

The following is my application scenario

For example, the client sends a request. At this time, the server needs to process the request and return it to the client. It should be noted that the user will wait for the return result in real time, so the faster the processing, the better

It is impossible to rely on one server to handle these tasks, the processing is too slow, and it is easy to hang up

Assume that I have 100 servers to handle these tasks at this time. The more troublesome method is to randomly send requests to these servers every time a user's request is received, and the server processes it and returns it to the user. In this way, 100 servers share the load Complete these tasks and relieve stress

Then I learned about some message queue issues, which should be producer-consumer issues

Then I happen to be using redis recently, which has a publish and subscribe function. I don’t know if it is suitable for this scenario.

天蓬老师天蓬老师2718 days ago1046

reply all(1)I'll reply

  • 曾经蜡笔没有小新

    曾经蜡笔没有小新2017-06-16 09:21:17

    Why don’t you try professional mq kafka?

    reply
    0
  • Cancelreply