在Websphere中修改JSP页面后刷新不生效解决方法

style="WIDTH: 345px; HEIGHT: 285px" align="left" marginwidth="0" marginheight="0" src="http://www.ymfund.com/web/ad.html" frameborder="0" width="468" scrolling="no" height="60">

Websphere中修改JSP页面后刷新不生效解决方法

 

       每次在Websphere中修改了JSP文件在前台页面刷新都不生效,还是没有改之前的状态,甚至把缓存中的.class文件清除后再刷新也是没有反应。导致每次都要删缓存然后再重启Websphere才生效,头痛死了。

 

解决方法:

打开 /WEB-INF/ 下面的 ibm-web-ext.xmi 文件,原来ibm-web-ext.xmi 文件内容如下:

 

<?xml version="1.0" encoding="UTF-8"?>

<webappext:WebAppExtension xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:webappext="webappext.xmi" xmlns:webapplication="webapplication.xmi" xmi:id="WebAppExtension_1" reloadInterval="5" reloadingEnabled="false" defaultErrorPage="error.jsp" additionalClassPath="" fileServingEnabled="false" directoryBrowsingEnabled="false" serveServletsByClassnameEnabled="true" autoRequestEncoding="true" autoResponseEncoding="false">

  <webApp href="WEB-INF/web.xml#WebApp_ID"/>

  <jspAttributes xmi:id="JSPAttribute_1" name="reloadEnabled" value="true"/>

</webappext:WebAppExtension>

 

红色部分为加入的,设置reloadEnabled 属性为 true,设置好后必须重新启动Websphere才能生效。

 

其它可设置的属性类似还有:

<jspAttributes xmi:id="JSPAttribute_1" name="useThreadTagPool" value="true"/>

<jspAttributes xmi:id="JSPAttribute_2" name="disableJspRuntimeCompilation" value="true"/>

<jspAttributes xmi:id="JSPAttribute_3" name="useFullPackageNames" value="true"/>

 

具体属性可参考IBM网站:

http://publib.boulder.ibm.com/infocenter/wsdoc400/v6r0/index.jsp?topic=/com.ibm.websphere.iseries.doc/info/ae/ae/rweb_jspreloading.html

 
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章