(đang nghiên cứu và đánh giá, thực hiện)
Giới thiệu công nghệ
Reverse Ajax refers to an Ajax design pattern that uses long-lived HTTP connections to enable low-latency communication between a web server and a browser. Basically it is a way of sending data from client to server and a mechanism for pushing server data back to the browser.
This server–client communication takes one of two forms:
* Client polling, the client repetitively queries (polls) the server and waits for an answer.
* Server pushing, a connection between a server and client is kept open, the server sends data when available.
Reverse Ajax describes the implementation of any of these models, including a combination of both. The design pattern is also known as Ajax Push, Full Duplex Ajax and Streaming Ajax.
Từ khoá: Reverse Ajax / Comet / Ajax Push
So sánh Push và Pull khi dùng Ajax
Các lựa chọn để cài đặt
Cometd Bayeux Ajax Push: Cometd is a scalable HTTP-based event routing bus that uses a Ajax Push technology pattern known as Comet. The term ‘Comet’ was coined by Alex Russell in his post Comet: Low Latency Data for the Browser.
MeteorServer – http://meteorserver.org/
Tomcat / Pushlets
PHP server push (chỉ xài với non-IE)
Jetty 6 Servlet Container has it. It is called Continuation and is based on NIO
Scalability is a fundamental feature for a Comet Server, since a large number of concurrent TCP connections has to handled.
Lightstreamer is based on a staged event driven architecture, built over Java NIO classes, that allows it to handle an arbitrary number of connections with a fixed pool of threads.
Just to give you an idea of performance, on a single Pentium 4 CPU – 2.4 GHz, Lightstreamer Server was able to sustain 10,000 concurrent streaming connections with an outbound frequency of 1 update/sec per client.