I am using in
Struts 2 with Ajax. The javascript function that creates the http request is called every 5 seconds by:
the url is mapped in struts.xml to a method in an action, I have a breakpoint in the method that is reached but it only happens once - it should be called every 5 seconds.
The method returns some text with the value of a counter that is incremented on each call but the counter value does not change - no surprise since the method's breakpoint is not reached.
I am reasonably sure javascript in the
jsp is correct - I modified the function that deals with Ajax response to alter the url to a bad value and I get struts error the action request url is being handled by struts.
It seems to me that there is some "cacheing" going on in struts, pseudo code:
if action has executed return action results
else call action
Just to reiterate, the method should be called every 5 seconds but is only called once.
my struts entry:
The action class method, gets called one time:
and the jsp