karaf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jonathan Byrne <jonathan.by...@yahoo.com>
Subject Patch created for KARAF-3811
Date Thu, 02 Jul 2015 14:05:59 GMT
I attached a patch that somewhat hackishly resolves  KARAF-3811
<https://issues.apache.org/jira/browse/KARAF-3811>  .

For some reason, a lock is being maintained on JAR files after they are
extracted from the KAR in the karaf:assembly Maven goal. Later in the Mojo
execution, the same JAR is copied from the Maven repository to the same
location where the KAR was extracted. A FileSystemException is thrown
because the destination file is locked.

I can't figure out why the file is still locked and I suspect it may be an
issue specific to the Windows HotSpot JVM. Ideally, I think the file should
not be copied more than once. However, that change was going to be more
substantial than I was willing to tackle. Instead, I changed the download
method to ignore the FileSystemException exception from a failed overwrite
caused by a file lock. This definitely feels hackish to me because it
doesn't address either of the two root issues. However, it was fast, it
worked, and it has a low probability of causing other problems.

View this message in context: http://karaf.922171.n3.nabble.com/Patch-created-for-KARAF-3811-tp4041245.html
Sent from the Karaf - Dev mailing list archive at Nabble.com.

View raw message