The problem here is almost not related to the fact that OSGi has no concept of a file system, but that the file is no longer in the classpath.
I assume that when the war works in regular tomcat, workflow.xml you refer to the file system and are accessible via the tomcat class path. Loader class for WAR delegates for the parent class loader that has access to the workflow.xml file.
In OSGi, your class path is determined by the Bundle-Classpath and any package import or package requirements. This workflow.xml file is obviously not available through any of these mechanisms.
There are several options:
- Place the workflow.xml file inside the package and put it in the Bundle-Classpath. This is not so good if you want the file to be edited without restoring WAB.
- OSGi workflow.xml . org.osgi.framework.bootdelegation com.xyz.abc.resource. : , com.xyz.abc.resource OSGi, framework
- equinox, bundle, : Bundle-Classpath. , .
() , . OsgiBundleResource.
OSGi, Blueprint Container, Spring DM. , , Apache Aries Eclipse Gemini.