The following constant element sets struts.devMode to true.
<struts> <constant name="struts.devMode" value="true"/> ... </struts>Once you set this attribute to true Struts will check the config file for every request. This will save lot of development time as you need not restart server for struts.xml changes.
Second way of setting this attribute is struts.properties file which can overrides the value of default.properties file as below.
struts.devMode = true
Third way to do it is as a init-param to filter tag in deployment descriptor (web.xml) file as shown below
<filter>
<filter-name>struts</filter-name>
<filter-class>
org.apache.struts2.dispatcher.FilterDispatcher
</filter-class>
<init-param>
<param-name>struts.devMode</param-name>
<param-value>true</param-value>
</init-param>
</filter>





Post a Comment