2 Replies Latest reply on Dec 29, 2008 9:56 AM by edill

    Jboss 5, Hot Re-Deployment, display old content, Work Direct

    edill

      Hi, I am currently evaluating JBoss 5 to replace a paid Application Server but am having problems with re-deployments of .WAR files. When I drag the .WAR to the deploy directory the first time, the correct content displays in the browser. However, once the content in the war file has changed and is copied over the old .WAR file, the original content is still displayed (much like it is storing it in cache).

      Stopping and restarting the server doesn't help, it still showed the old content. This told me that it was writing it to disk. Which led me to the "work" folder. When I delete the corresponding app from the "work" directory, the server creates a new one based on the new content.

      This is what I would like to achieve, without the step of deleting the application in "work" since it is recommended not to modify the "work" folder in a production environment.

      I have tried:
      -According to the standard output, hot deployment is working when the file is overwritten since is says "undeploy...redeploy..." and creates a new directory in TMP. Obviously HOT DEPLOY is working as advertised.

      -Changing "reloadable" attribute to "true" in the jmx-console's 'host=localhost,path=/webapp,type=Loader' link. (only in Jboss 4.2.3GA, doesn't exist in Jboss 5.0.0GA

      -Added reloadable="true" to the in server/default/deploy/jboss-web.deployer/context.xml

      -Modify and/or "Touching" the web.xml within the application I am trying to deploy.

      * None of these trigger the refreshing of the "work" directory.
      * I have read both the "Installation and Getting Started Guide" and "Administration and Configuration Guide" with no solutions
      * I have searched many forums including this one

      Any help from the experts would be very much appreciated!

      I am using:
      -Linux Ubuntu 6.06
      -Jboss 5 (Also back-tracked to 4.2.3 with the same problem)
      -Running default configuration (./run.sh -c default -b x.x.x.x)
      -JDeveloper 10.1.3 on Windows XP SP2 Client for development and deployment (war creation)

      Thanks in advance




        • 1. Re: Jboss 5, Hot Re-Deployment, display old content, Work Di
          jaikiran

           

          However, once the content in the war file has changed and is copied over the old .WAR file, the original content is still displayed (much like it is storing it in cache).


          What type of contents? JSP files?


          -Modify and/or "Touching" the web.xml within the application I am trying to deploy.

          * None of these trigger the refreshing of the "work" directory.


          See if this similar discussion helps http://www.jboss.com/index.html?module=bb&op=viewtopic&t=146078. I don't have my local JBoss setup (5.0 GA) in front me right now, so i can point you to the exact file which you might have to modify (the files have been moved to "deployers" folder in JBoss-5 i guess). But i guess, that post should atleast lead you in the right direction. Let us know if it doesn't.


          • 2. Re: Jboss 5, Hot Re-Deployment, display old content, Work Di
            edill

            jaikiran,

            What type of contents? JSP files?


            Yes, JSP files.

            This discussion http://www.jboss.com/index.html?module=bb&op=viewtopic&t=146078 solved my problem.

            They did, in fact, change the file name and location of the DeleteWorkDirOnContextDestroy attribute in Jboss 5.0.0. It is now located in server\default\deployers\jbossweb.deployer\META-INF\war-deployers-jboss-beans.xml. Changing the attribute to "true" from the default "false" and making sure the date and time was correct on the server solves the problem.

            Thank you so much for your response!