开发者

10,000 users or 10,000 setInterval()?

I'm using APE-Project,

Is it better to have 10,000 connected users or 10,000 pages that use a setInterval() to send each 开发者_StackOverflow中文版N milliseconds a request to a PHP page?

Thanks


APE claims it can scale upto 100k connections per machine. It's using proper evented I/O so it just scales becuase it doesn't have one thread/process per connection.

Just use 10000 connected clients with web sockets.


PHP isn't well known to be able to handle large amounts of concurrent long-lived connections. If you decide to use PHP you might want to use setInterval to pull updates from the server. This way you don't have to keep expensive connections open.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜