简体   繁体   中英

How to invoke struts1 action from a timer?

I got a struts1 web application, mainly forms submitted to the struts Actions on the server side. I would need to add a timer, that once in a while will read the parameters for the same form but from other source (like DB or file). So, basically the form will be filled in the timer, instead of the page. the questions is: how do I invoke the same Action for the Form? but from the timer thread, and not through the web page.

You can use javascript timer objects to create these time based events as described here . And then use normal ajax/event based form submission for example .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM