Most of your questions can be answered with a quick read of
the documentation. The function of execAndWait is different than the flow we discussed
in your previous post so that may be the source of your confusion. Basically,
Struts puts the action on its own
thread, completes one round trip of the request to render the wait
JSP, then polls the action to see if it is finished yet.
1.) If we see line 7 of the console, at this point sleep time in the action finishes off. So, after this statement execution of the action class, the interceptors should be called in the reverse order. Which are not being called !!
They are called correctly on lines 3 and 4.
2.) Line 8,9,10,11 they are printed out because after 2 seconds the temp.jsp page is being refreshed. Here the interceptors are working in their order but why action class is not envoked between this ?
The action is not called a second time by the execAndWait interceptor. That would cause an infinite loop as another long-running process would be spawned with each check. The spawned thread is checked by Struts and if it is done running, Struts shows the final result.
3.) Why is it that the result in the welcome.jsp is not coming in the uppercase ?
You should not be using the stack for regular user data. Use your "business objects", like Login. I would bet that Login.name is what is actually being referenced by welcome.jsp.