Home >Backend Development >PHP Tutorial >About reading the online device list in redis

About reading the online device list in redis

WBOY
WBOYOriginal
2016-09-13 08:46:031054browse

Use redis to save online devices. Operate redis in TCP Server (java netty implementation), add updated data, and then view it on the background management page (the background logic processing is based on thinkphp).
There are two options now:
1 is to use php to read the device online data directly from redis
2 is to interact with websocekt and TcpServer in the web page, and then the TCP Server reads the online device in redis, and then returns it through websocket.
Which one is better? How is it generally implemented?

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn