The missing requirement indicates that you need a Log Service implementation 
(i.e. someone to provide you with the service). The dependency that you’re 
compiling against is just the API (which is a good thing to compile against) 
but you actually need an implementation at runtime. Your build tools know that 
you need this service, and so have added a requirement for the service to your 
bundle. Your bundle therefore will not resolve until you have installed a 
bundle which declares that it provides the service!

Regards,

Tim

> On 22 Feb 2017, at 09:05, Olivier21 <olivier.roz...@netcourrier.com> wrote:
> 
> Hello,
> 
> I developed a SOAP service which is encapsulated in a kar archive. Then, I
> made a custom karaf distribution from Karaf 4.0.4. Everything works fine (no
> error message in the log files and the service works fine).
> 
> The problem is when I try to do the same thing with Karaf 4.0.8, I got this
> message during the deployement :
> 
> missing requirement [...] osgi.service; effective:=active;
> filter:="(objectClass=org.osgi.service.log.LogService)"
> 
> How can I inject the service "org.osgi.service.log.LogService"?
> 
> In my class, I have :
> 
> protected LogService logService;
> 
> public void setLogService( final LogService logService ) 
> {
>       this.logService = logService;
> }
> 
> 
> In the file pom.xml, I have :
> <dependency>
>        <groupId>org.osgi</groupId>
>        <artifactId>org.osgi.service.log</artifactId>
> </dependency>
> 
> Must I use <import-service> and if yes, what must be the contain of this
> element?
> 
> It seems that the LogService service is not satisfied anymore and it seems
> to be the same problem that is specified here :
> http://karaf.922171.n3.nabble.com/VOTE-Apache-Karaf-Container-4-0-6-release-td4047647.html
> 
> Please, could you help me please?
> 
> Olivier
> 
> 
> 
> 
> --
> View this message in context: 
> http://karaf.922171.n3.nabble.com/missing-requirement-osgi-service-effective-active-filter-objectClass-org-osgi-service-log-LogService-tp4049593.html
> Sent from the Karaf - User mailing list archive at Nabble.com.

Reply via email to