Oracle BPEL 10g XSL Cache Initialization

In my current project the BPEL development team, wherein i participate, maintains and develops BPEL processes on 10g. The complexity of these processes are not the processes itself but merely the applied transformations in these processes which also contain custom XSL functions. Testing of the XSL transformations within the IDE (JDeveloper) therefore is in many cases not an option. Alternatively the whole service has to be deployed to a local installed BPEL server and tested by instantiating the service. The main disadvantage here is that BPEL keeps it XSL files in cache, even the XSL files which were re-deployed. So when testing a re-deployed service with modified XSL files, the results of the transformations are unchanged, simply because the 'old' version of the XSL files are still in memory. To load the modified XSL files in memory the BPEL server has to be re-started after each deployment. When having to go though multiple iterations of testing and therefore time-consuming restarts of the local BPEL server can be quite annoying.

Googling around i ran into Shintan Shah's Blog describing the method initializeCache for the object GetElementFromXSLTFunction which is in the Collaxa XML packages used by BPEL. Based on this knowledge i wrote a very simple j2ee application which enables a developer to initialize the XSL Cache. Deploy this application to the same container as BPEL.

How to deploy

  • Download the application ‘InitXSLCache.war’ here
  • Copy ‘InitXSLCache.war’ to \j2ee\home\applications
  • Edit \j2ee\home\config\application.xml and add a line after the definition of the defaultWebApp web-module.

<web-module id="defaultWebApp" path="../../home/default-web-app"/>
web-module id="InitXSLCache" path="../../home/applications/InitXSLCache.war"/>

  • Edit \j2ee\home\config\http-web-site.xml and add a line after the definition of the defaultWebApp application

<default-web-app application="default" name="defaultWebApp"/>
<web-app application="default" name="InitXSLCache" load-on-startup="true" root="/InitXSLCache"/>

  • Stop and Start the BPEL Server

How to use

Access the XSL Cache Initialization application through;

If you want to customize the application yourself, the sources are included in the war-file.

blog comments powered by Disqus