JSP Precompilation Working but not 'on the fly', without server restart - Weblogic

This is a discussion on JSP Precompilation Working but not 'on the fly', without server restart - Weblogic ; Hi, Main Question: How can I get weblogic server to pick up newly pre-compiled JSP's without restarting? I've searched the BEA documentation and this news group for information regarding this matter but haven't got far at this point. Most of ...

+ Reply to Thread
Results 1 to 3 of 3

Thread: JSP Precompilation Working but not 'on the fly', without server restart

  1. JSP Precompilation Working but not 'on the fly', without server restart

    Hi,

    Main Question: How can I get weblogic server to pick up newly pre-compiled JSP's without restarting?

    I've searched the BEA documentation and this news group for information regarding this matter but haven't got far at this point. Most of the posts are about getting precompilation working in the first place.

    I have JSP precompilation working correctly for Weblogic 6.1 sp3 with temporary patch for CR081732 which is great.

    But...

    Is it possible to use precompilation without restarting the weblogic server?

    At the moment if I change a jsp, re-deploy it to the web directory and precompile it to the working directory (set in weblogic.xml) while weblogic is running then the JSP is re-compiled by the server regardless. If however I restart the server after the deploy-precompile action then the precompiled version is found and used as expected.

    I've manually checked the precompiled file and it is correct in terms of timestamp and weblogic version which are the two main aspects governing a server re-compile. The correct methods (i.e. _isStale and _staticIsStale) are also present and accounted for.

    As far as I know the only thing that remains is that the server won't or is unable to allow re-deploying a precompiled JSP without a restart. Am I correct here or is there a better answer please?

    To get this working without restarting the server is important as restarting in this instance takes approximately 3 minutes.


    Best Regards
    Jon

  2. Re: JSP Precompilation Working but not 'on the fly', without server restart

    Precompiled JSP classfiles, normally stored in WEB-INF/classes, are loaded during first access from the web application's classloader.

    If you update your JSP files, the stale method of the loaded classes is called and leads to recompilation of the JSP (JSP modified date is more actual).
    New classfiles won't be loaded on the fly.

    If you want to update JSPs together with the precompiled classfiles I suggest to redeploy this webapp. A server restart shouldn't be necessary.

    --stefan

  3. Re: JSP Precompilation Working but not 'on the fly', without server restart

    This has confirmed what I suspected.

    Thanks for your prompt reply Stefan.


    Regards
    Jon

    Message was edited by jonathan.court@db.com at Sep 21, 2004 3:31 PM

+ Reply to Thread