I need to do some pre-processing logic which reside in my Struts2 Action class, before showing index.jsp
when user access my Java web application for the first time. I tried using the below snippet in web.xml
but it failed:
web.xml:
<welcome-file-list>
<welcome-file>loginPage.action</welcome-file>
</welcome-file-list>
To summarize, when user hits http://myjavawebap.com
, first the struts2 action loginPage
needs to be called and then the action should dispatch the default index.jsp file. Is there any way to achieve this?