David might want to check this out.
Friday, April 20, 2007
Near real time communication using Restlet
Some services (such as a UI service to watch the arrival of sensor data at a SensorBase) want "near real time" communication, using something like Jabber. There is a new project that integrates XMPP and Restlet which might be quite useful for this:
http://permalink.gmane.org/gmane.comp.java.restlet/1944
David might want to check this out.
David might want to check this out.
Subscribe to:
Post Comments (Atom)
4 comments:
So the idea behind using XMPP in this case is to allow the server-push type of operation where each new sensor data packet is sent from the server to the client, rather than polled via GET by the client?
Exactly correct. BTW, do you have any alternative suggestions?
I know in HTTP it is possible to keep a connection open for a long time. Usually this is done so a client can reuse the connection and avoid the setup and teardown when it knows it will be making a lot of requests. Here is the Wikipedia page. Perhaps this could be used to reduce the overhead? Or perhaps the server could just send data as it comes and the client would slurp it up incrementally (even though the HTTP response is not complete).
I'd definitely recommend the first implementation just poll doing HTTP GETs (making sure to avoid caching). If that works it would be a lot easier than XMPP (which is a whole nother protocol, and you are reliant on Jabber servers, do you use Google or set up your own, etc).
I think you're right. I've updated the SensorDataViewer Milestone document appropriately. :-)
Post a Comment