asynchronous handling of backend events?
Folks;
maybe this is a pretty childish question - as I am all digging into this kind of technology, hope I don't bother you all too much with this. I do have a conceptual question regarding architecture of a given setup / idea:
- In a web application, I have sort of a "backend service" (actually a Java/Hessian web service keeping track of information related to an active web session), and there are different application modules accessing this service / session information.
- In the web UI, there are some components living in IFRAMEs accessing these session information in the backend, eventually changing them (yes, it's not the best way of doing so, but in terms of a slow, seamless migration the only one we can go so far).
- I want to make the UI "outside" the IFRAME capable of, well, sort of "listening" to changes happening in the backend and, eventually, updating the UI accordingly whenever something in the backend stored session state has changed.
The first thing I eventually came up with would be registering some sort of JavaScript polling mechanism to periodically "check" the backend service and figure out whether anything happened there, but I am not sure whether this is a good idea. I see jquery is pretty powerful, and I am aware there eventually are better ways to do this, but at the moment, I don't even know what to look for, in the documentation. Can some kind soul point me the right direction?
TIA and all the best,
Kristian