You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@felix.apache.org by Leen Toelen <to...@gmail.com> on 2009/12/24 08:36:34 UTC
FileInstall, ManagedServiceFactory and BluePrint filters
Hi,
I have a ManagedServiceFactory defined, and fileinstall cfg files that use
the ManagedServiceFactory pid.
com.example.factoryid-pid.cfg
datasourcename=mydatasource
driver=my.driver.Class
jdbcurl=mysql://...
The ManagedService is updated, and it re-registers a new Service (defining
the javax.sql.DataSource interface) in the runtime with the service
properties above. They also show up in the webconsole, so I guess that works
fine.
I would like to use the datasources in a blueprint service. The XML looks
like this
<reference id="datasourceservice" interface="javax.sql.DataSource"
*filter="(datasourcename=mydatasource)"* availability="mandatory">
</reference>
<service interface="com.example.service.Service">
<bean
class="com.example.service.impl.ServiceImpl">
<property name="datasource" ref="datasourceservice"/>
</bean>
</service>
The service is never created however, and the logs don't reveal anything.
Can anyone tell me what I am doing wrong?
Regards,
Leen