FileNotFoundException when deleting bundle from deploy folder on Fuse
Issue
-
In JBoss Fuse, the
"deploy"folder is used to deploy OSGi bundle into the environment. If I put some OSGi bundles in this folder, they are installed without any issue. However, after a restart of JBoss Fuse, if I delete these bundles, I always get an ERROR in the log related to a"java.lang.FileNotFoundException"thrown by fabric (see below). -
This error occurs only after a restart of JBoss Fuse with bundles in the deploy folder before the restart.
-
The
"deploy"folder is used for Hot deployment. Bundles copied in it are automatically installed. When you update or delete these bundles, changes are made automatically as well. -
It shouldn't throw the
"java.lang.FileNotFoundException"while deleting bundles in this folder after JBoss Fuse restart. Following steps to reproduce the issue :
- Start
"fuse.bat" - Copy any bundle in the deploy folder
- Stop
"fuse.bat" - Start again
"fuse.bat" - Delete the bundle from the deploy folder and check
"fuse.log". Following error can be seen:
13:23:10,764 | ERROR | edhat-384/deploy | FabDeploymentListener | 109 - io.fabric8.fab.fab-osgi - 1.0.0.redhat-379 | Unable to parse deployed file C:\jboss-fuse-6.1.0.redhat-384\deploy\test-1.0.0.jar
java.io.FileNotFoundException: C:\jboss-fuse-6.1.0.redhat-384\deploy\test-1.0.0.jar (The system cannot find the file specified)
at java.util.zip.ZipFile.open(Native Method)[:1.7.0_15]
at java.util.zip.ZipFile.<init>(ZipFile.java:214)[:1.7.0_15]
at java.util.zip.ZipFile.<init>(ZipFile.java:144)[:1.7.0_15]
at java.util.jar.JarFile.<init>(JarFile.java:153)[:1.7.0_15]
at java.util.jar.JarFile.<init>(JarFile.java:117)[:1.7.0_15]
at io.fabric8.fab.osgi.FabDeploymentListener.canHandle(FabDeploymentListener.java:51)[109:io.fabric8.fab.fab-osgi:1.0.0.redhat-379]
at org.apache.felix.fileinstall.internal.DirectoryWatcher.findListener(DirectoryWatcher.java:517)[7:org.apache.felix.fileinstall:3.3.11.redhat-610379]
at org.apache.felix.fileinstall.internal.DirectoryWatcher.uninstall(DirectoryWatcher.java:1054)[7:org.apache.felix.fileinstall:3.3.11.redhat-610379]
at org.apache.felix.fileinstall.internal.DirectoryWatcher.uninstall(DirectoryWatcher.java:877)[7:org.apache.felix.fileinstall:3.3.11.redhat-610379]
at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:481)[7:org.apache.felix.fileinstall:3.3.11.redhat-610379]
at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:291)[7:org.apache.felix.fileinstall:3.3.11.redhat-610379]
- The issue is reproducible every time.
Environment
- Red Hat JBoss Fuse
- 6.1.0
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
