Friday, August 21, 2009

Enabling Automatic JSP reloading

Introduction
Eventhough in IBM Web Sphere Portal 6.1(refered as Portal going forward) you can deploy deploy the custom theme as a separate war file, only the changes made in the defaul.jsp file will be reflected relatime. Other supporting file like head.jspf files etc.. even if you change the files, it practically it needs a application restart (In Portal 6.0 it required server restart. some what a improvement in that sense:) )

Particulary while developing the themes it would be cool if the JSP reloading is enabled. Make sure that the JSP reloading is disabled in Production and Stagging environment. Otherwise you will run into performance issues :)

Enabling Automatic JSP reloading
Steps followed:
a) Open the file<>/config/cells/cell_name/applications/ wps.ear/deployments/wps/wps.war/WEB-INF/ibm-web-ext.xmi

ie. Say the portal sever is installed in C:\ibm drive, then the path would be : C:\ibm\WebSphere\profiles\wp_profile\config\cells\citizen\applications\wps.ear\deployments\wps\wps.war\WEB-INF\ibm-web-ext.xmi

b) Change the value in the tag , reloadingEnabled to true

c) restart the portal server from WAS console

After making the above changes, changes are reflected immediatley when the files like head.jspf etc.. are changed in themes/skins

Things to Remember:
a) Performance issue will be there. use only for the testing purpose i.e. development environment. Dont use in PRODUCTION or STAGGING environment.
b) To view changes to a JSP that is included by another (parent) JSP, you must also change the parent JSP to indicate that it must be reloaded by the server.

Regards,
Elango

No comments: