You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@karaf.apache.org by to...@quarendon.net on 2016/09/20 10:49:38 UTC

OSGi Log Service?

According to the documentation, the OSGi Log service is supported.

I'm trying to install a bundle that uses it, and I get:

missing requirement [bundleid/1.0.0.201609201024] osgi.service;
filter:="(objectClass=org.osgi.service.log.LogService)"; effective:=active]]

My use is with DS, so:

	@Reference
	private LogService log;


To me that says that there isn't an implementation of the LogService object that
it can find to resolve. 

Am I misinterpreting?

(Karaf 4.0.6).

Thanks.

Re: OSGi Log Service?

Posted by je...@javaxpert.com.
Hi Tom
Did you install any feature providing the LogService? Felix Log service is one of the possible implementations
You may précise in your code the optional attributs while defining the injection.
Hth
Jérôme

Envoyé de mon smartphone BlackBerry 10 sur le réseau Orange.
  Message d'origine  
De: tom@quarendon.net
Envoyé: mardi 20 septembre 2016 12:49
À: user@karaf.apache.org
Répondre à: user@karaf.apache.org
Objet: OSGi Log Service?

According to the documentation, the OSGi Log service is supported.

I'm trying to install a bundle that uses it, and I get:

missing requirement [bundleid/1.0.0.201609201024] osgi.service;
filter:="(objectClass=org.osgi.service.log.LogService)"; effective:=active]]

My use is with DS, so:

@Reference
private LogService log;


To me that says that there isn't an implementation of the LogService object that
it can find to resolve. 

Am I misinterpreting?

(Karaf 4.0.6).

Thanks.

Re: OSGi Log Service?

Posted by Guillaume Nodet <gn...@apache.org>.
The service is provided by pax-logging.
But I suspect the manifest is missing the capability for this service.
Try adding the following instruction in your bundle

  <_removeheaders>Require-Capability</_removeheaders>

Cheers,
Guillaume Nodet

2016-09-20 12:49 GMT+02:00 <to...@quarendon.net>:

> According to the documentation, the OSGi Log service is supported.
>
> I'm trying to install a bundle that uses it, and I get:
>
> missing requirement [bundleid/1.0.0.201609201024] osgi.service;
> filter:="(objectClass=org.osgi.service.log.LogService)";
> effective:=active]]
>
> My use is with DS, so:
>
>         @Reference
>         private LogService log;
>
>
> To me that says that there isn't an implementation of the LogService
> object that
> it can find to resolve.
>
> Am I misinterpreting?
>
> (Karaf 4.0.6).
>
> Thanks.
>



-- 
------------------------
Guillaume Nodet
------------------------
Red Hat, Open Source Integration

Email: gnodet@redhat.com
Web: http://fusesource.com
Blog: http://gnodet.blogspot.com/