I'm running Karaf and have a blueprint xml file that access a file from the Karaf etc directory (...apache-karaf/etc/SomeProperties.properties) for use in a bundle:
<ext:property-placeholder placeholder-prefix="$[" placeholder-suffix="]">
<ext:location>file:etc/SomeProperties.properties</ext:location>
</ext:property-placeholder>
<bean id="SomeBean" class="impl.com.package.SomeBean"
init-method="init" destroy-method="destroy">
<property name="beanvariable1" value="$[property1key]"/>
<property name="beanvariable2" value="$[property2key]"/>
</bean>
However, I also want to access not only all the properties in that one particular file, but all files from that same karaf/etc directory that end in .cfg (without naming any of the files individually). Can this be done?
Specifically, is there a way to specify a directory location instead of file location? And additionally filter on file type within that directory?
Or, for that matter, is there any way (using blueprint or otherwise) to access all the files in the apache-karaf/etc dir (not just particular properties contained in them) from within a bundle running in Karaf?