When we try to redeploy an EAR whith an older version (with console 'update' but without using production redeployment) the classes of WEB-INF\classes and/or jars of WEB-INF\lib in the war modules are not updated with the oldest versions. This is the case when we want to reverse to a previous version of an application after a wrong deployment.
We are under weblogic server 10.3.
We don't use 'production redeployment' (so there is no appversion in descriptor) but rather use console 'update'.
We saw that jars and wlcls_gen.jar (containing classes from WEB-INF\classes) are not updated in the temp working folder (\tmp\_WL_users\...). These jars are only updated if the EAR contains newer classes in those specifics jars than the current deployed EAR.
Here is the test case :
- deploy an application and test a servlet saying 'version 1'
- update the application with changing the servlet that now say 'version 2' and test the servlet
- update the application with previous version (containing the servlet saying 'version 1' and test the servlet. It still say 'version 2' !!
You get the same issue if you package the servlet class in a jar into WEB-INF\lib instead of directly into WEB-INF\classes.
It seems that there is a kind of caching that is not updated on 'update' operation if the date/time of a class is not newer of the one actually deployed.
If someone know how to avoid this side effect.
Thanks for your help.
This is a known issue with the WLS web app caused by the check conducted by the ChangeAwareClassloader.
The fix most probably made it into Weblogic 10.3.6.
Can you confirm if this is also happening in 10.3.6?
I downloaded and install a 10.3.6 version and you are right, it seems to work. Older versions of classes, jars and jsp in an EAR are updated correctly on an 'update' deployment operation whatever their change dates. For the moment I have only test on a standalone server but I will make further tests in a cluster conf with stage and report the results here.
Thanks for your help anyway, you helped me on an issue I try to solve for a very long time while support always claimed 'it works as designed' (which don't seems to be the case anymore ;).