|
Relates :
|
|
|
Relates :
|
|
|
Relates :
|
A customer found the case where files in .war can not be deleted
in some Web application which uses javax.crypto.Cipher
even if undeploy are executed.
CONFIGURATION:
JDK:JDK1.4.2_05
Tomcat 5.0.25
BEHAVIOR :
The files under webappls directory can not be deleted after undeploy
with Tomcat Manager.
Because the files are not deleted, application can not be deployed
after the customer changes the application.
.........
at sun.net.www.protocol.jar.JarFileFactory.get(JarFileFactory.java:67)
at sun.net.www.protocol.jar.JarURLConnection.connect(JarURLConnection.ja
va:85)
at sun.net.www.protocol.jar.JarURLConnection.getJarFile(JarURLConnection
.java:69)
at javax.crypto.SunJCE_e.run(DashoA6275)
at java.security.AccessController.doPrivileged(Native Method)
at javax.crypto.SunJCE_d.b(DashoA6275)
at javax.crypto.SunJCE_d.a(DashoA6275)
at javax.crypto.SunJCE_d.a(DashoA6275)
at javax.crypto.SunJCE_b.b(DashoA6275)
at javax.crypto.SunJCE_b.a(DashoA6275)
at javax.crypto.SunJCE_g.a(DashoA6275)
at javax.crypto.SunJCE_g.a(DashoA6275)
at javax.crypto.SunJCE_b.a(DashoA6275)
at javax.crypto.SunJCE_b.a(DashoA6275)
at javax.crypto.Cipher.a(DashoA6275)
at javax.crypto.Cipher.getInstance(DashoA6275)
at HelloWorld.encode(HelloWorld.java:41)
at HelloWorld.init(HelloWorld.java:17)
at javax.servlet.GenericServlet.init(GenericServlet.java:211)
INVESTIGATION :
It turned out the jar file included in the appication is saved in cache of
sun.net.www.protocol.jar.JarFileFactory called from javax.crypto.Cipher.
We can control cache on/off with using setUseCaches(false) in usual our
application. However, in the above case, because the cache control is done
in javax.crypto.Cipher, we can not do anything to control cache.
REQUEST:
If Cipher really opens jars in user application and hold,
it seems that Cipher should release or purge cached jars on the application's
exit.
Otherwise, please provide some workaround.
======================================================================
|