Actions and their corresponding jsps exist to handle requests sent by the browser. Its a client pull model, so you cant schedule to push data to the client at intervals (I would recommend staying away from trying any tricky hacks that involve keeping the http connection open).

What you can do is to set up javascript or some kind of meta refresh tag (I forget the syntax, one of these pages should have it though:
http://www.google.com/search?q=automatic+page+refresh+meta+tag
) in your pages html to cause the browser to self-refresh the page every 30 seconds.


If you go this way you need to be aware of potential load issues (if you have many browsers issuing the request every 30 seconds it can bog down your server quite a bit - especially where there is db access involved...)

Id recommend you leave it to the user to manually refresh the page themselves (you may give them a button to do it).

Ryan julius wrote:

Hi,
I have in my project, an action /ReadDataBaseData.do and the corresponding handler :
public ActionForward accessDatabase(ActionMapping, ActionForm, ...) ;
This action forwards to the page displayData.jsp
<forward name="displayDBData" path="/displayData.jsp"/>
Problem: The database is populated each 30 seconds by an external server.
Question : How can I setup my action and implementation in order to access the database each 30 seconds.
Thanks in advance.


                
---------------------------------
Créez gratuitement votre Yahoo! Mail avec 100 Mo de stockage !
Créez votre Yahoo! Mail

Le nouveau Yahoo! Messenger est arrivé ! Découvrez toutes les nouveautés pour dialoguer instantanément avec vos amis.Téléchargez GRATUITEMENT ici !


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to