tags:

views:

245

answers:

1

Oracle 10g Application Server, Java 1.5 + JSF (presentation layer) + iBatis (database communication layer)

In the place where I work at the moment, there sometimes rises the necessity to do small tweaks to the deployment directory. I don't deny that it's not the best practice (if I stay long enough on this site maybe I'll end up the example of the worst practices in general - but there are good sides to it too :)

So, three basic things we tweak with are:

  • recompiled Java class files
  • modified JSP's
  • modified iBatis query "maps" in XML format

For example, when a bug is reported, and the client is eager to get on with it being corrected, we make the correction to the java file, recompile the class, and copy the resulting .CLASS file to wherever the old version was placed during the deployment. Likewise, we overwrite modified JSP's (I suppose that the application server magically understands when a new JSP has arrived, and recompiles it as necessary).

In the above two cases, just as a precaution, we also restart the Application Server. I have never tried to see if the changes would work without restarting - if the server somehow caches the classes/JSPs in memory this wouldn't be the case.. So, that's my first question - are the changes in class/JSP files are tracked by the application server? maybe restart is not necessary?

In case of iBatis XML's, we have seen that new queries are taken from updated XMLs, and no restarting is necessary. Still, sometimes while undeploying, we have seen that some XML files stay locked, meaning that iBatis caches something (not sure what).

I was wondering, in the long run, how these tweaks may influence the stability of the system? Do other people apart from us here do stuff like that?

+1  A: 

We have Apache Tomcat on our production servers, JSPs can be replaced without problem, the server will read the new page without a restart. Files like .properties, ibatis .xml, .class cannot be used in this way, as far as I know this require a restart on Tomcat.

Alberto Zaccagni