Re: Model View Controller with JSP
Jan Behrens wrote: hi list, i am trying to figure out a way to use the model-view-controller paradigm to dynamicaly reload a jsp page when the underlying object has been changed by another user. i would like to achive this without having to use a separate servlet however... any ideas, tips or links would be very much appreciated There's no way for the HTML stream that has been sent by the server to the user agent to know when something has happened on the server side without the user-agent being prompted to re-check the server. However, you can keep an open connection to the user-agent and send it new data when necessary -- it is complicated but someone recently posted a link to this article on the subject (this is called pushlets): http://www.javaworld.com/javaworld/jw-03-2000/jw-03-pushlet.html Erik - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Model View Controller with JSP
hi list, i am trying to figure out a way to use the model-view-controller paradigm to dynamicaly reload a jsp page when the underlying object has been changed by another user. i would like to achive this without having to use a separate servlet however... any ideas, tips or links would be very much appreciated regards jan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Model View Controller with JSP
Hi Jan, I think you are out of luck with a straight JSP unless you incorporate Applets to stream the data to. When you request a JSP page, it is dynamically generated from the server, but it still follows the HTTP method of a simple request, which returns the page and the 'connection' is terminated. I would recommend either Java Applets, or doing your app in Macromedia Flash and taking advantage of the XMLSockets talking to a servlet. This method would 'push' the data out to the clients as soon as it is updated. Or, if you can 'poll' the server for updates (ie it doesn't have to be updated immediately), you can simply have your applet or Flash app occasionally request a certain JSP page for new data. Mark - Original Message - From: Jan Behrens [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Friday, March 14, 2003 5:48 AM Subject: Model View Controller with JSP hi list, i am trying to figure out a way to use the model-view-controller paradigm to dynamicaly reload a jsp page when the underlying object has been changed by another user. i would like to achive this without having to use a separate servlet however... any ideas, tips or links would be very much appreciated regards jan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]