Home > other >  Golang can realize this business scenario?
Golang can realize this business scenario?

Time:09-16



I'm a phper, now has a business scenario, use PHP to achieve but also will have trouble, you the great god how to implement this scenario with the go better;

Scene: I use A B C D E F G.. N WeChat ID, now I need to send their message segmentation fixed time, such as 1 second, but if you throw into the queue consumption A B C D will affect their own messages, but if each WeChat ID built A queue will be particularly bad operation and lack of flexibility;
Consumption that require this order, but be not fixed assigned to the message queue for how to implement in golang?

CodePudding user response:

And, of course, if golang can need not queue the intermediate medium could do better,

CodePudding user response:

The channel is not for this job? The sender timing data to the channel, receives the read is sent out,

CodePudding user response:

Queue can find a memory model, type or write a simple memory, is a kind of data structure, also the channel queue if you have the capacity or three?

CodePudding user response:

Golang perfect solution
  • Related