It's comet.
Now there are two requirements to achieve
1, a new user questions, the Web interface automatically pop-up questions
2, the number of problems under a tag increased by 1 The total number of Web interface tags automatically add 1
In fact, do not consider the server pressure how to do it.
How to minimize server pressure without being too concerned about compatibility
Available HTML5
Reply content:
It's comet.
Now there are two requirements to achieve
1, a new user questions, the Web interface automatically pop-up questions
2, the number of problems under a tag increased by 1 The total number of Web interface tags automatically add 1
In fact, do not consider the server pressure how to do it.
How to minimize server pressure without being too concerned about compatibility
Available HTML5
PHP Web message Push framework
There are ready-made open source can be used directly, the use is very simple.
Based on WebSocket, automatically turn to comet when not supporting websocket, non-rotation, good performance
Demo: Click here to view Web message push Demo
Currently I have tried two websocket based frameworks, one is Swoole, one is Workerman, you can try
WebSocket
The Segmentfault notification is that the Web client initiates a request to pull data every minute.
One project idea is to pull data each time the user actively get and post requests