GitHub user gaohoward opened a pull request:
https://github.com/apache/activemq-artemis/pull/1125
ARTEMIS-1058 Jars in web tmp dir locked on Windows
The embedded jetty web server's WebAppClassloader holds up
webapp's jar files and does not release them after close.
For that reason the web app's temp dir cannot be cleaned up
on Windows. (Other platforms like Linux doesn't prevent a
force delete of files even they are not released).
As long as this behavior exists we need to have a workaround
to let the tmp dir be cleaned up.
It is possible that we use a 'customized' classloader to replace
jetty's WebAppClassloader, in which we manually iterate every
JarFile resources and close them.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/gaohoward/activemq-artemis master_jetty
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/activemq-artemis/pull/1125.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #1125
----
commit 1c85570d926ce1a51a34523eadab9e1714a498f2
Author: Howard Gao <[email protected]>
Date: 2017-03-23T13:45:12Z
ARTEMIS-1058 Jars in web tmp dir locked on Windows
The embedded jetty web server's WebAppClassloader holds up
webapp's jar files and does not release them after close.
For that reason the web app's temp dir cannot be cleaned up
on Windows. (Other platforms like Linux doesn't prevent a
force delete of files even they are not released).
As long as this behavior exists we need to have a workaround
to let the tmp dir be cleaned up.
It is possible that we use a 'customized' classloader to replace
jetty's WebAppClassloader, in which we manually iterate every
JarFile resources and close them.
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---